ocssw
V2022
|
Functions | |
int | epr_read_bitmask_raster (EPR_SProductId *product_id, const char *bm_expr, int offset_x, int offset_y, EPR_SRaster *raster) |
Detailed Description
Function Documentation
◆ epr_read_bitmask_raster()
int epr_read_bitmask_raster | ( | EPR_SProductId * | product_id, |
const char * | bm_expr, | ||
int | offset_x, | ||
int | offset_y, | ||
EPR_SRaster * | bm_raster | ||
) |
Calculates a bit-mask, composed of flags of the given product and combined as described in the given bit-mask expression, for the a certain dimension and sub-sampling as defined in the given raster.
- Parameters
-
product_id Identifier of the ENVISAT product for which the bit-mask shall be created. This is used by the function to retreive the needed flags. bm_expr A string holding the logical expression for the defintion of the bit-mask. In a bit-mask expression, any number of the flag-names (found in the DDDB) can be composed with "(", ")", "NOT", "AND", "OR". Valid bit-mask expression are for example:
"flags.LAND OR flags.CLOUD" or "NOT flags.WATER AND flags.TURBID_S".offset_x across-track co-ordinate in pixel co-ordinates (zero-based) of the upper right corner of the source-region offset_y along-track co-ordinate in pixel co-ordinates (zero-based) of the upper right corner of the source-region raster the raster for the bit-mask. The data type of the raster must be either e_tid_uchar or e_tid_char.
- Returns
- zero for success, an error code otherwise
- See also
- create_band_raster
Reads bit-mask pixels of the given product for the given bit-mask expression for the given region offset and raster.
- Parameters
-
product_id the product ID bm_expr the bit-mask expression offset_x X-coordinate in pixel co-ordinates (zero-based) of the upper right raster corner to be searched for offset_y Y-coordinate in pixel co-ordinates (zero-based) of the upper right raster corner to be searched for raster the instance to the buffer information was used
- Returns
- zero for success, an error code otherwise
Definition at line 99 of file epr_bitmask.c.