Jump to content
Sign in to follow this  
kumpa

I3d From .tiff

Recommended Posts

hi !

i have medical dataset that was converted from .dicom to 16 bit .tiff. Is there a way to pack this set in .i3d format ?

tnxalot

kumpa

Share this post


Link to post
Share on other sites

Not sure but You can try:

create slabs of points...

export data from tiff to points (How to do this - depends on slabs layout in tiff)...

save points as geo...

convert geo to i3d

Share this post


Link to post
Share on other sites

It would be really cool if there was a standalone tool that could take a sequence of images and save them straight into an i3d format, it would save a lot of messing around. Better yet an option in ROPs to render out a sequence straight into i3d

Share this post


Link to post
Share on other sites

hi !

tnx people, that was really fast and i agree with sibbarick, i think it would be nicer to just convert them instead of mapping them onto points. Do you think that .i3d file has to be 2^n, because i have only 260 slices and what does i3dgen actually does ?

Share this post


Link to post
Share on other sites

hi andrew !

thans a lot because this is really cool !!!

the only problem i see is that i dont know if houdini will be able to crunch trough all 260 slices with resolution 512x512. Right now i am at job so i dont have time to run my set, but what u did looks really cool.I will go deeper as soon as i go home. If u are intrested in haveing entire dataset fot testing purposes (because i know you are volumetrics fan), let me know and i will sent it to you.

tanks again

kumpa

Share this post


Link to post
Share on other sites

Hey kumpa!

Hmmm 512x512x260....I am afraid it is impossible to cook such a big

amount of points directly from Houdini. (Memory leak error)

Perhaps it is possible to write standalone app with HDK.

Question about dataset...is it single file (tiled slices) or sequence of files?

I have an idea how to cook i3d from sequence of files with help of i3d shader

without geo (3d Generator ROP: "No geometry needed" mode).

I will check it tomorrow.

Can you mail me your dataset to avk107@yahoo.com? (limit: 10mb per mail)

Share this post


Link to post
Share on other sites

You could just build this into a loop so that you aren't trying to process the whole data set at once. Just do one grid at a time then merge all the processed points together - I haven't done the maths but that should keep it under the 1gb limit I would think.

Of course whether you can then render the thing afterwards is another question.

Keep us posted I'm very interested in this too.

Share this post


Link to post
Share on other sites

Ok...try this:

Jump to Output net

Render comp1 ROP (480 slices 480x480 will be saved to $TEMP)

Render image3d1 ROP (cloud.i3d will be saved to $TEMP) (aprox 4 mimutes on XP1800)

Render mantra1 ROP :)

However there is a problem...

Sequence should be named without padding...

because VEX has the limited set of functions for creation of strings.

So sequence should be named temp1.tif temp2.tif ...... temp100.tif temp101.tif

Look at i3d shader parameters...

Base name - filename without number and extension!

Extension - file extension without dot!

dataset.zip

Share this post


Link to post
Share on other sites

Hi!

I would like to thank you for interest first. I just sent dataset to Andrew because i couldnt upload it to www.yousendit.com. (it just didnt worked). I asked him to put it on ftp or something like that. If you want to have it feel free to mail me on kumpa(at)sekvenca(dot)com. I will send my results as soon as i get home (i was stuck at the office yesterday). Probably those ultra-gurus (especially Andrew) here will be faster than me :)

kumpa

Share this post


Link to post
Share on other sites

I had good results with an little export script I wrote for ImageJ. It writes out a .geo file which you can then convert to I3D. It was an ugly script, but for the small test it worked fine. If your interested I can try to find and upload it this weekend.

Cheers

Achim

Share this post


Link to post
Share on other sites

Hey kumpa!

Thanks for dataset:)

Very interesting pics:)

Unfortunately I do not have access to FTP :(

Note:

Here is parameters for i3dGen:

Oversampling: 1

Compression: No Compression

Variance: 0

It is necessary for succes!!!

You can also fly through i3d in COPs

Install this cop filter:

#pragma oplabel "VEX i3d viewer"
#pragma label zd "Z Depth"
#pragma range zd 0  1
#pragma label channel Channel
#pragma label image "3D Image"
#pragma hint image file


cop2
i3dviewer (  
      string image = "";
      string channel = "";
 float zd = 0;
  )
{
if (image != "" && channel != "")
  {
   vector min;
   vector max;

   float minx;
   float miny;
   float minz;

   float maxx;
   float maxy;
   float maxz;

   float i3dx;
   float i3dy;
   float i3dz;

   vector i3dP;
   vector i3dval;

   float newR;
   float newG;
   float newB;
   
   
   texture3dBox(image, channel, min, max);
   
   assign(minx, miny, minz, min);
   assign(maxx, maxy, maxz, max);
   
   i3dx = fit(X, 0, 1, minx, maxx);
   i3dy = fit(Y, 0, 1, miny, maxy);
   i3dz = fit(zd, 0, 1, minz, maxz);
   
   i3dP = set(i3dx, i3dy, i3dz);
   
   i3dval = texture3d(image, channel, i3dP,
                       "filter", "catrom", "width", 1);
   
   assign(newR, newG, newB, i3dval);
   
   R = newR;
   G = newG;
   B = newB;
  }
}

Create "color COP" (size 512x512)

Add "VEX i3d viewer" and play with Z Depth parameter.

Click Shift-R or "Adapt to full pixel range" button to see all details

This is screenshot of created i3d

post-136-1137162304_thumb.jpg

Share this post


Link to post
Share on other sites
...and rendered as ISO at density -d 0.013

23654[/snapback]

WOW :blink: you guys + houdini = rock's

Share this post


Link to post
Share on other sites

WOW !

that is all i can say now, u guys are amazing !!!

I am sorry but i am still at the job and we are still finishing real-time tv show for our national tv so i cant try it myself, but i am glad u did.

Andrew = Houdini :ph34r:

Share this post


Link to post
Share on other sites

Thanks guys:)

It would be cool to find dataset of the whole human body:)

Just imagine what you can see by animating "density" parameter:)

On this small part i saw bones, veins etc

Very cool!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×