X
PrevPrev Go to previous topic
NextNext Go to next topic
Last Post 22 Oct 2011 09:56 PM by  anon
error of plotting a image from a 3-D array
 3 Replies
Sort:
You are not authorized to post a reply.
Author Messages

anon



New Member


Posts:
New Member


--
22 Oct 2011 09:56 PM
    I read into IDL a set of 2d images (10 in all) from a fold and put them into a 3-D array. My code is as following IDL> a3d=bindgen(2048,1768,10) IDL> start_dir=get_coursefiles_dir(/data) IDL> names=sindgen(10) IDL> for i=0,9 do names[i]=start_dir+path_sep()+strcompress(string(i),/remove_all)+'.tif' IDL> for i=0,9 do a3d[*,*,i]=read_tiff(names[i]) Both of the following code is OK and IDL 8.1.0 can draw the original image ( it is 1.tif here) or part of it. IDL> i6=image(a3d[*,*,1]) IDL> i6=image(a3d[100:600,200:1000,1]) But when I use this following code, an error occurs: IDL> i6=image(a3d[*,1,*]) % IMAGE: First argument has invalid dimensions% Execution halted at: $MAIN$ I am really confused because there should be no difference between these two codes. Another question is that, which routine or function should I use if I want to create a 3-D picture from the 3-D array? The pictures used above are intensity-mapped images. Thanks for you help. I will appreciate you deeply. Zhenbo Xia

    Deleted User



    New Member


    Posts:
    New Member


    --
    24 Oct 2011 12:58 PM
    It should be the same, but to make it the same you have to type it correctly. If you look carefully at your two commands, you will see a difference in where you are locating the "1". As far as a "3D picture" is concerned, it will depend on what you mean by a 3D picture. Do you want to look at this as a volume, a series of stacked images, or what exactly do you have in mind?

    Deleted User



    New Member


    Posts:
    New Member


    --
    26 Oct 2011 10:10 PM
    I am trying to putting a series of images into an 3-D array, which are taken through cutting down a porous bulk material slice by slice. My aim is to reproduce the material cut based on these images. As I did above, I want to put these images into a 3-D array and image it. Of course, there are a lot of work left to do and much more details should be taken into consideration rather than combining them simply. Actually, I am at the very beginning of the process and want to know how to show a 3-D image, whose data or gray level was stored in a 3-D array. I might be not present myself clearly enough, and you are welcome to contact me through my email, xiazhenbo@gmail.com or g-talk. Thanks very much for your help.

    Deleted User



    New Member


    Posts:
    New Member


    --
    28 Oct 2011 07:03 AM
    Here is an article that explains how to create a 3D volume view from a series of stacked images: http://www.idlcoyote.com/...phics_tips/mesh.html
    You are not authorized to post a reply.