voxcraft / voxcraft-sim

a GPU-accelerated voxel-based physics engine

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Please provide example .vxd file with PhaseOffset

jrieffel opened this issue · comments

Any chance you could provide a simple example vxd file that contains the correct format for per-voxel PhaseOffset?

thank you!

You need commas between every float value for phaseoffset, but no commas between every integer 0-9 for the morphology. I realize this is not ideal. It is something we brought over from voxcad that we should probably change.

An example would help :)

ah yes, having now actually read what you asked, here is an example:

<Structure Compression="ASCII_READABLE">
    <X_Voxels>2</X_Voxels>
    <Y_Voxels>2</Y_Voxels>
    <Z_Voxels>2</Z_Voxels>
    <Data>
        <Layer><![CDATA[1111]]></Layer>
        <Layer><![CDATA[0011]]></Layer>
    </Data>
    <PhaseOffset>
        <Layer><![CDATA[-1.0, -0.5, 0.0, 0.5, ]]></Layer>
        <Layer><![CDATA[0.0, 0.0, 0.0, 1.0, ]]></Layer>
    </PhaseOffset>
</Structure>