Clarisse 5.0 SP8 SDK  5.0.5.8.0
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
Classes | Public Types | Public Member Functions | List of all members
ImageSampler Class Reference

Public Types

enum  PixelSampling {
  PIXEL_SAMPLING_STRATIFIED = 0,
  PIXEL_SAMPLING_STRATIFIED_JITTER,
  PIXEL_SAMPLING_RANDOM,
  PIXEL_SAMPLING_HALTON,
  PIXEL_SAMPLING_HAMMERSLEY,
  PIXEL_SAMPLING_COUNT
}
 
enum  TimeSampling {
  TIME_SAMPLING_NONE = 0,
  TIME_SAMPLING_STRATIFIED,
  TIME_SAMPLING_STRATIFIED_JITTER,
  TIME_SAMPLING_RANDOM,
  TIME_SAMPLING_GOLDEN,
  TIME_SAMPLING_COUNT
}
 

Public Member Functions

void init (const unsigned int &image_width, const unsigned int &image_height, const unsigned int &pixel_width=1, const unsigned int &pixel_height=1, const unsigned int &packet_width=1, const unsigned int &packet_height=1, const unsigned int &image_seed=0, const unsigned int &sample_offset=0, const PixelSampling &pixel_sampling=PIXEL_SAMPLING_STRATIFIED, const SamplingKernel2d *pixel_sampling_kernel=0, const TimeSampling &time_sampling=TIME_SAMPLING_NONE, const GMathLut1d *time_sampling_lut=0)
 Configure the sampler.
 
void set_pixel_sampling (const PixelSampling &pixel_sampling, const SamplingKernel2d *pixel_sampling_kernel=0)
 
void set_time_sampling (const TimeSampling &time_sampling, const GMathLut1d *time_sampling_lut=0)
 
PixelSampling get_pixel_sampling_mode () const
 
TimeSampling get_time_sampling_mode () const
 
const SamplingKernel2dget_pixel_sampling_kernel () const
 
const GMathLut1d * get_time_sampling_lut () const
 
unsigned int get_sampling_dimension () const
 
unsigned int get_sampling_offset () const
 
unsigned int get_pixel_count_x () const
 
unsigned int get_pixel_count_y () const
 
unsigned int get_pixel_count () const
 
unsigned int get_pixel_sample_count_x () const
 
unsigned int get_pixel_sample_count_y () const
 
unsigned int get_pixel_sample_count () const
 
unsigned int get_packet_count_x () const
 
unsigned int get_packet_count_y () const
 
unsigned int get_packet_count () const
 
unsigned int get_packet_pixel_count_x () const
 
unsigned int get_packet_pixel_count_y () const
 
unsigned int get_packet_pixel_count () const
 
unsigned int get_packet_sample_count () const
 
unsigned int get_image_sample_count () const
 
const GMathVec2d & get_pixel_size () const
 
void get_sub_image_bounds (const int &start_x, const int &start_y, const int &end_x, const int &end_y, GMathVec2d &min, GMathVec2d &max) const
 
unsigned int get_pixel_samples (const int &pixel_x, const int &pixel_y, ImageSample<> *samples, GMathVec2d &min, GMathVec2d &max, const unsigned int &sample_offset=0) const
 
unsigned int get_sub_image_samples (const int &start_x, const int &start_y, const int &end_x, const int &end_y, ImageSample<> *samples, GMathVec2d &min, GMathVec2d &max, const unsigned int &sample_offset=0) const
 
unsigned int get_sub_image_samples (const int &start_x, const int &start_y, const int &end_x, const int &end_y, ImageSample<> *samples, GMathVec2d &min, GMathVec2d &max, const unsigned int &sample_offset, const CoreBasicArray< unsigned int > &sample_count, const unsigned int &sample_count_offset, const unsigned int &sample_count_stride) const
 
unsigned int get_sub_quality_samples (const int &start_x, const int &start_y, const int &end_x, const int &end_y, const unsigned int &quality, const bool &skip_even_pixels, ImageSample<> *samples, GMathVec2d &min, GMathVec2d &max, const unsigned int &sample_offset=0) const
 
void get_pixel_samples (const unsigned int &pixel_index, ImageSample<> *samples, GMathVec2d &min, GMathVec2d &max, const unsigned int &sample_offset=0) const
 

Member Function Documentation

void ImageSampler::init ( const unsigned int &  image_width,
const unsigned int &  image_height,
const unsigned int &  pixel_width = 1,
const unsigned int &  pixel_height = 1,
const unsigned int &  packet_width = 1,
const unsigned int &  packet_height = 1,
const unsigned int &  image_seed = 0,
const unsigned int &  sample_offset = 0,
const PixelSampling &  pixel_sampling = PIXEL_SAMPLING_STRATIFIED,
const SamplingKernel2d pixel_sampling_kernel = 0,
const TimeSampling &  time_sampling = TIME_SAMPLING_NONE,
const GMathLut1d *  time_sampling_lut = 0 
)

Configure the sampler.

Parameters
image_widthImage pixel count in X
image_heightImage pixel count in Y
pixel_widthPixel sample count in X (0 must be set if it is not constant over the whole image)
pixel_heightPixel sample count in Y (0 must be set if it is not constant over the whole image)
packet_widthPacket pixel count in X
packet_heightPacket pixel count in Y