volumetric data in blender

I Want to write a python script that gets volumetric data into blender

Im starting of with stacks of photos taken of objects that iv sliced up.

My first attempt was to texture a plane for each image slice but as you can see in this video there are alot of artifacts… what is the best way to approach this?

I think the coolest way to do it might be a script that creates a particle for each pixle in each slice…(can each individual particle hold RGB values ?)
If this could be accomplished then you could do some really amazing things with a keyed particles.

You can see more videos at www.vissesonce.org

Thanks
Rylan Grayston

Your video looks great …

Idea: inform at a Hospital, with a 3D scanner, which company generates pictures out of the scan?

It looks like that you like to be able to cut the object again and look into the interior, right?

The idea of EVERY pixel giving a particle is strange for me: if you mean particle = vertex then probably you had to create
toooooo much vertices’s (if thinking of 60K picture [only!] and a lot of them).

There are a lot of company’s that do medical imaging but its important for me to be able to do it with blender… because blender is open source and Im a blender head :D.

I used the limit setting of the camera to be able to cut into the object from any angle, but this only alows me to cut with a flat plane
that is stuck being Tangical to the camera… I want WAY more control than that.

There are 170 slices and the pics i took were 1600 x 1200
so in this case we would be looking at 1200 x 1600 = 1920000 x 170= 326,400,000 particles
that number is a bit misleading because only about half the pixels that my camera took are actually onion, the other half are
the black background the onion was sitting on.

so ruffly 150,000,000 would give hd resolution of this onion…

That is a lot of Particles but I dont think the number is that big for computers theses days…
tThe fact is that blender 2.4 handled rendering exactly 326,400,000 points of RGB information in the animation in my first post.
and it did so on a 2.4 gh dual core, ( i forget how long it took … but less than a day)

Now I have a 2.6gh Quad core and blender 2.6

I just want to change HOW I did this in blender, so I can have more control, and no artifacts.

I remember some thins like these in old blender release.
Are you tried to do a search in the forum_

try adding a thin solidify modifier to them all and see what that looks like :slight_smile:

You need to utilize BI Smoke system, it already heavily optimized for such data. First step is how to convert your 3d texture slices to data that can be used by smoke system.

There are many algorithms how to draw 3D texture on screen, tens of dissertations, papers. Simpler is pure smoke grayscale cloud, maybe cutted by near plane. More complex models trying to guess gradient of density (very hard task for CPU), and use mix surface/volume produce very nice result.

I think BI Smoke is very interactive and easy to implement, later you can enhance it.

The standard particle system is not programmable. You can not control particles with python, only examine them. So a particle per pixel is out of the question anyway.

What you have in your video is not bad, you just chose bad colors. That solid blue background is not really helping out. Put a gradient in your background, or some kind of environment image. Also, make sure your UV mapping on the planes is really a 1:1 mapping to your images. If you use images as planes and choose the option to make the planes the same size as the image you can get that without having to create them all by hand. Try bluring the image on the planes just a touch under sampling.

Thanks for all the reply’s
I think the solidify modifier or the blur idea would fix the artifacts but would not give me the control Im looking for.

voxel textures looks really promising
but it docent look like it would give me the kind of control that a keyed particle system would… I dont think you can move the individual voxel blocks around.

Mett ebb has obviously been on a mission similar to mine for quite some time!
I think ill contact him.
Thanks RickyBlender

Ill be sure to post my next render here.

read also the thread from Breatch

he added a small script to make special file to use with voxel from slices files
may be you can use this

have fun with voxels

Awsome

Thanks again everyone