Magic

Music Visuals
https://magicmusicvisuals.com/forums/

Working with Voxel

https://magicmusicvisuals.com/forums/viewtopic.php?f=5&t=649

Page 1 of 1

Working with Voxel

Posted: Sun Jan 24, 2016 7:15 pm
by TanookiMonk
Hi there,

So i just want to share with you 2 very good software for making easy voxel that you can import in magic. There is more other software but my goal here is to share the best ones i could find.

First one is VoxelShop :
[media]

Link : https://blackflux.com/node/11

Second is MagicaVoxel :
[media]

Link : https://ephtracy.github.io/

Here is a very basic example of me making a very basic usage of voxel in magic :
[media]


Here is the original Magic Project file containing all voxel that you can feel free to use :
https://www.dropbox.com/s/03s4n9zab8mlm ... k.zip?dl=0

Re: Working with Voxel

Posted: Sun Jan 24, 2016 9:10 pm
by Eric
Awesome! :)

Re: Working with Voxel

Posted: Mon Jan 25, 2016 3:31 am
by artnik
I was playing with MagicaVoxel on OS X just this weekend.

Have you managed to get the .OBJ files to import with their correct colours? The geometry came in fine, but the colours were all messed up.

Re: Working with Voxel

Posted: Mon Jan 25, 2016 4:44 am
by TanookiMonk
artnik wrote:I was playing with MagicaVoxel on OS X just this weekend.

Have you managed to get the .OBJ files to import with their correct colours? The geometry came in fine, but the colours were all messed up.


Yes you are right, the closest thing i could come up with is actually load the obj in VoxelShop and then export it in dae format. But this make a weird lightning effect on final result combined with weird colors too. And the conversion make a "Smooth effect" so we lose the voxel cubic style.

I also tried to load it into blender and export it in blender format. This works with Legacy option enabled but come with similar effect. So in the end yeah this is kind of sad as the only choice (For now) is to create model and color them in magic or use Voxelshop

Re: Working with Voxel

Posted: Mon Jan 25, 2016 5:14 am
by artnik
I had some luck running the .OBJ through MESHLAB, but like you, the best I could do was convert the texture colours to vertex colour and it shows smooth shading across the tri's.

It's interesting, because just importing the .OBJ file comes in with the colours showing the correct, square, hard-edged boundaries, just the wrong colour. It's as if the various faces have been assigned to groups, but that they are pointing to the wrong colours.

Re: Working with Voxel

Posted: Mon Jan 25, 2016 4:27 pm
by Eric
It's interesting, because just importing the .OBJ file comes in with the colours showing the correct, square, hard-edged boundaries, just the wrong colour. It's as if the various faces have been assigned to groups, but that they are pointing to the wrong colours.

That could be a bug -- I'll have a look. Can you post an .obj file which shows up with the wrong colors in Magic?

Re: Working with Voxel

Posted: Mon Jan 25, 2016 4:53 pm
by artnik
Hey Eric,

Seems I can't add .ZIP files, so here's a WeTransfer link to the .OBJ and associated .MTL file: http://we.tl/qfuuFpFJiu
It's one of the example files included with the software.

Here's a screenshot showing the file in MagicaVoxel, and imported to Magic:

Screen Shot 2016-01-25 at 11.33.05 AM copy.png
Screenshot showing colours
Screen Shot 2016-01-25 at 11.33.05 AM copy.png (99.17 KiB) Viewed 14176 times

Re: Working with Voxel

Posted: Tue Jan 26, 2016 2:44 am
by Eric
Thanks. The problem appears to be that the .png texture file generated by MagicaVoxel isn't well formatted. Specifically, it is 32 bits per pixel, which you might think would mean RGBA, but it doesn't actually have an alpha channel.

I can probably make Magic handle this, but another way to easily solve it is to open the .png file in Photoshop (or a similar image-editing program) and re-save it *without* transparency. Try it out and let me know how it goes.

Re: Working with Voxel

Posted: Tue Jan 26, 2016 3:01 am
by artnik
BINGO!

Funny thing is, I opened that in Photoshop and checked the number of channels, only saw 3, and assumed it was good, missing that the image wasn't flattened. Nice sleuthing.

Happy to fix that as I go. Thank-you. :-)

Re: Working with Voxel

Posted: Tue Jan 26, 2016 8:57 am
by damstraversaz
that's great ! thanks a lot for sharing this.

Re: Working with Voxel

Posted: Thu Jan 28, 2016 10:57 pm
by visuality
Great stuff, It would be great to see audio reactive tracing shaders ( for edges ) applied to these volumes, god I cant wait till I get grip on this glsl thing.

Re: Working with Voxel

Posted: Tue Feb 02, 2016 2:06 am
by Eric
Funny thing is, I opened that in Photoshop and checked the number of channels, only saw 3, and assumed it was good, missing that the image wasn't flattened. Nice sleuthing.

Happy to fix that as I go. Thank-you. :-)

It was actually pretty easy for me to handle the alpha issue internally in Magic, so in the next release you shouldn't have to do anything else to get the textures to work.

Re: Working with Voxel

Posted: Tue Feb 02, 2016 5:28 am
by TanookiMonk
Eric wrote:
Funny thing is, I opened that in Photoshop and checked the number of channels, only saw 3, and assumed it was good, missing that the image wasn't flattened. Nice sleuthing.

Happy to fix that as I go. Thank-you. :-)

It was actually pretty easy for me to handle the alpha issue internally in Magic, so in the next release you shouldn't have to do anything else to get the textures to work.


You are my hero !!! Eric this is the kind of things thats remind me why i am so happy i bought Magic in the first place. Those small things you do for your community makes big change for us. :)

Re: Working with Voxel

Posted: Tue Feb 02, 2016 5:48 am
by artnik
Thank-you Eric.

Re: Working with Voxel

Posted: Mon Feb 08, 2016 4:25 am
by TanookiMonk
Ok i just tested the new beta and your fix workt perfectly. But i would like to show you eric how Light is handled weirdly.

Download a voxel model i made here : https://www.dropbox.com/s/t9wh8yj0otzo3cb/Field.7z?dl=0

And load it into magic, you will see that lighting/shadow effect act not so well. I can manage to get different result when rotating the object slightly but obviously this is not a solution :P

Re: Working with Voxel

Posted: Mon Feb 08, 2016 5:12 pm
by Eric
Is the issue that the shadows are too dark?

Re: Working with Voxel

Posted: Tue Feb 09, 2016 5:34 am
by TanookiMonk
Well we could say it like that. But it looks to me that it is dark even when there is no shadow to expose !

Model Loaded :
Ex1.png
Ex1.png (24.91 KiB) Viewed 13548 times


Model Loaded with only a rotate axis :
ex2.png
ex2.png (71.82 KiB) Viewed 13548 times

Re: Working with Voxel

Posted: Tue Feb 09, 2016 5:42 pm
by Eric
Yeah, right now the Model module just uses the default shading options, so the more a face points away from the viewer position, the darker it is.

I have it on my list to add some better lighting controls, such as being able to specify the ambient/diffuse/specular brightness.

Re: Working with Voxel

Posted: Fri Sep 16, 2016 9:55 pm
by TanookiMonk
Hey i just found this : http://www.crocotile3d.com/

[media]


wich is similar to voxel but whit a twist :) ! Gottaaaa love those curvy pixels !!

Re: Working with Voxel

Posted: Mon Aug 31, 2020 10:03 pm
by yumatripp
Any idea on when we may see that 3D lighting?

All times are UTC
Page 1 of 1