|
From: Ethan A M. <merritt@u.washington.edu> - 2005-11-14 00:00:25
|
On Sunday 13 November 2005 01:36 am, Daniel J Sebald wrote:
>
> Attached is a patch for AVS format (*.avs *.x).
Very nice.
With some minor tweaking, I think this should go into cvs.
> Here are some sample commands:
>
> set datafile binary filetype=auto
> plot "mandrill.x" binary with rgbimage
Or in my case
set datafile binary filetype=avs
plot "< convert ~/images/photo.jpeg avs:-" binary with rgbimage
That works. But these variants don't:
set datafile binary filetype=avs
set style data rgbimage
plot "< convert ~/images/photo.jpeg avs:-" with rgbimage
warning: Skipping data file with no valid points
x range is invalid
plot "< convert ~/images/photo.jpeg avs:-" binary
Read grid of zero width
I don't think these failures have anything to do with the patch,
however. I think the binary and rgbimage modes are not correctly
picked up from the default style in any case.
> This comes with a no warranty.
> If you have some tweaks, let me know.
Unfortunately, AVS format does not guarantee any particular byte order.
You normally get whatever byte order is native to the machine the image
was created on. Therefore any application that reads AVS images should
check for sanity of the xwidth and ywidth values at the head of the file,
and try a different byte ordering if they are absurd.
--
Ethan A Merritt
Biomolecular Structure Center
University of Washington, Seattle 98195-7742
|