libopenraw  0.3.7
Functions

Access the raw data. More...

Functions

or_error or_get_extract_rawdata (const char *filename, uint32_t options, ORRawDataRef *rawdata)
 Extract the RAW data from the raw file. More...
 
ORRawDataRef or_rawdata_new (void)
 Allocate a new RawData. More...
 
or_error or_rawdata_release (ORRawDataRef rawdata)
 Release the rawdata.
 
or_data_type or_rawdata_format (ORRawDataRef rawdata)
 Get the format of the RAW data.
 
void * or_rawdata_data (ORRawDataRef rawdata)
 Get a pointer to the RAW data. More...
 
size_t or_rawdata_data_size (ORRawDataRef rawdata)
 Get the size of the RAW data in bytes.
 
void or_rawdata_dimensions (ORRawDataRef rawdata, uint32_t *x, uint32_t *y)
 Get the RAW data dimensions in pixels. More...
 
or_error or_rawdata_get_active_area (ORRawDataRef rawdata, uint32_t *x, uint32_t *y, uint32_t *width, uint32_t *height)
 Get the active area for the raw data. More...
 
uint32_t or_rawdata_bpc (ORRawDataRef rawdata)
 Return the bits per component. More...
 
or_cfa_pattern or_rawdata_get_cfa_pattern_type (ORRawDataRef rawdata)
 Return the bayer type for the raw data. More...
 
ORMosaicInfoRef or_rawdata_get_mosaicinfo (ORRawDataRef rawdata)
 Return the mosaic info. More...
 
uint32_t or_rawdata_get_compression (ORRawDataRef rawdata)
 Return the compression type for the RawData. More...
 
or_error or_rawdata_get_levels (ORRawDataRef rawdata, uint16_t *black, uint16_t *white)
 Return the levels values for the raw data. More...
 
const double * or_rawdata_get_colour_matrix (ORRawDataRef rawdata, uint32_t index, uint32_t *size)
 Get the colour matrix. More...
 
or_error or_rawdata_get_rendered_image (ORRawDataRef rawdata, ORBitmapDataRef bitmapdata, uint32_t options)
 Get the rendered image from the raw data. More...
 

Detailed Description

Access the raw data.

Function Documentation

◆ or_get_extract_rawdata()

or_error or_get_extract_rawdata ( const char *  filename,
uint32_t  options,
ORRawDataRef rawdata 
)

Extract the RAW data from the raw file.

Parameters
filenamethe raw file name
optionsthe options to pass
rawdatathe destination RawData. Must allocated.

Definition at line 51 of file rawdata.cpp.

References OR_ERROR_NONE.

◆ or_rawdata_bpc()

uint32_t or_rawdata_bpc ( ORRawDataRef  rawdata)

Return the bits per component.

Returns
the number of bits per component in the RAW data.

Definition at line 130 of file rawdata.cpp.

◆ or_rawdata_data()

void* or_rawdata_data ( ORRawDataRef  rawdata)

Get a pointer to the RAW data.

The pointer is owned by the RawData object.

Definition at line 85 of file rawdata.cpp.

◆ or_rawdata_dimensions()

void or_rawdata_dimensions ( ORRawDataRef  rawdata,
uint32_t *  x,
uint32_t *  y 
)

Get the RAW data dimensions in pixels.

Parameters
[out]xthe horizontal dimension
[out]ythe vertical dimension

Definition at line 97 of file rawdata.cpp.

References OpenRaw::BitmapData::height(), and OpenRaw::BitmapData::width().

◆ or_rawdata_get_active_area()

or_error or_rawdata_get_active_area ( ORRawDataRef  rawdata,
uint32_t *  x,
uint32_t *  y,
uint32_t *  width,
uint32_t *  height 
)

Get the active area for the raw data.

The active area is the usefull part of the RAW data it is specific per camera and isn't the crop.

Parameters
rawdatathe RawData object
[out]xthe X origin
[out]ythe Y origin
[out]widththe width
[out]heightthe height.
Returns
an error code or OR_ERROR_NONE in case of success.

Definition at line 110 of file rawdata.cpp.

References OpenRaw::RawData::activeAreaX(), and OR_ERROR_NONE.

◆ or_rawdata_get_cfa_pattern_type()

or_cfa_pattern or_rawdata_get_cfa_pattern_type ( ORRawDataRef  rawdata)

Return the bayer type for the raw data.

Returns
one of the constant defined in or_cfa_pattern

Definition at line 136 of file rawdata.cpp.

◆ or_rawdata_get_colour_matrix()

const double* or_rawdata_get_colour_matrix ( ORRawDataRef  rawdata,
uint32_t  index,
uint32_t *  size 
)

Get the colour matrix.

Parameters
rawdatathe raw data object
indexthe matrix index.
[out]sizeof matrix. Returns the actual size.
Returns
the matrix. Pointer is owned by the RawData.

Definition at line 168 of file rawdata.cpp.

References OpenRaw::RawData::getColourMatrix1(), and OpenRaw::RawData::getColourMatrix2().

◆ or_rawdata_get_compression()

uint32_t or_rawdata_get_compression ( ORRawDataRef  rawdata)

Return the compression type for the RawData.

Returns
the numerical value.

Definition at line 148 of file rawdata.cpp.

◆ or_rawdata_get_levels()

or_error or_rawdata_get_levels ( ORRawDataRef  rawdata,
uint16_t *  black,
uint16_t *  white 
)

Return the levels values for the raw data.

These are possible values, not actual values.

Parameters
rawdatathe raw data object
[out]blackthe pointer to the black value.
[out]whitethe pointer to the white value.
Returns
the error code.

Definition at line 154 of file rawdata.cpp.

References OR_ERROR_NONE.

◆ or_rawdata_get_mosaicinfo()

ORMosaicInfoRef or_rawdata_get_mosaicinfo ( ORRawDataRef  rawdata)

Return the mosaic info.

Returns
a MosaicInfo object. It is owned by the RawData. Can't be NULL.

Definition at line 142 of file rawdata.cpp.

◆ or_rawdata_get_rendered_image()

or_error or_rawdata_get_rendered_image ( ORRawDataRef  rawdata,
ORBitmapDataRef  bitmapdata,
uint32_t  options 
)

Get the rendered image from the raw data.

Parameters
rawdatathe raw data.
bitmapdatathe preallocated bitmap data.
optionsoption for rendering. Pass 0 for now.
Returns
an error code, OR_ERROR_NONE in case of success.

Definition at line 200 of file rawdata.cpp.

References OpenRaw::RawData::getRenderedImage(), and OR_ERROR_NOTAREF.

◆ or_rawdata_new()

ORRawDataRef or_rawdata_new ( void  )

Allocate a new RawData.

Returns
A newly allocated RawData. Must be released by or_rawdata_release

Definition at line 62 of file rawdata.cpp.