Re: wkPDFResolution

From: Fred Clare <fredclare_at_nyahnyahspammersnyahnyah>
Date: Sat, 23 May 2009 13:15:31 -0600

On May 12, 2009, at 7:47 AM, Hahmann, Andrea N. wrote:

> Hello
>
> I was wondering if anybody has used the wks resource
> wkPDFResolution. I
> have tried to increase it (e.g. from 1800 to 3600 or larger) to
> generate a
> higher resolution pdf file, but the size of the file remains
> unchanged. Any
> ideas?

We have looked into this and I thought it would be good to summarize
the results, for the record.

In most cases changing the value of the wkPDFResolution resource will
not affect the size of the PDF file produced. One thing that changes
in the PDF file is a scale factor that is applied to how the
coordinates are calculated. For example, in the case of going from
setting PDFResolution from 1800 to 3600, the scale factor goes from
0.03846 to half that. The scale factor in the output PDF will always
be in a %7.5f format, so there would be no difference in size. And
the coordinates are always produced in a %6d format which would
accommodate PDFResolutions of up to around 50000. PDF files are ASCII
files, if you do a diff on the files produced between using
PDFResolutions of 1800 vs. 3600, you should see the differences.

The recommended ways to set a value for wkPDFResolution are either:

type = "pdf"
type_at_wkPDFResolution = 3600
wks = gsn_open_wks(type,"gsun01n")

if using a gsun open, or

xworkid = create "xy01Work" pdfWorkstationClass defaultapp
"wkPDFResolution" : 3600
"wkPDFFileName" : "xy01n.pdf"
end create

For certain technical reasons, setting a value for wkPDFResolution in
an external .res file will not change the resolution from its default
setting.

Fred Clare

>
>
> Thanks
> Andrea
> --
>
> Andrea N. Hahmann
> Senior Scientist
>
> Phone direct +45 4677 5471
> andrea.n.hahmann_at_risoe.dk
>
> Wind energy Division
> Risø National Laboratory for Sustainable Energy
> Technical University of Denmark – DTU
> Building 114, P.O. Box 49
> DK-4000 Roskilde, Denmark
> Tel +45 4677 5471
> Fax +45 4677 5083
> www.risoe.dtu.dk
>
>
> _______________________________________________
> 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 Sat May 23 2009 - 13:15:31 MDT

This archive was generated by hypermail 2.2.0 : Mon Jun 01 2009 - 07:47:28 MDT