Sorry for not answering this sooner (this thread always slips my mind). Essentially, Laurent is correct when it comes to mobile. Updating meshes at runtime in Unity is expensive, even moreso if you have colliders attached. That’s why I don’t make any guarantees for mobile platforms. The runtime portion of PicaVoxel is mainly aimed at desktop.
Draw calls is an interesting question. Despite using a shared material, the draw calls (batches in U5) always seem high. I’m guessing this is down to the meshes having >900 vert attributes. Again, we’re rubbing up against limitations with procedural meshes in Unity.
Your mileage may vary though, which is why I honour refunds within the first two weeks if you find that PicaVoxel doesn’t suit your project.
I love this toolset very much, and Can you provide a teaching video about the new features like Marching Cubes Meshing and Emissive and Mosaic shaders?
I’ve been considering developing a voxelized rpg and was wondering if you can create an item and then scale it down (basically for better resolution), I’m wanting the flexibility of voxels but better detail. And can each item be scaled seperately? Are the objects created saved as individual files say for importing into multiple projects?
Each PicaVoxel object (we call them Volumes) has its own Voxel Size parameter which sets the size of the individual voxels in units. So yes, you can scale your models as you see fit, and have different sizes for each.
The created objects are not saved as individual files, but you can create prefabs from them.
I would suggest using an external editor such as MagicaVoxel or VoxelShop to create your models, and then import them with PicaVoxel. That way your models are not tied to a particular Unity project. PicaVoxel has full workflow support for .vox and .qb voxel formats.
I’m afraid I don’t have any performace comparisons with other assets for you.
I just updated to PicaVoxel 1.4.7 and every time I try to import a .vox file from MagicaVoxel, I get an error. It just returns an object reference exception and points to this line of code.
if (voxelData.Length == 0) return; // failed to read any valid voxel data
Is this a bug or am I somehow doing something stupid?
Hey @GarethIW I updated to 1.4.7 and save/load is no longer ok, what’s the new syntax for save/load?
voxels*.dataholder.data.LoadFromString(PlayerPrefs.GetString(PPname));*
Also the chunk building is super slow, any plan to thread mesh building?
There’s nothing in PicaVoxel that has the above syntax (dataholder etc) and I have not changed the syntax for loading from a byte array since the very early versions. Did you add your own code to the PicaVoxel classes?
Also, mesh generation in PicaVoxel is threaded. Are you sure you’re not looking at another asset?
That and meshbuilding in the editor is super slow plus search was in full word mode (sneaky) so I couldn’t find threads. This is what happens when reviving year old project with confusing names. So now I spend time before naming my projects, a bit like this
By the way Voxel.Active is a getter. I think I changed it to a variable because when I load I don’t want the mesh to be built (it causes a hiccup), could you add something?
I’ve hacked a thing in the meantime.
set{State = value ? VoxelState.Active : VoxelState.Inactive; }
Hello people,
the last couple of weeks I’ve worked for my current project on a workflow and scripts for rigging a PicaVoxel object using Qubicle, Blender and - no wonder - PicaVoxel. As I thought it would be useful for others as well, I’m hereby releasing it to all PicaVoxel owners. It enables you to combine PicaVoxel objects with Unity avatar setups and so to animate multipart voxel models via Mechanim.
As a bonus, the asset also contains an importer for the new Qubicle Binary Tree format to take automation even further.
I’ve tried to write the workflow as detailed as possible without being bloated. I’ve tested as much as possible, but I’m sure there’s lots of room for improvement. Out of need for my project, I’ll go on to extend this further, so expect more in the future.
If you got any comments, requests, bugs etc. please feel free to contact me via the mail adress you can find in the workflow document. Looking forward to your feedback.
You can’t rig it directly in Unity because it’s not a SkinnedMeshRenderer that Unity uses for these cases, but have a look at my post above yours, I just created a workflow and scripts for exactly that purpose and I’m continously working on extending it for my own project.