Changeset 1633
- Timestamp:
- Aug 26, 2004, 1:46:39 PM (22 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
-
archive/pslib/include/psImage.h (modified) (3 diffs)
-
doc/pslib/ChangeLogSDRS.tex (modified) (1 diff)
-
doc/pslib/psLibSDRS.tex (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/archive/pslib/include/psImage.h
r1585 r1633 80 80 /** Direction in which to cut */ 81 81 typedef enum { 82 PS_CUT_X_POS, ///< Cut in positive x direction83 PS_CUT_X_NEG, ///< Cut in negative x direction84 PS_CUT_Y_POS, ///< Cut in positive y direction85 PS_CUT_Y_NEG ///< Cut in negative y direction82 PS_CUT_X_POS, ///< Cut in positive x direction 83 PS_CUT_X_NEG, ///< Cut in negative x direction 84 PS_CUT_Y_POS, ///< Cut in positive y direction 85 PS_CUT_Y_NEG ///< Cut in negative y direction 86 86 } psImageCutDirection; 87 87 … … 89 89 psVector * 90 90 psImageSlice(psVector *out, ///< Vector to output, or NULL 91 psVector *coords, ///< Returned coordinates along the slice, or NULL92 91 const psImage *input, ///< Input image 93 92 const psImage *mask, ///< Ignore those pixels where mask & maskVal == 1. May be NULL 94 93 unsigned int maskVal, ///< Value in mask to ignore 95 unsigned int x, ///< starting x coord of region to slice96 unsigned int y, ///< starting y coord of region to slice97 unsigned int nx, ///< length of region in x98 unsigned int ny, ///< length of region in y94 unsigned int x, ///< starting x coord of region to slice 95 unsigned int y, ///< starting y coord of region to slice 96 unsigned int nx, ///< length of region in x 97 unsigned int ny, ///< length of region in y 99 98 psImageCutDirection direction, ///< Direction in which to cut 100 const psStats *stats ///< defines statistics used to find output values99 const psStats *stats ///< defines statistics used to find output values 101 100 ); 102 101 … … 111 110 float xe, ///< ending x coord of cut 112 111 float ye, ///< ending y coord of cut 113 float dw, ///< width of cut114 const psStats *stats)///< defines statistics used to find output values115 ;112 unsigned int nSamples, ///< Number of samples along the slice 113 psImageInterpolateMode mode ///< defines statistics used to find output values 114 ); 116 115 117 116 /// Extract radial annulii data to a vector. -
trunk/doc/pslib/ChangeLogSDRS.tex
r1620 r1633 252 252 \item Added function \code{psTimeLeapSeconds} to calculate number of 253 253 leap seconds between two dates, required for time arithmetic. 254 \item Changed \code{psImageCut} to do a slice through the data in an 255 arbitrary direction, instead of merging the data along a particular 256 dimension. 254 257 \end{itemize} -
trunk/doc/pslib/psLibSDRS.tex
r1632 r1633 1 %%% $Id: psLibSDRS.tex,v 1.8 6 2004-08-26 21:43:50price Exp $1 %%% $Id: psLibSDRS.tex,v 1.87 2004-08-26 23:46:13 price Exp $ 2 2 \documentclass[panstarrs,spec]{panstarrs} 3 3 … … 2341 2341 \begin{verbatim} 2342 2342 typedef enum { 2343 PS_CUT_X_POS, 2344 PS_CUT_X_NEG, 2345 PS_CUT_Y_POS, 2346 PS_CUT_Y_NEG 2343 PS_CUT_X_POS, ///< Cut in positive x direction 2344 PS_CUT_X_NEG, ///< Cut in negative x direction 2345 PS_CUT_Y_POS, ///< Cut in positive y direction 2346 PS_CUT_Y_NEG ///< Cut in negative y direction 2347 2347 } psImageCutDirection; 2348 2348 2349 psVector *psImageSlice(psVector *out, 2349 psVector *psImageSlice(psVector *out, 2350 2350 psVector *coords, 2351 const psImage *input, 2352 const psImage *mask, 2351 const psImage *input, 2352 const psImage *mask, 2353 2353 unsigned int maskVal, 2354 unsigned int x, 2355 unsigned int y, 2356 unsigned int nx, 2357 unsigned int ny, 2358 psImageCutDirection direction, 2359 const psStats *stats);2354 unsigned int x, 2355 unsigned int y, 2356 unsigned int nx, 2357 unsigned int ny, 2358 psImageCutDirection direction, 2359 const psStats *stats); 2360 2360 \end{verbatim} 2361 2361 Extract pixels from rectlinear region to a vector (array of floats). … … 2375 2375 \begin{verbatim} 2376 2376 psVector *psImageCut(psVector *out, const psImage *input, 2377 const psImage *mask, 2378 unsigned int maskVal, 2377 const psImage *mask, unsigned int maskVal, 2379 2378 float xs, float ys, float xe, float ye, 2380 float dw, const psStats *stats); 2381 \end{verbatim} 2382 Extract pixels from an image along a line to a vector (array of 2383 floats). The vector \code{(xs,ys)} - \code{(xe,ye)} forms the basis 2384 of the output vector. Pixels are considered in a rectangular region 2385 of width \code{dw} about this vector. The input region is collapsed 2386 in the perpendicular direction, and each element of the output vector 2387 represents pixel-sized boxes, where the value is derived from the 2388 statistics of the pixels interpolated along the perpendicular 2389 direction. The specific algorithm which must be used is described in 2390 the PSLib ADD (PSDC-430-006). The statistic used to derive the output 2391 vector value is specified by \code{stats}. Only one of the statistics 2392 choices may be specified, otherwise the function must return an error. 2393 The \code{mask} and \code{maskVal} entries are passed to the psLib 2394 statistics function used to calculate the ensemble statistics. This 2395 function must be defined for the following types: \code{psS8}, 2396 \code{psU16}, \code{psF32}, \code{psF64} 2379 unsigned int nSamples, psImageInterpolateMode mode); 2380 \end{verbatim} 2381 Extract pixels along a line segment, \code{(xs,ys)} to \code{(xe,ye)}, 2382 on the image to a vector (array of the appropriate data type). The 2383 line segment is sampled \code{nSamples} times, hence the output vector 2384 contains \code{nSamples} elements. The interpolation method used to 2385 derive the output vector value at each sample along the line segment 2386 is specified by \code{mode}. If the \code{mask} is non-\code{NULL}, 2387 then pixels for which the corresponding mask value is \code{maskVal} 2388 are not included in the interpolation. This function must be defined 2389 for the following types: \code{psS8}, \code{psU16}, \code{psF32}, 2390 \code{psF64}. 2397 2391 2398 2392 \begin{verbatim}
Note:
See TracChangeset
for help on using the changeset viewer.
