Re: Ways to output image to standard out

From: Dave Allured <dave.allured_at_nyahnyahspammersnyahnyah>
Date: Tue Apr 17 2012 - 11:13:34 MDT

NCL is not versatile with stdin and stout. Believe me, I have tried.
How about just using a temp file and doing what is needed in the
shell? Untested pseudo code:

setenv TEMPNAME image.$PID.png
ncl prog.ncl >& /dev/null
   wks = gsn_open_wks("png","$TEMPNAME")
cat $TEMPNAME # this line puts PNG contents to stout
rm $TEMPNAME

--Dave

On Sun, Apr 15, 2012 at 1:21 AM, Harold Chan <cmkgroup@gmail.com> wrote:
>
> Hi all,
>
> Currently, if I output an image to a file, I would write:
>
> wks = gsn_open_wks("png","example")
>
> example.png will be generated.
>
> What If I want to output it to stdout, is it possible? As I would like to
> use it as a CGI program.
>
>
> Thanks,
> Harold
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Apr 17 11:13:45 2012

This archive was generated by hypermail 2.1.8 : Fri Apr 20 2012 - 16:21:18 MDT