Page 1 of 1

Raw+srtm plugin for elevation maps

Posted: Fri Sep 19, 2008 8:40 pm
by cameni
Hi,
I have plugin for reading raw files that contain elevation maps (raw or dem/srtm files).

Almost works now, but I have one problem - since these are raw files without a header, the plugin displays a dialog window first, allowing user to specify the dimensions, bit depth, various flags about the file (integer/floating point data, signedness, endianness) and rendering options (vertical flip, grayscale, clip ranges). The plugin can also autodetect the image dimensions according to the specified types, using correlation test.

However, herein lies the problem - XnView attempts to prefetch the next image, and if that happens to be a .raw file too, another dialog window is displayed as soon as the first file loads.
I wonder, would it be possible to for example to add something like GFP_NOPREFETCH flag to the support member of gfpGetPluginInfo function, that would turn off the prefetching for files with given extension? Or maybe there is some other solution ..

thanks

Re: Raw+srtm plugin for elevation maps

Posted: Sat Sep 20, 2008 7:50 am
by xnview
Perhaps you can disable 'read ahead'?

Posted: Sat Sep 20, 2008 11:48 am
by cameni
Yes I can .. but it affects everything. But I suppose there is no other option unless XnView and its plugin api is modified too :?

Re: Raw+srtm plugin for elevation maps

Posted: Wed Jul 22, 2009 9:15 am
by cameni
For anyone interested, here's the link to the raw/srtm elevation map reader plugin (I have also edited the link in the initial post).
There's also updated version with many fixes and some additional functionality, like automatic range detection and custom color mapping.

Re: Raw+srtm plugin for elevation maps

Posted: Fri Jul 24, 2009 5:19 pm
by oops66
Thank you for the link

Re: Raw+srtm plugin for elevation maps

Posted: Fri Mar 25, 2011 10:15 am
by cameni
Added support for *.hgt extension, removed *.raw that was often conflicting with raw camera formats. Minor fixes.
New version xhgt.zip, description here.

Encountered an interesting problem - XnView refused to load the extension when it was named just "hgt.usr", I had to prefix it with 'x' making it "xhgt.usr", to force loading it.

Re: Raw+srtm plugin for elevation maps

Posted: Wed Sep 07, 2011 9:56 am
by Eduardo
Seeking for *.hgt extension support. Could u please redirect me to the thread it has been already mentioned? TIA.