.\" This page was automatically generated. Do not edit! .\" .TH PLCALC_WORLD 3plplot "August, 2012" "" "PLplot API" .SH NAME \fBplcalc_world\fP - Calculate world coordinates and corresponding window index from relative device coordinates .SH SYNOPSIS \fBplcalc_world\fP(\fIrx\fP, \fIry\fP, \fIwx\fP, \fIwy\fP, \fIwindow\fP) .SH DESCRIPTION .P Calculate world coordinates, \fIwx\fP and \fIwy\fP, and corresponding \fIwindow\fP index from relative device coordinates, \fIrx\fP and \fIry\fP. .P Redacted form: General: \fBplcalc_world(rx, ry, wx, wy, window)\fP Perl/PDL: Not available? .P This function is used in example 31. .SH ARGUMENTS .TP \fIrx\fP (PLFLT, input) Input relative device coordinate (ranging from 0. to 1.) for the x coordinate. .TP \fIry\fP (PLFLT, input) Input relative device coordinate (ranging from 0. to 1.) for the y coordinate. .TP \fIwx\fP (PLFLT *, output) Pointer to the returned world coordinate for x corresponding to the relative device coordinates \fIrx\fP and \fIry\fP. .TP \fIwy\fP (PLFLT *, output) Pointer to the returned world coordinate for y corresponding to the relative device coordinates \fIrx\fP and \fIry\fP. .TP \fIwindow\fP (PLINT *, output) Pointer to the returned last defined window index that corresponds to the input relative device coordinates (and the returned world coordinates). To give some background on the window index, for each page the initial window index is set to zero, and each time \fBplwind\fP(3plplot) is called within the page, world and device coordinates are stored for the window and the window index is incremented. Thus, for a simple page layout with non-overlapping viewports and one window per viewport, \fIwindow\fP corresponds to the viewport index (in the order which the viewport/windows were created) of the only viewport/window corresponding to \fIrx\fP and \fIry\fP. However, for more complicated layouts with potentially overlapping viewports and possibly more than one window (set of world coordinates) per viewport, \fIwindow\fP and the corresponding output world coordinates corresponds to the last window created that fulfils the criterion that the relative device coordinates are inside it. Finally, in all cases where the input relative device coordinates are not inside any viewport/window, then \fIwindow\fP is set to -1. .SH AUTHORS Geoffrey Furnish and Maurice LeBrun wrote and maintain PLplot. This man page was automatically generated from the DocBook source of the PLplot documentation, maintained by Alan W. Irwin and Rafael Laboissiere. .SH SEE ALSO PLplot documentation at http://plplot.sourceforge.net/resources.