Voxelers/mcthings

Create Voxels based 3D Graphics

acs opened this issue · 6 comments

acs commented

What are the best tools? The best workflow?

acs commented

Let's explore the MagicaVoxels to MC workflow. MagicaVoxels (MV) can export in OBJ format, so then, we can use binvox like in #62

The main issue is to work with big cubes like in MC en MV. Let's see. Guau, it's very easy to do it. Just press 1/2 to adjust the size of the model until you reach 1x1x1. Time to export it to OBJ and imoport it in MC!

Let's start with this knight (20x21x20 cubes):

Screenshot from 2020-06-11 22-58-06

converted with:

[schematics](develop)$ binvox -fit -d 21 ~/devel/voxels/MagicaVoxel-0.99.5.1-win64/export/chr_knight.obj -t schematic

and the result is:

Screenshot from 2020-06-11 23-06-46

we need to rotate it, and also, it has been flipped by X! (a bug in binvox) The axe is in the left and not in the right hand!

[schematics](develop)$ binvox -rotz -fit -d 21 ~/devel/voxels/MagicaVoxel-0.99.5.1-win64/export/chr_knight.obj -t schematic

Screenshot from 2020-06-11 23-15-38

Screenshot from 2020-06-11 23-19-26

So we can adjust the dimension so they are the same in both tools. But the precision is not totally right if you take a close look to both figures.

In order to map the materials file to schematics blocks:

-mb: when converting using -e from .obj to schematic, parse block ID from material spec 'usemtl blockid_<id>' (ids 1-255 only)

I am not sure if you can have only one material for all the schematic or you can map materials from obj to minecraf block ids.

Let's take a look to this OBJ also in Blender:

Screenshot from 2020-06-11 23-37-09

Here, the knight is not flipped. So this is something done by binvox.

Ok, as a conclussion, MagicaVoxel could be a good option for creating figures to be used in Minecraft. The flipped issue could be solved flipping the images inside MagicaVoxel before exporting to OBJ.

The sample rool from MagicaVoxel in Minecraft:

Screenshot from 2020-06-12 00-06-10
Screenshot from 2020-06-12 00-04-59

acs commented

Vox (and kv6) to Schematics

It is possible to have colors from the obj 3D model inside Minecraft using this workflow (not using binvox): http://makeit.zone/3d-conversion-for-minecraft.html#.XuT6OpaxWV4

But if this python lib works, https://github.com/gromgull/py-vox-io, it must be easy to have our own converter and to tweak it to our needs. According to this fork there are isssues: https://github.com/alexhunsley/numpy-vox-io

There is a new .vox format that breaks the lib: gromgull/py-vox-io#6

This new format is described in: https://github.com/ephtracy/voxel-model/blob/master/MagicaVoxel-file-format-vox-extension.txt

The support on Cubik Studio for Minecraft seems to br broken: https://cubik.studio/forum/viewtopic.php?f=4&t=1503&p=5885&hilit=minecraft#p5885

This guys has something working, but with the old vox format:

http://www.brightmoore.net/mcedit-filters-1/voxtoschematic

But it is in pyhton, so we should take a look.

This project supports Goxel, MagicaVoxel and Schematics legacy and Sponge: https://gitlab.com/bztsrc/mtsedit/blob/master/docs/import.md So we must take it as reference.

We need to decide the Voxel editor to use to work if needed in the workflow with Schematics.

Goxel to Minetest reflections: guillaumechereau/goxel#89 interesting reading

The KV6 (VoxelShop, Open Source!) format has a convert to Minecraft. And it is supported by goxel: guillaumechereau/goxel#32 It seems we are arriving to a workflow ...

KV6 is used in https://openspades.yvt.jp/ We must take a look to this game.

[exported]$ flatpak install flathub jp.yvt.OpenSpades

http://makeit.zone/3d-conversion-for-minecraft.html#.XuUGfJaxUUo A workflow from 3D to Schematics without binvox.

acs commented

https://forum.minetest.net/viewtopic.php?t=23724 MTSEditor seems to be an Editor for Minetest which has support for vox, goxel, schematic legacy and sponge ... promising. But it is pretty young and can ... to which format can it save to?

It can output to vox: https://gitlab.com/bztsrc/mtsedit/-/commit/80569a64c0c91080699f46fd9a1302b14b1847b2

But, also to schematics? No, it only writes to MTS (Minetest format) and to VOX :(

acs commented

Let's go with Goxel:

[exported]$ flatpak install flathub io.github.guillaumechereau.Goxel
[exported]$ flatpak run io.github.guillaumechereau.Goxel

It saves as vxl but no kv6. Not sure if it is compatible with kv6 in some way.