re-printim
Arlindo da Silva
arlindo.dasilva at GMAIL.COM
Thu Nov 19 23:15:09 EST 2009
On Thu, Nov 19, 2009 at 5:15 PM, Daniel MAINEULT <daniel.maineult at neuf.fr>wrote:
> Dear Mike,
>
> me work under linux Fedora 11
> I have the problem with the two following versions:
>
> grads 2.0.a7 and opengrads 2.0.a5.oga.5
>
> Impossible to use a resolution 720*576 or 960*576 the transparency doesn't
> function
> but with 800*640 it is ok.
> I need to use formats broadcasts.
>
>
The command version of* gxyat* has a more flexible transparency capability
which allows each color you define to have its own transparency level (the
so-called alpha channel). In particular, it can emulate the -t option of
printim and it does work with any resolution. Here is an example:
ga-> open model
ga-> set_rgba 60 125 125 125 0 1
ga-> set ccols 1 2 3 4 5 6 60 t.
ga-> set clevs 500 600 700 800 900 1000
ga-> d ps
ga-> gxyat -x 1600 -y 1200 img.png
As a bonus, you get anti-aliased fonts. Here is the syntax of the
set_rgbacommand that Pablo Romero contributed:
NAME
set_rgba - define color including alpha channel
SYNOPSIS
set_rgba color red green blue alpha [mask]
DESCRIPTION
This User Defined Command (UDC) defines *color* given its
RGB triplet along with its *alpha* channel.
color integer in the range [16-255]
red,
green,
blue integers in the range [0-255]
alpha float, with alpha ranging from 0.0 (fully transparent)
to 1.0 (fully opaque).
The optional parameter *mask* determines whether the color below
it is visible or not.
mask=0 --- if alpha<1, *color* will be semi-transparent and the
colors below it will be visible (default)
mask=1 --- if alpha<1, *color* will be semi-transparent but the
colors below it will *not* be visible
EXAMPLE
In order to emulate the -t option in printim
ga-> set rgb 60 125 125 125
ga-> printim img.png -t 60
Specify alpha=0 and mask=1
ga-> set_rgba 60 125 125 125 0 1
ga-> gxyat img.png
--
Arlindo da Silva
dasilva at alum.mit.edu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20091119/efd7d170/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: img.png
Type: image/png
Size: 271178 bytes
Desc: not available
Url : http://gradsusr.org/pipermail/gradsusr/attachments/20091119/efd7d170/attachment.png
More information about the gradsusr
mailing list