PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ rt_raster_get_phys_params()

void rt_raster_get_phys_params ( rt_raster  rast,
double *  i_mag,
double *  j_mag,
double *  theta_i,
double *  theta_ij 
)

Calculates and returns the physically significant descriptors embodied in the geotransform attached to the provided raster.

Parameters
rastthe raster containing the geotransform of interest
i_magsize of a pixel along the transformed i axis
j_magsize of a pixel along the transformed j axis
theta_iangle by which the raster is rotated (radians positive clockwise)
theta_ijangle from transformed i axis to transformed j axis (radians positive counterclockwise)

Definition at line 231 of file rt_raster.c.

233 {
234  double o11, o12, o21, o22 ; /* geotransform coefficients */
235 
236  if (rast == NULL) return ;
237  if ( (i_mag==NULL) || (j_mag==NULL) || (theta_i==NULL) || (theta_ij==NULL))
238  return ;
239 
240  /* retrieve coefficients from raster */
241  o11 = rt_raster_get_x_scale(rast) ;
242  o12 = rt_raster_get_x_skew(rast) ;
243  o21 = rt_raster_get_y_skew(rast) ;
244  o22 = rt_raster_get_y_scale(rast) ;
245 
246  rt_raster_calc_phys_params(o11, o12, o21, o22, i_mag, j_mag, theta_i, theta_ij);
247 }
return(const char *)
Definition: dbfopen.c:1613
double rt_raster_get_x_skew(rt_raster raster)
Get skew about the X axis.
Definition: rt_raster.c:181
double rt_raster_get_x_scale(rt_raster raster)
Get scale X in projection units.
Definition: rt_raster.c:150
double rt_raster_get_y_scale(rt_raster raster)
Get scale Y in projection units.
Definition: rt_raster.c:159
double rt_raster_get_y_skew(rt_raster raster)
Get skew about the Y axis.
Definition: rt_raster.c:190
void rt_raster_calc_phys_params(double xscale, double xskew, double yskew, double yscale, double *i_mag, double *j_mag, double *theta_i, double *theta_ij)
Calculates the physically significant descriptors embodied in an arbitrary geotransform.
Definition: rt_raster.c:250

References rtpixdump::rast, return(), rt_raster_calc_phys_params(), rt_raster_get_x_scale(), rt_raster_get_x_skew(), rt_raster_get_y_scale(), and rt_raster_get_y_skew().

Referenced by RASTER_setRotation().

Here is the call graph for this function:
Here is the caller graph for this function: