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

Home » Public Forums » archive » Re: missing a dimension in IDLgrVolume
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
Re: missing a dimension in IDLgrVolume [message #33974] Wed, 12 February 2003 01:59 Go to next message
s[1] is currently offline  s[1]
Messages: 21
Registered: December 2002
Junior Member
Hey,

it's the minus in the rotator's position, this one will work:
Rotator = OBJ_NEW('IDLexRotator', [image_size/2.0, $
image_size/2.0], image_size/2)

You didn't just copy'n'paste the Viewplane_Rect to the Rotator, did you?
:-)


Sebastian


On Wed, 12 Feb 2003, Thomas Gutzler wrote:

> Hey,
>
> can anybody tell me, what I'm doing wrong ?
> I'm comparing the code for 2 hours now and I don't get it.
> Seems to having lost the z-dimension :(
> I can rotate the Volume only in 1 dimension but I really need the
> others, too!
>
> here we go (requires IDLexRotator):
>
> PRO TDVol_Event, event
> WIDGET_CONTROL, event.top, Get_UValue=info
> IF (*info).Rotator->Update(event) THEN $
> (*info).oWindow->Draw, (*info).View
> END
>
> PRO TDVol_Cleanup, tlb
> WIDGET_CONTROL, tlb, Get_UValue=info
> OBJ_DESTROY, (*info).View
> OBJ_DESTROY, (*info).oWindow
> OBJ_DESTROY, (*info).Rotator
> OBJ_DESTROY, (*info).volume
> PTR_FREE, info
> END
>
> PRO vol_test
> image_size=200
> tmp = BYTSCL(dist(image_size))
> images = BYTARR(image_size, image_size, 10)
> FOR i=0,9 DO images[*,*,i] = tmp
>
> View = OBJ_NEW('IDLgrView', Viewplane_Rect=[-image_size/2.0, $
> -image_size/2.0, image_size, image_size])
> RotMod = OBJ_NEW('IDLgrModel')
> Rotator = OBJ_NEW('IDLexRotator', [-image_size/2.0, $
> -image_size/2.0], image_size/2)
> volume = OBJ_NEW('IDLgrVolume', images, $
> XCOORD_CONV=[-image_size/2.0, 1], $
> YCOORD_CONV=[-image_size/2.0, 1], /NO_COPY)
>
> View->Add, Rotator
> Rotator->Add, RotMod
> RotMod->Add, volume
>
> TLB = WIDGET_BASE()
> drawID = WIDGET_DRAW(TLB, XSize=image_size, YSize=image_size, $
> /button_events, /motion_events, graphics_level=2)
>
> WIDGET_CONTROL, TLB, /Realize
> WIDGET_CONTROL, drawID, Get_Value=oWindow
> oWindow->Draw, View
>
> info = PTR_NEW({ View:View, oWindow:oWindow, $
> Rotator:Rotator, volume:volume})
>
> WIDGET_CONTROL, TLB, Set_UValue=info
> XMANAGER, 'TDVol_Viewer', TLB, EVENT_HANDLER='TDVol_Event', $
> CLEANUP='TDVol_Cleanup', /NO_BLOCK
> END
>
>
Re: missing a dimension in IDLgrVolume [message #34051 is a reply to message #33974] Wed, 12 February 2003 17:23 Go to previous message
Thomas Gutzler is currently offline  Thomas Gutzler
Messages: 44
Registered: November 2002
Member
Sebastian wrote:
> Hey,
>
> it's the minus in the rotator's position, this one will work:
> Rotator = OBJ_NEW('IDLexRotator', [image_size/2.0, $
> image_size/2.0], image_size/2)
>
> You didn't just copy'n'paste the Viewplane_Rect to the Rotator, did you?
> :-)

No, i didn't. Honestly :)

Thanx,
Tom
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: IDL 5.6: are file_copy and file_move atomic?
Next Topic: IDL objects and names

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

Current Time: Wed Oct 08 13:26:24 PDT 2025

Total time taken to generate the page: 0.00467 seconds