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

Home » Public Forums » archive » Re: Object Graphics: Black Box
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Object Graphics: Black Box [message #26467 is a reply to message #26466] Thu, 23 August 2001 12:15 Go to previous messageGo to previous message
Adam Rankin is currently offline  Adam Rankin
Messages: 15
Registered: July 2001
Junior Member
> Adam Rankin (arankin@irus.rri.on.ca) writes:
>>
>> A fun one to throw at you...
>> I load a widget_draw and give it the GRAPHICS_LEVEL=2 keyword...
>> I make an IDLgrImage,IDLgrModel,IDLgrView and a IDLgrScene
>> and add them appropriately using data retrieved by READ_DICOM
>> (I tested the data with TVSCL and it works)
>> but when I load it into this draw widget all that appears is a black box!
>>
>> Any suggestions?
>
> Uh, you are looking at the first pixel in the image. :-)
>
> But don't worry, this is almost inevitably
> what new object graphics users look at
> when they first start. (If they can see
> *anything* in their window.)
>
> You have to make the arbitrary coordinatee system
> of the viewplane rectangle match the coordinate
> system of the image. In your case, I would probably
> try setting the viewplane rectangle like this:
>
> oImageView = obj_new('IDLgrView', $
> VIEWPLANE_RECT=[0,0,128,128])
>
> Assuming the image is 128 by 128, that will fill
> the image up in the window. (Which may or may not
> be what you want.) But at least you will see
> *something*, which is always half the battle with
> object graphics. :-)
>
> If you want another example, see my XImage program
> here:
>
> http://www.dfanning.com/programs/ximage.pro
>
> Cheers,
>
> David
>
> --
> David W. Fanning, Ph.D.
> Fanning Software Consulting
> Phone: 970-221-0438, E-mail: david@dfanning.com
> Coyote's Guide to IDL Programming: http://www.dfanning.com/
> Toll-Free IDL Book Orders: 1-888-461-0155

Once again, another problem solved.
Of course it worked and I can see the image wonderfully...
Thanks for your help.

-Adam

(oh and I got a good kick out of the fact that you can easily recognize a
newbie object graphic programmer.)~
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: "private" and "public" attributes in IDL.
Next Topic: file directory

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

Current Time: Sat Oct 11 02:01:36 PDT 2025

Total time taken to generate the page: 0.55578 seconds