This project has moved. For the latest updates, please go here.

EXPORT/IMPORT .obj files

Aug 20, 2013 at 8:19 PM
I am trying to use MagicaVoxel as a voxel editor for .obj files. When I load a .obj file, for example the 7x7x7 model, and then export it I see the corresponding .obj file get stored in my /mesh directory. Later, without changing any settings, when I import this .obj file, there are differences in shape between the imported model as compared to the original model. I'm not concerned about the color differences, its the difference in shape that is troubling.

Is there some MagicaVoxel setting that will ensure that an imported model described by a .obj file is identical to the original exported model?

Thanks.
Coordinator
Aug 20, 2013 at 10:13 PM
Edited Aug 20, 2013 at 10:17 PM
Hi bkhanna,

Actually Import and Export operations are irreversible.

When a voxel model is exported, its exterior surface will be saved as individual quads into mesh model such as '.obj' format;
When a polygon model ( triangles, quads, etc. ) such as '.obj' format is imported, its polygon surface will be voxelized into voxels by 3D Scan Conversion ( or Rasterization );

And when the editor exports a voxel model to '.obj', it doesn't export any information about which voxel model it comes from, ( and the editor can't ensure that the voxel model with the same name is the original model )
so it's not available now.
Aug 20, 2013 at 11:09 PM
Thanks glkasumi.

I also notice a big difference in the vertex coordinates among the imported and exported .obj files. For example, I import a .obj file into MagicaVoxel and a typical coordinate in it is "v 1312 1285 10". When I export this model as a .obj file that it stores in /mesh directory, a typical coordinate is "v 44 0 21". Does this mean that MagicaVoxel changes the size of the imported model, when it exports it?
Coordinator
Aug 20, 2013 at 11:25 PM
Yes,
since currently the maximum editable size of voxel model is ( 126, 126, 126 ) in MagicaVoxel,
when import mesh, the editor will firstly try to scale it to fit into this range , and then do voxelization;
while when export voxel model, the output vertex position will just use their integer grid coordinates in the editor.
Aug 22, 2013 at 4:16 PM
Thanks. Is there a way I can increase the maximum editable size of the voxel model to (2046X2046X50) for the application I'm trying to use it for?
Coordinator
Aug 24, 2013 at 1:45 PM
Unfortunately it is not available now ( and it is also why I call it 8-bit voxel editor ;) )
Actually I was planning to make a scene editor in order to edit larger landscape,
but since large resolution volume requires different rendering and editing algorithms ,
it needs some time to implement......
Coordinator
Aug 27, 2013 at 10:56 PM
Correction

When importing mesh model, the editor will firstly scale the mesh to the current volume size not the maximum editable volume size.

If you want to get more details, you need to change the size to the maximum editable volume size ( e.g. 126, 126, 126 ) manually.

Thanks.
Nov 28, 2013 at 3:00 AM
Hi I am a new user with this program, and I have a problem, when I finish a project and I want export, I can't. I don’t know if do something bad or I don’t know where the Project is.

I need help

Thanks
Coordinator
Nov 28, 2013 at 6:28 AM
totoindus wrote:
Hi I am a new user with this program, and I have a problem, when I finish a project and I want export, I can't. I don’t know if do something bad or I don’t know where the Project is.

I need help

Thanks
Hi, to export a model,

firstly make sure that the model has a valid name,

and then after you press the export->obj button, the output mesh will appear in the 'mesh/' folder
Nov 28, 2013 at 11:12 PM
Thanks