AlmostAbsent
Just like above.
Can you procedurally create the world in ue4 with Voxel Farm instead of making it in Voxel Farm Engine and then importing it?
0 0
voxelfarmtorres
Yes, it is possible if you define your custom world as one (or more) implementation of IVoxelLayer.

To add a new IVoxelLayer in the UE4 plugin:

Open VoxelFarmBundle.cpp and locate the VF_UEC::BundleWorld::BundleWorld constructor. There you have a pointer to the worldGenerator object used by the actor. The generator contains the stack of voxel layers that will be used. 

You must add your own by doing:

worldGenerator->addVoxelLayer(myLayer, false);


This requires you to create a C++ class that inherits from IVoxelLayer, which is an abstract interface, and for you to implement at least the getContourData() method in this class. This method is the one that outputs voxels for your layer. It is rather simple, the method will be called by the engine for every cell (or chunk) of the world that appears on the scene. Each chunk is 44x44x44 voxels. There are multiple implementations of IVoxelLayer in the SDK example. You can just search the SDK solution for "IVoxelLayer" and see the example classes. Your layer must set at least a material for the voxels it outputs, and also a "vector" in case you want smooth surfaces.

I also recommend you search in this forum for "IVoxelLayer". You will find multiple posts dealing with this same scenario. This post in particular discusses how to produce vectors for smooth terrain: 

https://forums.voxelfarm.com/post/basic-cube-world-with-underground-and-rudimentary-ore-vein-prototype-9631187?pid=1303252340
1 0