Jump to content

I3D generation from 2D images sequence


Dealer2Couleurs

Recommended Posts

Hi,

I have some cloud images at different altitude (taken from a satelite) and I want to convert them to a volumetric shader.

I'm not sure i3D images are what I need but it seems the best for my needs.

I already try to do it in geometry context by creating a serie of voxels (boxes) and then applying the color and alpha of my texture pixels

to these boxes.(X,Z are the UV of my textures and Y is the number of the texture in altitude) The result where not so bad on small exemples but the final textures I want to use are so big that I know it's not the right way to do it ( 2048*1024*1024 = too much geometry).

So I decide to look for 3d textures to do it.

I discover the i3d generator inside Houdini and I'm wandering if it's possible to generate a volumetric shader

based on a sequence of texutre 2D at different levels.

Or maybe you know a better way to do this...

thank you,

I continue looking for docs about volumetric shader inside Houdini.

If you have some good one please share them. For now the only things I found is how to use the clouds and fog shaders already existing but not how to create a new one from scratch ( with VEX, C++, or nodes: I don't care).

have a nice day

Nicolas

Link to comment
Share on other sites

Hi there,

nice thing about HDK/IMG3D_Manager is that it can streams tiles on disk during creation (fillTexture() method), so you could theoretically feed your i3d with any voxels you want. Generating 1024x1024x1024 texture (1.2GB on disk) takes about 40MB of RAM (+10minutes on my laptop). Checkout i3dshpere.C example in HDK docs.

Actually Image3d ROP (interface for i3dgen standalone program) does the same thing even faster, so you're not limited by the size of the volume to be displayed. The trick is to create a i3d shader that will read pixels from correct images.

I wonder how Houdini's texture caching would perform though, as the biggest bottleneck I see in reading in 1000(?) of images... (repeatedly as fillTexture will call pixels in voxels tile order not by plane afaik). Quite probably VEX with texture caching will handle it well.

Edited by SYmek
Link to comment
Share on other sites

I think the bigger ones were 800^3, I think I hit the 2gig windows limit with the 1024^3 ones.

I did have 4 floats per voxel, R, G, B, and density - if you can make do with just density, that gives you more res for the same filesize.

Link to comment
Share on other sites

it's working with VOP and i3dgen rop but only for the density.

I don't understand how I can change the color in the 3D texture because the output parameter node in the image3d shader builder only allow for density float value.

eetu I look at your solution and you said you export the color in the shader but I have no idea how to do this.

Do you remember how you do it (approximatively)?

also I cannot find a good way to switch texture based on the y coordinate. For now I have a switcher with only 3 levels connected to it.

but I suppose you didn't plug 512 level by hand in a switcher. Do you remember your solution?

thank you so much

Link to comment
Share on other sites

I don't understand how I can change the color in the 3D texture because the output parameter node in the image3d shader builder only allow for density float value.

eetu I look at your solution and you said you export the color in the shader but I have no idea how to do this.

Do you remember how you do it (approximatively)?

I think it was just a Parameter VOP, set to export. The name of the parameter will be the name of the channel in the i3d file.

also I cannot find a good way to switch texture based on the y coordinate. For now I have a switcher with only 3 levels connected to it.

but I suppose you didn't plug 512 level by hand in a switcher. Do you remember your solution?

I used the voxel index to build a filename string in the VOP network, and then read from that file.

Link to comment
Share on other sites

I found an other way to get the color.

Instead or trying to get the color in the same file with the density,

I create three different files, each one with a specific color.

After that, I just need to print the three i3D files in the same render ( each one on a diffferent shader) and they merge pretty well

It allow a better resolution because insteade of having one big file (limited to 2Go on windows),

you separate the data in three different so you can increase the resolution a lot.

thanks a lot for your help.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...