[Thread Prev][Thread Next][Index]

Re: custom.pl



Hi John,

The size is sent as a Ferret property; you can get to it in the init method, for instance, as follows:

my $size = $req->getProperties('ferret')->{size};

This API is not documented in the version of LAS you are using; it will be in the next release (coming soon!). If you want an idea of how to use the API, check out the init method in Ferret.pl.

That's the good news. The bad news is that the 2d window size is reduced to a 1D parameter by the user interface (for some reason, Ferret uses a 1D number that is proportional to the *area* of the window to specify window size), so some information is lost. The formula used is:

size = xwidth*ywidth/960000

so, for instance, a 800X600 window gives you a size of 0.5

At 02:29 PM 1/24/2002 -0700, John C Cartwright wrote:
Hello All,

I'm trying to add a new visualization program to LAS and looking at the example in the manual. Specifically, I'm looking at the code for custom.pl. I see how I can grab the geographic range from the request, but am wondering how to get the user-specified window size.

I am also confused here because, I understood that a LAS::Request object is being passed into the init() method and I see a getChildren() method being used but cannot locate it the documention for this type of object.

Thanks for any help!


-- john

=====================================================
John Cartwright
Professional Research Assistant / Associate Scientist
CIRES, SEG/NGDC/NOAA
(303) 497-6284
jcartwright@ngdc.noaa.gov
=====================================================





[Thread Prev][Thread Next][Index]

Dept of Commerce / NOAA / OAR / PMEL / TMAP
Contact Us | Privacy Policy | Disclaimer | Accessibility Statement