comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Shrinking Image
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Shrinking Image [message #33381] Mon, 23 December 2002 10:10
pushyar is currently offline  pushyar
Messages: 9
Registered: October 2002
Junior Member
Hi..
I tried to create a sphere and then threshold the sphere. The image
after thresholding appears to be smaller. i want it to be in the same
size as the original 3D iamge. I'm not sure if i am scaling it down.
Please help me

Thanks,
Pushya

The code i wrote is attached below:

PRO createsphere
sphere = FltArr(40, 40, 40)
FOR x=0,39 DO FOR y=0,39 DO FOR z=0,39 DO $
sphere(x, y, z) = SQRT((x-20)^2 + (y-20)^2 + (z-20)^2)
Shade_Volume, sphere, 16, vertices, polygons, /LOW, /VERBOSE
Scale3, XRange=[0,40], YRange=[0,40], ZRange=[0,40]
image = PolyShade(vertices, polygons, /T3D)
TV, image
sphere = bytscl(sphere)

threshim = sphere ge 50
help, threshim
threshim = congrid(bytscl(threshim),40,40,40)
;print, threshim
shade_volume, threshim, 20, v, p, /LOW, /VERBOSE
Scale3, XRange=[0,40], YRange=[0,40], ZRange=[0,40]
image1 = PolyShade(v,p, /T3D)
TV, image1
END
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Shrinking Image
Next Topic: Accessing an ASCII database?

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 13:40:09 PDT 2025

Total time taken to generate the page: 0.00540 seconds