Commit f244b108 authored by David Llewellyn-Jones's avatar David Llewellyn-Jones

Fixed absurd sleep-induced compilation errors. Added OpenVDB menu entry.

parent 7d661d95
......@@ -334,6 +334,15 @@
<property name="use_underline">True</property>
</object>
</child>
<child>
<object class="GtkMenuItem" id="MenuExportModelVDB">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="tooltip_text" translatable="yes">Export as a voxel volume in OpenVDB format.</property>
<property name="label" translatable="yes">OpenVDB (VDB)</property>
<property name="use_underline">True</property>
</object>
</child>
<child>
<object class="GtkMenuItem" id="MenuExportBitmapPNG">
<property name="visible">True</property>
......
......@@ -56,7 +56,7 @@ OVDBCPersist * NewOVDBCPersist (char const * szOutfile) {
psOVDBCData->psGrid = openvdb::FloatGrid::create (2.0);
g_string_assign (psOVDBCData->szOutfile, szOutfile);
psOVDBCData->sAccessor = psOVDBCData->psGrid.getAccessor();
psOVDBCData->sAccessor = psOVDBCData->psGrid->getAccessor();
return psOVDBCData;
}
......@@ -82,7 +82,12 @@ void DeleteOVDBCPersist (OVDBCPersist * psOVDBCData) {
}
void SetGridValue (Vector3 const * const pvPos, OVDBCPersist * psOVDBCData) {
psOVDBCData->sAccessor.setValue (*vPos, 1.0);
openvdb::Coord sCoord;
sCoord[0] = pvPos->fX;
sCoord[1] = pvPos->fY;
sCoord[2] = pvPos->fZ;
psOVDBCData->sAccessor.setValue (sCoord, 1.0);
}
......
......@@ -15,6 +15,8 @@
///////////////////////////////////////////////////////////////////
// Includes
#include "utils.h"
///////////////////////////////////////////////////////////////////
// Defines
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment