Openholo  v4.2
Open Source Digital Holographic Library
ophPAS_GPU Class Reference

#include <ophPAS_GPU.h>

Inheritance diagram for ophPAS_GPU:
Collaboration diagram for ophPAS_GPU:

Public Member Functions

 ophPAS_GPU ()
 
bool readConfig (const char *fname)
 
int loadPoint (const char *_filename)
 
int save (const char *fname, uint8_t bitsperpixel, uchar *src, uint px, uint py)
 
void save (const char *fname)
 
char * trim (char *s)
 
char * ltrim (char *s)
 
char * rtrim (char *s)
 
void PASCalculation (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void PAS (long voxelnum, OphPointCloudData *data, double *m_pHologram, OphPointCloudConfig &conf)
 
void DataInit (int segsize, int cghwidth, int cghheight, float xiinter, float etainter)
 
void DataInit (OphPointCloudConfig &conf)
 
void MemoryRelease (void)
 
void generateHologram ()
 
void PASCalculation_GPU (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void CalcSpatialFrequency (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, float *sf_cx, float *sf_cy, int *pp_cx, int *pp_cy, int *cf_cx, int *cf_cy, float xiint, float etaint, OphPointCloudConfig &conf)
 
void CalcCompensatedPhase (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, int *cf_cx, int *cf_cy, float *COStbl, float *SINtbl, float **inRe, float **inIm, OphPointCloudConfig &conf)
 
void RunFFTW (int segnumx, int segnumy, int segsize, int hsegsize, float **inRe, float **inIm, fftw_complex *in, fftw_complex *out, fftw_plan *plan, double *pHologram, OphPointCloudConfig &conf)
 
void encodeHologram (const vec2 band_limit, const vec2 spectrum_shift)
 
void encoding (unsigned int ENCODE_FLAG)
 
 ophPAS_GPU ()
 
bool readConfig (const char *fname)
 
int loadPoint (const char *_filename)
 
int save (const char *fname, uint8_t bitsperpixel, uchar *src, uint px, uint py)
 
void save (const char *fname)
 
char * trim (char *s)
 
char * ltrim (char *s)
 
char * rtrim (char *s)
 
void PASCalculation (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void PAS (long voxelnum, OphPointCloudData *data, double *m_pHologram, OphPointCloudConfig &conf)
 
void DataInit (int segsize, int cghwidth, int cghheight, float xiinter, float etainter)
 
void DataInit (OphPointCloudConfig &conf)
 
void MemoryRelease (void)
 
void generateHologram ()
 
void PASCalculation_GPU (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void CalcSpatialFrequency (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, float *sf_cx, float *sf_cy, int *pp_cx, int *pp_cy, int *cf_cx, int *cf_cy, float xiint, float etaint, OphPointCloudConfig &conf)
 
void CalcCompensatedPhase (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, int *cf_cx, int *cf_cy, float *COStbl, float *SINtbl, float **inRe, float **inIm, OphPointCloudConfig &conf)
 
void RunFFTW (int segnumx, int segnumy, int segsize, int hsegsize, float **inRe, float **inIm, fftw_complex *in, fftw_complex *out, fftw_plan *plan, double *pHologram, OphPointCloudConfig &conf)
 
void encodeHologram (const vec2 band_limit, const vec2 spectrum_shift)
 
void encoding (unsigned int ENCODE_FLAG)
 
 ophPAS_GPU ()
 
bool readConfig (const char *fname)
 
int loadPoint (const char *_filename)
 
int save (const char *fname, uint8_t bitsperpixel, uchar *src, uint px, uint py)
 
void save (const char *fname)
 
char * trim (char *s)
 
char * ltrim (char *s)
 
char * rtrim (char *s)
 
void PASCalculation (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void PAS (long voxelnum, OphPointCloudData *data, double *m_pHologram, OphPointCloudConfig &conf)
 
void DataInit (int segsize, int cghwidth, int cghheight, float xiinter, float etainter)
 
void DataInit (OphPointCloudConfig &conf)
 
void MemoryRelease (void)
 
void generateHologram ()
 
void PASCalculation_GPU (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void CalcSpatialFrequency (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, float *sf_cx, float *sf_cy, int *pp_cx, int *pp_cy, int *cf_cx, int *cf_cy, float xiint, float etaint, OphPointCloudConfig &conf)
 
void CalcCompensatedPhase (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, int *cf_cx, int *cf_cy, float *COStbl, float *SINtbl, float **inRe, float **inIm, OphPointCloudConfig &conf)
 
void RunFFTW (int segnumx, int segnumy, int segsize, int hsegsize, float **inRe, float **inIm, fftw_complex *in, fftw_complex *out, fftw_plan *plan, double *pHologram, OphPointCloudConfig &conf)
 
void encodeHologram (const vec2 band_limit, const vec2 spectrum_shift)
 
void encoding (unsigned int ENCODE_FLAG)
 
 ophPAS_GPU ()
 
bool readConfig (const char *fname)
 
int loadPoint (const char *_filename)
 
int save (const char *fname, uint8_t bitsperpixel, uchar *src, uint px, uint py)
 
void save (const char *fname)
 
char * trim (char *s)
 
char * ltrim (char *s)
 
char * rtrim (char *s)
 
void PASCalculation (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void PAS (long voxelnum, OphPointCloudData *data, double *m_pHologram, OphPointCloudConfig &conf)
 
void DataInit (int segsize, int cghwidth, int cghheight, float xiinter, float etainter)
 
void DataInit (OphPointCloudConfig &conf)
 
void MemoryRelease (void)
 
void generateHologram ()
 
void PASCalculation_GPU (long voxnum, unsigned char *cghfringe, OphPointCloudData *data, OphPointCloudConfig &conf)
 
void CalcSpatialFrequency (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, float *sf_cx, float *sf_cy, int *pp_cx, int *pp_cy, int *cf_cx, int *cf_cy, float xiint, float etaint, OphPointCloudConfig &conf)
 
void CalcCompensatedPhase (float cx, float cy, float cz, float amp, int segnumx, int segnumy, int segsize, int hsegsize, float sf_base, float *xc, float *yc, int *cf_cx, int *cf_cy, float *COStbl, float *SINtbl, float **inRe, float **inIm, OphPointCloudConfig &conf)
 
void RunFFTW (int segnumx, int segnumy, int segsize, int hsegsize, float **inRe, float **inIm, fftw_complex *in, fftw_complex *out, fftw_plan *plan, double *pHologram, OphPointCloudConfig &conf)
 
void encodeHologram (const vec2 band_limit, const vec2 spectrum_shift)
 
void encoding (unsigned int ENCODE_FLAG)
 
- Public Member Functions inherited from ophGen
 ophGen (void)
 Constructor. More...
 
Real ** getEncodedBuffer (void)
 Function for getting the encoded complex field buffer. More...
 
uchar ** getNormalizedBuffer (void)
 Function for getting the normalized(0~255) complex field buffer. More...
 
void initialize (void)
 Initialize variables for Hologram complex field, encoded data, normalized data. More...
 
int loadPointCloud (const char *pc_file, OphPointCloudData *pc_data_)
 load to point cloud data. More...
 
bool readConfig (const char *fname)
 load to configuration file. More...
 
void RS_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 RS-diffraction method. More...
 
void Fresnel_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 Fresnel-diffraction method. More...
 
void Fresnel_FFT (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real waveRatio, Real distance)
 Fresnel-fft method. More...
 
void AngularSpectrumMethod (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real distance)
 Angular spectrum propagation method. More...
 
void conv_fft2 (Complex< Real > *src1, Complex< Real > *src2, Complex< Real > *dst, ivec2 size)
 Convolution between Complex arrays which have same size. More...
 
void normalize (void)
 Normalization function to save as image file after hologram creation. More...
 
bool save (const char *fname, uint8_t bitsperpixel=8, uchar *src=nullptr, uint px=0, uint py=0)
 Function for saving image files. More...
 
void * load (const char *fname)
 Function for loading image files. More...
 
virtual bool loadAsOhc (const char *fname)
 Function to read OHC file. More...
 
void setPrecision (uint precision)
 Function for setting precision. More...
 
uint getPrecision ()
 
void setEncodeMethod (unsigned int ENCODE_FLAG)
 
void encoding (unsigned int ENCODE_FLAG)
 Encoding Functions. More...
 
void encoding (unsigned int ENCODE_FLAG, Complex< Real > *holo, Real *encoded)
 
void encoding ()
 
virtual void encoding (unsigned int ENCODE_FLAG, unsigned int SSB_PASSBAND, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 
void encoding (unsigned int BIN_ENCODE_FLAG, unsigned int ENCODE_FLAG, Real threshold, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 Binary Encoding Functions. More...
 
bool Shift (Real x, Real y)
 
void waveCarry (Real carryingAngleX, Real carryingAngleY, Real distance)
 Wave carry. More...
 
void waveCarry (Complex< Real > *src, Complex< Real > *dst, Real wavelength, int carryIdxX, int carryIdxY)
 
void transVW (int nVertex, Vertex *dst, Vertex *src)
 
void transVW (int nVertex, Real *dst, Real *src)
 
int getStream ()
 
Real getFieldLength ()
 
ivec2getEncodeSize (void)
 Function for getting encode size. More...
 
void setResolution (ivec2 resolution)
 Function for setting buffer size. More...
 
Real getElapsedTime ()
 Function for getting elapsed time. More...
 
bool saveRefImages (char *fnameW, char *fnameWC, char *fnameAS, char *fnameSSB, char *fnameHP, char *fnameFreq, char *fnameReal, char *fnameBin, char *fnameReconBin, char *fnameReconErr, char *fnameReconNo)
 
void fresnelPropagation (OphConfig context, Complex< Real > *in, Complex< Real > *out, Real distance)
 Fresnel propagation. More...
 
void fresnelPropagation (Complex< Real > *in, Complex< Real > *out, Real distance, uint channel)
 Fresnel propagation. More...
 
void SetRandomPhase (bool bRandomPhase)
 Function for setting the random phase. More...
 
bool GetRandomPhase ()
 Function for getting the random phase. More...
 
void SetMode (unsigned int mode)
 
unsigned int GetMode ()
 
 ophGen (void)
 Constructor. More...
 
Real ** getEncodedBuffer (void)
 Function for getting the encoded complex field buffer. More...
 
uchar ** getNormalizedBuffer (void)
 Function for getting the normalized(0~255) complex field buffer. More...
 
void initialize (void)
 Initialize variables for Hologram complex field, encoded data, normalized data. More...
 
int loadPointCloud (const char *pc_file, OphPointCloudData *pc_data_)
 load to point cloud data. More...
 
bool readConfig (const char *fname)
 load to configuration file. More...
 
void RS_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 RS-diffraction method. More...
 
void Fresnel_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 Fresnel-diffraction method. More...
 
void Fresnel_FFT (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real waveRatio, Real distance)
 Fresnel-fft method. More...
 
void AngularSpectrumMethod (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real distance)
 Angular spectrum propagation method. More...
 
void conv_fft2 (Complex< Real > *src1, Complex< Real > *src2, Complex< Real > *dst, ivec2 size)
 Convolution between Complex arrays which have same size. More...
 
void normalize (void)
 Normalization function to save as image file after hologram creation. More...
 
bool save (const char *fname, uint8_t bitsperpixel=8, uchar *src=nullptr, uint px=0, uint py=0)
 Function for saving image files. More...
 
void * load (const char *fname)
 Function for loading image files. More...
 
virtual bool loadAsOhc (const char *fname)
 Function to read OHC file. More...
 
void setPrecision (uint precision)
 Function for setting precision. More...
 
uint getPrecision ()
 
void setEncodeMethod (unsigned int ENCODE_FLAG)
 
void encoding (unsigned int ENCODE_FLAG)
 Encoding Functions. More...
 
void encoding (unsigned int ENCODE_FLAG, Complex< Real > *holo, Real *encoded)
 
void encoding ()
 
virtual void encoding (unsigned int ENCODE_FLAG, unsigned int SSB_PASSBAND, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 
void encoding (unsigned int BIN_ENCODE_FLAG, unsigned int ENCODE_FLAG, Real threshold, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 Binary Encoding Functions. More...
 
bool Shift (Real x, Real y)
 
void waveCarry (Real carryingAngleX, Real carryingAngleY, Real distance)
 Wave carry. More...
 
void waveCarry (Complex< Real > *src, Complex< Real > *dst, Real wavelength, int carryIdxX, int carryIdxY)
 
void transVW (int nVertex, Vertex *dst, Vertex *src)
 
void transVW (int nVertex, Real *dst, Real *src)
 
int getStream ()
 
Real getFieldLength ()
 
ivec2 & getEncodeSize (void)
 Function for getting encode size. More...
 
void setResolution (ivec2 resolution)
 Function for setting buffer size. More...
 
Real getElapsedTime ()
 Function for getting elapsed time. More...
 
bool saveRefImages (char *fnameW, char *fnameWC, char *fnameAS, char *fnameSSB, char *fnameHP, char *fnameFreq, char *fnameReal, char *fnameBin, char *fnameReconBin, char *fnameReconErr, char *fnameReconNo)
 
void fresnelPropagation (OphConfig context, Complex< Real > *in, Complex< Real > *out, Real distance)
 Fresnel propagation. More...
 
void fresnelPropagation (Complex< Real > *in, Complex< Real > *out, Real distance, uint channel)
 Fresnel propagation. More...
 
void SetRandomPhase (bool bRandomPhase)
 Function for setting the random phase. More...
 
bool GetRandomPhase ()
 Function for getting the random phase. More...
 
void SetMode (unsigned int mode)
 
unsigned int GetMode ()
 
 ophGen (void)
 Constructor. More...
 
Real ** getEncodedBuffer (void)
 Function for getting the encoded complex field buffer. More...
 
uchar ** getNormalizedBuffer (void)
 Function for getting the normalized(0~255) complex field buffer. More...
 
void initialize (void)
 Initialize variables for Hologram complex field, encoded data, normalized data. More...
 
int loadPointCloud (const char *pc_file, OphPointCloudData *pc_data_)
 load to point cloud data. More...
 
bool readConfig (const char *fname)
 load to configuration file. More...
 
void RS_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 RS-diffraction method. More...
 
void Fresnel_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 Fresnel-diffraction method. More...
 
void Fresnel_FFT (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real waveRatio, Real distance)
 Fresnel-fft method. More...
 
void AngularSpectrumMethod (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real distance)
 Angular spectrum propagation method. More...
 
void conv_fft2 (Complex< Real > *src1, Complex< Real > *src2, Complex< Real > *dst, ivec2 size)
 Convolution between Complex arrays which have same size. More...
 
void normalize (void)
 Normalization function to save as image file after hologram creation. More...
 
bool save (const char *fname, uint8_t bitsperpixel=8, uchar *src=nullptr, uint px=0, uint py=0)
 Function for saving image files. More...
 
void * load (const char *fname)
 Function for loading image files. More...
 
virtual bool loadAsOhc (const char *fname)
 Function to read OHC file. More...
 
void setPrecision (uint precision)
 Function for setting precision. More...
 
uint getPrecision ()
 
void setEncodeMethod (unsigned int ENCODE_FLAG)
 
void encoding (unsigned int ENCODE_FLAG)
 Encoding Functions. More...
 
void encoding (unsigned int ENCODE_FLAG, Complex< Real > *holo, Real *encoded)
 
void encoding ()
 
virtual void encoding (unsigned int ENCODE_FLAG, unsigned int SSB_PASSBAND, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 
void encoding (unsigned int BIN_ENCODE_FLAG, unsigned int ENCODE_FLAG, Real threshold, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 Binary Encoding Functions. More...
 
bool Shift (Real x, Real y)
 
void waveCarry (Real carryingAngleX, Real carryingAngleY, Real distance)
 Wave carry. More...
 
void waveCarry (Complex< Real > *src, Complex< Real > *dst, Real wavelength, int carryIdxX, int carryIdxY)
 
void transVW (int nVertex, Vertex *dst, Vertex *src)
 
void transVW (int nVertex, Real *dst, Real *src)
 
int getStream ()
 
Real getFieldLength ()
 
ivec2getEncodeSize (void)
 Function for getting encode size. More...
 
void setResolution (ivec2 resolution)
 Function for setting buffer size. More...
 
Real getElapsedTime ()
 Function for getting elapsed time. More...
 
bool saveRefImages (char *fnameW, char *fnameWC, char *fnameAS, char *fnameSSB, char *fnameHP, char *fnameFreq, char *fnameReal, char *fnameBin, char *fnameReconBin, char *fnameReconErr, char *fnameReconNo)
 
void fresnelPropagation (OphConfig context, Complex< Real > *in, Complex< Real > *out, Real distance)
 Fresnel propagation. More...
 
void fresnelPropagation (Complex< Real > *in, Complex< Real > *out, Real distance, uint channel)
 Fresnel propagation. More...
 
void SetRandomPhase (bool bRandomPhase)
 Function for setting the random phase. More...
 
bool GetRandomPhase ()
 Function for getting the random phase. More...
 
void SetMode (unsigned int mode)
 
unsigned int GetMode ()
 
 ophGen (void)
 Constructor. More...
 
Real ** getEncodedBuffer (void)
 Function for getting the encoded complex field buffer. More...
 
uchar ** getNormalizedBuffer (void)
 Function for getting the normalized(0~255) complex field buffer. More...
 
void initialize (void)
 Initialize variables for Hologram complex field, encoded data, normalized data. More...
 
int loadPointCloud (const char *pc_file, OphPointCloudData *pc_data_)
 load to point cloud data. More...
 
bool readConfig (const char *fname)
 load to configuration file. More...
 
void RS_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 RS-diffraction method. More...
 
void Fresnel_Diffraction (Point src, Complex< Real > *dst, Real lambda, Real distance, Real amplitude)
 Fresnel-diffraction method. More...
 
void Fresnel_FFT (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real waveRatio, Real distance)
 Fresnel-fft method. More...
 
void AngularSpectrumMethod (Complex< Real > *src, Complex< Real > *dst, Real lambda, Real distance)
 Angular spectrum propagation method. More...
 
void conv_fft2 (Complex< Real > *src1, Complex< Real > *src2, Complex< Real > *dst, ivec2 size)
 Convolution between Complex arrays which have same size. More...
 
void normalize (void)
 Normalization function to save as image file after hologram creation. More...
 
bool save (const char *fname, uint8_t bitsperpixel=8, uchar *src=nullptr, uint px=0, uint py=0)
 Function for saving image files. More...
 
void * load (const char *fname)
 Function for loading image files. More...
 
virtual bool loadAsOhc (const char *fname)
 Function to read OHC file. More...
 
void setPrecision (uint precision)
 Function for setting precision. More...
 
uint getPrecision ()
 
void setEncodeMethod (unsigned int ENCODE_FLAG)
 
void encoding (unsigned int ENCODE_FLAG)
 Encoding Functions. More...
 
void encoding (unsigned int ENCODE_FLAG, Complex< Real > *holo, Real *encoded)
 
void encoding ()
 
virtual void encoding (unsigned int ENCODE_FLAG, unsigned int SSB_PASSBAND, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 
void encoding (unsigned int BIN_ENCODE_FLAG, unsigned int ENCODE_FLAG, Real threshold, Complex< Real > *holo=nullptr, Real *encoded=nullptr)
 Binary Encoding Functions. More...
 
bool Shift (Real x, Real y)
 
void waveCarry (Real carryingAngleX, Real carryingAngleY, Real distance)
 Wave carry. More...
 
void waveCarry (Complex< Real > *src, Complex< Real > *dst, Real wavelength, int carryIdxX, int carryIdxY)
 
void transVW (int nVertex, Vertex *dst, Vertex *src)
 
void transVW (int nVertex, Real *dst, Real *src)
 
int getStream ()
 
Real getFieldLength ()
 
ivec2 & getEncodeSize (void)
 Function for getting encode size. More...
 
void setResolution (ivec2 resolution)
 Function for setting buffer size. More...
 
Real getElapsedTime ()
 Function for getting elapsed time. More...
 
bool saveRefImages (char *fnameW, char *fnameWC, char *fnameAS, char *fnameSSB, char *fnameHP, char *fnameFreq, char *fnameReal, char *fnameBin, char *fnameReconBin, char *fnameReconErr, char *fnameReconNo)
 
void fresnelPropagation (OphConfig context, Complex< Real > *in, Complex< Real > *out, Real distance)
 Fresnel propagation. More...
 
void fresnelPropagation (Complex< Real > *in, Complex< Real > *out, Real distance, uint channel)
 Fresnel propagation. More...
 
void SetRandomPhase (bool bRandomPhase)
 Function for setting the random phase. More...
 
bool GetRandomPhase ()
 Function for getting the random phase. More...
 
void SetMode (unsigned int mode)
 
unsigned int GetMode ()
 
- Public Member Functions inherited from Openholo
 Openholo (void)
 Constructor. More...
 
virtual bool saveAsImg (const char *fname, uint8_t bitsperpixel, uchar *src, int width, int height)
 Function for creating image files. More...
 
virtual ucharloadAsImg (const char *fname)
 Function for loading image files. More...
 
virtual bool saveAsOhc (const char *fname)
 Function to write OHC file
More...
 
Complex< Real > ** getComplexField (void)
 Function for getting the complex field. More...
 
OphConfiggetContext (void)
 Function for getting the current context. More...
 
ImageConfiggetImageConfig ()
 Function for getting the image config. More...
 
void setPixelNumber (ivec2 n)
 Function for setting the output resolution. More...
 
void setPixelNumber (int width, int height)
 
void setPixelPitch (vec2 p)
 Function for setting the output pixel pitch. More...
 
void setPixelPitch (Real pitchX, Real pitchY)
 
void setWaveLength (Real w, const uint idx=0)
 Function for setting the wave length. More...
 
void setWaveNum (int num)
 Function for setting the wave number. More...
 
void setOffset (ivec2 offset)
 Function for setting the offset. More...
 
void setImageMerge (bool merge)
 Function for setting the image merge(true or false) More...
 
void setImageRotate (bool rotate)
 Function for setting the image rotate(true or false) More...
 
void setImageFlip (int flip)
 Function for setting the image flip. More...
 
void setMaxThreadNum (int num)
 Function for setting the max thread num. More...
 
int getMaxThreadNum ()
 Function for getting the max thread num. More...
 
bool mergeColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate RGB image from each grayscale image. More...
 
bool separateColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate each grayscale image from RGB image. More...
 
 Openholo (void)
 Constructor. More...
 
virtual bool saveAsImg (const char *fname, uint8_t bitsperpixel, uchar *src, int width, int height)
 Function for creating image files. More...
 
virtual ucharloadAsImg (const char *fname)
 Function for loading image files. More...
 
virtual bool saveAsOhc (const char *fname)
 Function to write OHC file
More...
 
Complex< Real > ** getComplexField (void)
 Function for getting the complex field. More...
 
OphConfiggetContext (void)
 Function for getting the current context. More...
 
ImageConfiggetImageConfig ()
 Function for getting the image config. More...
 
void setPixelNumber (ivec2 n)
 Function for setting the output resolution. More...
 
void setPixelNumber (int width, int height)
 
void setPixelPitch (vec2 p)
 Function for setting the output pixel pitch. More...
 
void setPixelPitch (Real pitchX, Real pitchY)
 
void setWaveLength (Real w, const uint idx=0)
 Function for setting the wave length. More...
 
void setWaveNum (int num)
 Function for setting the wave number. More...
 
void setOffset (ivec2 offset)
 Function for setting the offset. More...
 
void setImageMerge (bool merge)
 Function for setting the image merge(true or false) More...
 
void setImageRotate (bool rotate)
 Function for setting the image rotate(true or false) More...
 
void setImageFlip (int flip)
 Function for setting the image flip. More...
 
void setMaxThreadNum (int num)
 Function for setting the max thread num. More...
 
int getMaxThreadNum ()
 Function for getting the max thread num. More...
 
bool mergeColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate RGB image from each grayscale image. More...
 
bool separateColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate each grayscale image from RGB image. More...
 
 Openholo (void)
 Constructor. More...
 
virtual bool saveAsImg (const char *fname, uint8_t bitsperpixel, uchar *src, int width, int height)
 Function for creating image files. More...
 
virtual ucharloadAsImg (const char *fname)
 Function for loading image files. More...
 
virtual bool saveAsOhc (const char *fname)
 Function to write OHC file
More...
 
Complex< Real > ** getComplexField (void)
 Function for getting the complex field. More...
 
OphConfiggetContext (void)
 Function for getting the current context. More...
 
ImageConfiggetImageConfig ()
 Function for getting the image config. More...
 
void setPixelNumber (ivec2 n)
 Function for setting the output resolution. More...
 
void setPixelNumber (int width, int height)
 
void setPixelPitch (vec2 p)
 Function for setting the output pixel pitch. More...
 
void setPixelPitch (Real pitchX, Real pitchY)
 
void setWaveLength (Real w, const uint idx=0)
 Function for setting the wave length. More...
 
void setWaveNum (int num)
 Function for setting the wave number. More...
 
void setOffset (ivec2 offset)
 Function for setting the offset. More...
 
void setImageMerge (bool merge)
 Function for setting the image merge(true or false) More...
 
void setImageRotate (bool rotate)
 Function for setting the image rotate(true or false) More...
 
void setImageFlip (int flip)
 Function for setting the image flip. More...
 
void setMaxThreadNum (int num)
 Function for setting the max thread num. More...
 
int getMaxThreadNum ()
 Function for getting the max thread num. More...
 
bool mergeColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate RGB image from each grayscale image. More...
 
bool separateColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate each grayscale image from RGB image. More...
 
 Openholo (void)
 Constructor. More...
 
virtual bool saveAsImg (const char *fname, uint8_t bitsperpixel, uchar *src, int width, int height)
 Function for creating image files. More...
 
virtual ucharloadAsImg (const char *fname)
 Function for loading image files. More...
 
virtual bool saveAsOhc (const char *fname)
 Function to write OHC file
More...
 
Complex< Real > ** getComplexField (void)
 Function for getting the complex field. More...
 
OphConfiggetContext (void)
 Function for getting the current context. More...
 
ImageConfiggetImageConfig ()
 Function for getting the image config. More...
 
void setPixelNumber (ivec2 n)
 Function for setting the output resolution. More...
 
void setPixelNumber (int width, int height)
 
void setPixelPitch (vec2 p)
 Function for setting the output pixel pitch. More...
 
void setPixelPitch (Real pitchX, Real pitchY)
 
void setWaveLength (Real w, const uint idx=0)
 Function for setting the wave length. More...
 
void setWaveNum (int num)
 Function for setting the wave number. More...
 
void setOffset (ivec2 offset)
 Function for setting the offset. More...
 
void setImageMerge (bool merge)
 Function for setting the image merge(true or false) More...
 
void setImageRotate (bool rotate)
 Function for setting the image rotate(true or false) More...
 
void setImageFlip (int flip)
 Function for setting the image flip. More...
 
void setMaxThreadNum (int num)
 Function for setting the max thread num. More...
 
int getMaxThreadNum ()
 Function for getting the max thread num. More...
 
bool mergeColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate RGB image from each grayscale image. More...
 
bool separateColor (int idx, int width, int height, uchar *src, uchar *dst)
 Function for generate each grayscale image from RGB image. More...
 
- Public Member Functions inherited from Base
 Base (void)
 Constructor. More...
 
unsigned long addRef (void)
 If referenced this(Base's child, not abstract class) instance, must call this method. More...
 
unsigned long release (void)
 Call release() when reference is finished. More...
 
 Base (void)
 Constructor. More...
 
unsigned long addRef (void)
 If referenced this(Base's child, not abstract class) instance, must call this method. More...
 
unsigned long release (void)
 Call release() when reference is finished. More...
 
 Base (void)
 Constructor. More...
 
unsigned long addRef (void)
 If referenced this(Base's child, not abstract class) instance, must call this method. More...
 
unsigned long release (void)
 Call release() when reference is finished. More...
 
 Base (void)
 Constructor. More...
 
unsigned long addRef (void)
 If referenced this(Base's child, not abstract class) instance, must call this method. More...
 
unsigned long release (void)
 Call release() when reference is finished. More...
 

Public Attributes

double * m_pHologram
 
float * m_COStbl
 
float * m_SINtbl
 
int m_segSize
 
int m_hsegSize
 
int m_dsegSize
 
int m_segNumx
 
int m_segNumy
 
int m_hsegNumx
 
int m_hsegNumy
 
float * m_SFrequency_cx
 
float * m_SFrequency_cy
 
int * m_PickPoint_cx
 
int * m_PickPoint_cy
 
int * m_Coefficient_cx
 
int * m_Coefficient_cy
 
float * m_xc
 
float * m_yc
 
unsigned char * cgh_fringe
 
float m_sf_base
 
float * m_inReHost
 
float * m_inImHost
 
fftw_complex * m_in
 
fftw_complex * m_out
 
fftw_plan m_plan
 
float ** m_inRe
 
float ** m_inIm
 
float * m_inRe_h
 
float * m_inIm_h
 
float m_cx
 
float m_cy
 
float m_cz
 
float m_amp
 
ivec3 se
 

Protected Member Functions

virtual ~ophPAS_GPU ()
 
virtual ~ophPAS_GPU ()
 
virtual ~ophPAS_GPU ()
 
virtual ~ophPAS_GPU ()
 
- Protected Member Functions inherited from ophGen
virtual ~ophGen (void)=0
 Destructor. More...
 
bool save (const char *fname, uint8_t bitsperpixel, uint px, uint py, uint fnum, uchar *args ...)
 Called when saving multiple hologram data at a time. More...
 
void resetBuffer ()
 reset buffer More...
 
template<typename T >
void RealPart (Complex< T > *holo, T *encoded, const int size)
 Encoding method. More...
 
template<typename T >
void ImaginaryPart (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Phase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Amplitude (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void TwoPhase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Burckhardt (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void SimpleNI (Complex< T > *holo, T *encoded, const int size)
 
void singleSideBand (Complex< Real > *holo, Real *encoded, const ivec2 holosize, int passband)
 Encoding method. More...
 
void freqShift (Complex< Real > *holo, Complex< Real > *encoded, const ivec2 holosize, int shift_x, int shift_y)
 Frequency shift. More...
 
bool binaryErrorDiffusion (Complex< Real > *holo, Real *encoded, const ivec2 holosize, const int type, Real threshold)
 
bool getWeightED (const ivec2 holosize, const int type, ivec2 *pNw)
 
bool shiftW (ivec2 holosize)
 
void binarization (Complex< Real > *src, Real *dst, const int size, int ENCODE_FLAG, Real threshold)
 
void CorrectionChromaticAberration (uchar *src, uchar *dst, int width, int height, int ch)
 
void encodeSideBand (bool bCPU, ivec2 sig_location)
 Encode the CGH according to a signal location parameter. More...
 
void encodeSideBand_CPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the CPU. More...
 
void encodeSideBand_GPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the GPU. More...
 
void getShiftPhaseValue (Complex< Real > &shift_phase_val, int idx, ivec2 sig_location)
 Calculate the shift phase value. More...
 
void GetRandomPhaseValue (Complex< Real > &rand_phase_val, bool rand_phase)
 Assign random phase value if random_phase == 1. More...
 
void ScaleChange (Real *src, Real *dst, int nSize, Real scaleX, Real scaleY, Real scaleZ)
 
void GetMaxMin (Real *src, int len, Real &max, Real &min)
 
virtual void ophFree (void)
 Pure virtual function for override in child classes. More...
 
virtual ~ophGen (void)=0
 Destructor. More...
 
bool save (const char *fname, uint8_t bitsperpixel, uint px, uint py, uint fnum, uchar *args ...)
 Called when saving multiple hologram data at a time. More...
 
void resetBuffer ()
 reset buffer More...
 
template<typename T >
void RealPart (Complex< T > *holo, T *encoded, const int size)
 Encoding method. More...
 
template<typename T >
void ImaginaryPart (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Phase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Amplitude (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void TwoPhase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Burckhardt (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void SimpleNI (Complex< T > *holo, T *encoded, const int size)
 
void singleSideBand (Complex< Real > *holo, Real *encoded, const ivec2 holosize, int passband)
 Encoding method. More...
 
void freqShift (Complex< Real > *holo, Complex< Real > *encoded, const ivec2 holosize, int shift_x, int shift_y)
 Frequency shift. More...
 
bool binaryErrorDiffusion (Complex< Real > *holo, Real *encoded, const ivec2 holosize, const int type, Real threshold)
 
bool getWeightED (const ivec2 holosize, const int type, ivec2 *pNw)
 
bool shiftW (ivec2 holosize)
 
void binarization (Complex< Real > *src, Real *dst, const int size, int ENCODE_FLAG, Real threshold)
 
void CorrectionChromaticAberration (uchar *src, uchar *dst, int width, int height, int ch)
 
void encodeSideBand (bool bCPU, ivec2 sig_location)
 Encode the CGH according to a signal location parameter. More...
 
void encodeSideBand_CPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the CPU. More...
 
void encodeSideBand_GPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the GPU. More...
 
void getShiftPhaseValue (Complex< Real > &shift_phase_val, int idx, ivec2 sig_location)
 Calculate the shift phase value. More...
 
void GetRandomPhaseValue (Complex< Real > &rand_phase_val, bool rand_phase)
 Assign random phase value if random_phase == 1. More...
 
void ScaleChange (Real *src, Real *dst, int nSize, Real scaleX, Real scaleY, Real scaleZ)
 
void GetMaxMin (Real *src, int len, Real &max, Real &min)
 
virtual void ophFree (void)
 Pure virtual function for override in child classes. More...
 
virtual ~ophGen (void)=0
 Destructor. More...
 
bool save (const char *fname, uint8_t bitsperpixel, uint px, uint py, uint fnum, uchar *args ...)
 Called when saving multiple hologram data at a time. More...
 
void resetBuffer ()
 reset buffer More...
 
template<typename T >
void RealPart (Complex< T > *holo, T *encoded, const int size)
 Encoding method. More...
 
template<typename T >
void ImaginaryPart (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Phase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Amplitude (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void TwoPhase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Burckhardt (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void SimpleNI (Complex< T > *holo, T *encoded, const int size)
 
void singleSideBand (Complex< Real > *holo, Real *encoded, const ivec2 holosize, int passband)
 Encoding method. More...
 
void freqShift (Complex< Real > *holo, Complex< Real > *encoded, const ivec2 holosize, int shift_x, int shift_y)
 Frequency shift. More...
 
bool binaryErrorDiffusion (Complex< Real > *holo, Real *encoded, const ivec2 holosize, const int type, Real threshold)
 
bool getWeightED (const ivec2 holosize, const int type, ivec2 *pNw)
 
bool shiftW (ivec2 holosize)
 
void binarization (Complex< Real > *src, Real *dst, const int size, int ENCODE_FLAG, Real threshold)
 
void CorrectionChromaticAberration (uchar *src, uchar *dst, int width, int height, int ch)
 
void encodeSideBand (bool bCPU, ivec2 sig_location)
 Encode the CGH according to a signal location parameter. More...
 
void encodeSideBand_CPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the CPU. More...
 
void encodeSideBand_GPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the GPU. More...
 
void getShiftPhaseValue (Complex< Real > &shift_phase_val, int idx, ivec2 sig_location)
 Calculate the shift phase value. More...
 
void GetRandomPhaseValue (Complex< Real > &rand_phase_val, bool rand_phase)
 Assign random phase value if random_phase == 1. More...
 
void ScaleChange (Real *src, Real *dst, int nSize, Real scaleX, Real scaleY, Real scaleZ)
 
void GetMaxMin (Real *src, int len, Real &max, Real &min)
 
virtual void ophFree (void)
 Pure virtual function for override in child classes. More...
 
virtual ~ophGen (void)=0
 Destructor. More...
 
bool save (const char *fname, uint8_t bitsperpixel, uint px, uint py, uint fnum, uchar *args ...)
 Called when saving multiple hologram data at a time. More...
 
void resetBuffer ()
 reset buffer More...
 
template<typename T >
void RealPart (Complex< T > *holo, T *encoded, const int size)
 Encoding method. More...
 
template<typename T >
void ImaginaryPart (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Phase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Amplitude (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void TwoPhase (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void Burckhardt (Complex< T > *holo, T *encoded, const int size)
 
template<typename T >
void SimpleNI (Complex< T > *holo, T *encoded, const int size)
 
void singleSideBand (Complex< Real > *holo, Real *encoded, const ivec2 holosize, int passband)
 Encoding method. More...
 
void freqShift (Complex< Real > *holo, Complex< Real > *encoded, const ivec2 holosize, int shift_x, int shift_y)
 Frequency shift. More...
 
bool binaryErrorDiffusion (Complex< Real > *holo, Real *encoded, const ivec2 holosize, const int type, Real threshold)
 
bool getWeightED (const ivec2 holosize, const int type, ivec2 *pNw)
 
bool shiftW (ivec2 holosize)
 
void binarization (Complex< Real > *src, Real *dst, const int size, int ENCODE_FLAG, Real threshold)
 
void CorrectionChromaticAberration (uchar *src, uchar *dst, int width, int height, int ch)
 
void encodeSideBand (bool bCPU, ivec2 sig_location)
 Encode the CGH according to a signal location parameter. More...
 
void encodeSideBand_CPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the CPU. More...
 
void encodeSideBand_GPU (int cropx1, int cropx2, int cropy1, int cropy2, ivec2 sig_location)
 Encode the CGH according to a signal location parameter on the GPU. More...
 
void getShiftPhaseValue (Complex< Real > &shift_phase_val, int idx, ivec2 sig_location)
 Calculate the shift phase value. More...
 
void GetRandomPhaseValue (Complex< Real > &rand_phase_val, bool rand_phase)
 Assign random phase value if random_phase == 1. More...
 
void ScaleChange (Real *src, Real *dst, int nSize, Real scaleX, Real scaleY, Real scaleZ)
 
void GetMaxMin (Real *src, int len, Real &max, Real &min)
 
virtual void ophFree (void)
 Pure virtual function for override in child classes. More...
 
- Protected Member Functions inherited from Openholo
virtual ~Openholo (void)=0
 Destructor. More...
 
bool checkExtension (const char *fname, const char *ext)
 Functions for extension checking. More...
 
bool loadAsImgUpSideDown (const char *fname, uchar *dst)
 Function for loading image files | Output image data upside down. More...
 
bool getImgSize (int &w, int &h, int &bytesperpixel, const char *fname)
 Function for getting the image size. More...
 
void imgScaleBilinear (uchar *src, uchar *dst, int w, int h, int neww, int newh, int channels=1)
 Function for change image size. More...
 
void convertToFormatGray8 (uchar *src, uchar *dst, int w, int h, int bytesperpixel)
 Function for convert image format to gray8. More...
 
void fft1 (int n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 1-dimension operations inside Openholo. More...
 
void fft2 (ivec2 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 2-dimension operations inside Openholo. More...
 
void fft3 (ivec3 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 3-dimension operations inside Openholo. More...
 
void fftExecute (Complex< Real > *out, bool bReverse=false)
 Execution functions to be called after fft1, fft2, and fft3. More...
 
void fftFree (void)
 Resource release method. More...
 
void fftInit2D (ivec2 size, int sign, unsigned int flag)
 initialize method for 2D FFT More...
 
void fft2 (Complex< Real > *src, Complex< Real > *dst, int nx, int ny, int type, bool bNormalized=false)
 Convert data from the spatial domain to the frequency domain using 2D FFT on CPU. More...
 
void fftShift (int nx, int ny, Complex< Real > *input, Complex< Real > *output)
 Swap the top-left quadrant of data with the bottom-right , and the top-right quadrant with the bottom-left. More...
 
void setPixelNumberOHC (const ivec2 pixel_number)
 getter/setter for OHC file read and write More...
 
void setPixelPitchOHC (const vec2 pixel_pitch)
 
void setWavelengthOHC (const Real wavelength, const LenUnit wavelength_unit)
 
void setWaveLengthNumOHC (const uint wavelength_num)
 
void setColorTypeOHC (const ColorType color_type)
 
void setColorArrangeOHC (const ColorArran color_arrange)
 
void setWaveLengthUnitOHC (const LenUnit length_unit)
 
void setFieldEncodingOHC (const FldStore field_store, const FldCodeType field_code_type)
 
void setPhaseEncodingOHC (const BPhaseCode phase_code, const vec2 phase_code_range)
 
void addWaveLengthNComplexFieldDataOHC (const Real wavelength, const OphComplexField &complex_field)
 Function to add ComplexField when adding wavelength data. More...
 
void addWaveLengthOHC (const Real wavelength)
 
void addComplexFieldDataOHC (const OphComplexField &complex_field)
 
void getPixelNumberOHC (ivec2 &pixel_number)
 
void getPixelPitchOHC (vec2 &pixel_pitch)
 
void getWavelengthOHC (vector< Real > &wavelength)
 
void getWaveLengthNumOHC (uint &wavelength_num)
 
void getColorTypeOHC (ColorType &color_type)
 
void getColorArrangeOHC (ColorArran &color_arrange)
 
void getWaveLengthUnitOHC (LenUnit &length_unit)
 
void getComplexFieldDataOHC (Complex< Real > **cmplx, uint wavelen_idx)
 
void getComplexFieldDataOHC (OphComplexField &cmplx, uint wavelen_idx)
 
virtual ~Openholo (void)=0
 Destructor. More...
 
bool checkExtension (const char *fname, const char *ext)
 Functions for extension checking. More...
 
bool loadAsImgUpSideDown (const char *fname, uchar *dst)
 Function for loading image files | Output image data upside down. More...
 
bool getImgSize (int &w, int &h, int &bytesperpixel, const char *fname)
 Function for getting the image size. More...
 
void imgScaleBilinear (uchar *src, uchar *dst, int w, int h, int neww, int newh, int channels=1)
 Function for change image size. More...
 
void convertToFormatGray8 (uchar *src, uchar *dst, int w, int h, int bytesperpixel)
 Function for convert image format to gray8. More...
 
void fft1 (int n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 1-dimension operations inside Openholo. More...
 
void fft2 (ivec2 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 2-dimension operations inside Openholo. More...
 
void fft3 (ivec3 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 3-dimension operations inside Openholo. More...
 
void fftExecute (Complex< Real > *out, bool bReverse=false)
 Execution functions to be called after fft1, fft2, and fft3. More...
 
void fftFree (void)
 Resource release method. More...
 
void fftInit2D (ivec2 size, int sign, unsigned int flag)
 initialize method for 2D FFT More...
 
void fft2 (Complex< Real > *src, Complex< Real > *dst, int nx, int ny, int type, bool bNormalized=false)
 Convert data from the spatial domain to the frequency domain using 2D FFT on CPU. More...
 
void fftShift (int nx, int ny, Complex< Real > *input, Complex< Real > *output)
 Swap the top-left quadrant of data with the bottom-right , and the top-right quadrant with the bottom-left. More...
 
void setPixelNumberOHC (const ivec2 pixel_number)
 getter/setter for OHC file read and write More...
 
void setPixelPitchOHC (const vec2 pixel_pitch)
 
void setWavelengthOHC (const Real wavelength, const LenUnit wavelength_unit)
 
void setWaveLengthNumOHC (const uint wavelength_num)
 
void setColorTypeOHC (const ColorType color_type)
 
void setColorArrangeOHC (const ColorArran color_arrange)
 
void setWaveLengthUnitOHC (const LenUnit length_unit)
 
void setFieldEncodingOHC (const FldStore field_store, const FldCodeType field_code_type)
 
void setPhaseEncodingOHC (const BPhaseCode phase_code, const vec2 phase_code_range)
 
void addWaveLengthNComplexFieldDataOHC (const Real wavelength, const OphComplexField &complex_field)
 Function to add ComplexField when adding wavelength data. More...
 
void addWaveLengthOHC (const Real wavelength)
 
void addComplexFieldDataOHC (const OphComplexField &complex_field)
 
void getPixelNumberOHC (ivec2 &pixel_number)
 
void getPixelPitchOHC (vec2 &pixel_pitch)
 
void getWavelengthOHC (vector< Real > &wavelength)
 
void getWaveLengthNumOHC (uint &wavelength_num)
 
void getColorTypeOHC (ColorType &color_type)
 
void getColorArrangeOHC (ColorArran &color_arrange)
 
void getWaveLengthUnitOHC (LenUnit &length_unit)
 
void getComplexFieldDataOHC (Complex< Real > **cmplx, uint wavelen_idx)
 
void getComplexFieldDataOHC (OphComplexField &cmplx, uint wavelen_idx)
 
virtual ~Openholo (void)=0
 Destructor. More...
 
bool checkExtension (const char *fname, const char *ext)
 Functions for extension checking. More...
 
bool loadAsImgUpSideDown (const char *fname, uchar *dst)
 Function for loading image files | Output image data upside down. More...
 
bool getImgSize (int &w, int &h, int &bytesperpixel, const char *fname)
 Function for getting the image size. More...
 
void imgScaleBilinear (uchar *src, uchar *dst, int w, int h, int neww, int newh, int channels=1)
 Function for change image size. More...
 
void convertToFormatGray8 (uchar *src, uchar *dst, int w, int h, int bytesperpixel)
 Function for convert image format to gray8. More...
 
void fft1 (int n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 1-dimension operations inside Openholo. More...
 
void fft2 (ivec2 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 2-dimension operations inside Openholo. More...
 
void fft3 (ivec3 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 3-dimension operations inside Openholo. More...
 
void fftExecute (Complex< Real > *out, bool bReverse=false)
 Execution functions to be called after fft1, fft2, and fft3. More...
 
void fftFree (void)
 Resource release method. More...
 
void fftInit2D (ivec2 size, int sign, unsigned int flag)
 initialize method for 2D FFT More...
 
void fft2 (Complex< Real > *src, Complex< Real > *dst, int nx, int ny, int type, bool bNormalized=false)
 Convert data from the spatial domain to the frequency domain using 2D FFT on CPU. More...
 
void fftShift (int nx, int ny, Complex< Real > *input, Complex< Real > *output)
 Swap the top-left quadrant of data with the bottom-right , and the top-right quadrant with the bottom-left. More...
 
void setPixelNumberOHC (const ivec2 pixel_number)
 getter/setter for OHC file read and write More...
 
void setPixelPitchOHC (const vec2 pixel_pitch)
 
void setWavelengthOHC (const Real wavelength, const LenUnit wavelength_unit)
 
void setWaveLengthNumOHC (const uint wavelength_num)
 
void setColorTypeOHC (const ColorType color_type)
 
void setColorArrangeOHC (const ColorArran color_arrange)
 
void setWaveLengthUnitOHC (const LenUnit length_unit)
 
void setFieldEncodingOHC (const FldStore field_store, const FldCodeType field_code_type)
 
void setPhaseEncodingOHC (const BPhaseCode phase_code, const vec2 phase_code_range)
 
void addWaveLengthNComplexFieldDataOHC (const Real wavelength, const OphComplexField &complex_field)
 Function to add ComplexField when adding wavelength data. More...
 
void addWaveLengthOHC (const Real wavelength)
 
void addComplexFieldDataOHC (const OphComplexField &complex_field)
 
void getPixelNumberOHC (ivec2 &pixel_number)
 
void getPixelPitchOHC (vec2 &pixel_pitch)
 
void getWavelengthOHC (vector< Real > &wavelength)
 
void getWaveLengthNumOHC (uint &wavelength_num)
 
void getColorTypeOHC (ColorType &color_type)
 
void getColorArrangeOHC (ColorArran &color_arrange)
 
void getWaveLengthUnitOHC (LenUnit &length_unit)
 
void getComplexFieldDataOHC (Complex< Real > **cmplx, uint wavelen_idx)
 
void getComplexFieldDataOHC (OphComplexField &cmplx, uint wavelen_idx)
 
virtual ~Openholo (void)=0
 Destructor. More...
 
bool checkExtension (const char *fname, const char *ext)
 Functions for extension checking. More...
 
bool loadAsImgUpSideDown (const char *fname, uchar *dst)
 Function for loading image files | Output image data upside down. More...
 
bool getImgSize (int &w, int &h, int &bytesperpixel, const char *fname)
 Function for getting the image size. More...
 
void imgScaleBilinear (uchar *src, uchar *dst, int w, int h, int neww, int newh, int channels=1)
 Function for change image size. More...
 
void convertToFormatGray8 (uchar *src, uchar *dst, int w, int h, int bytesperpixel)
 Function for convert image format to gray8. More...
 
void fft1 (int n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 1-dimension operations inside Openholo. More...
 
void fft2 (ivec2 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 2-dimension operations inside Openholo. More...
 
void fft3 (ivec3 n, Complex< Real > *in, int sign=OPH_FORWARD, uint flag=OPH_ESTIMATE)
 Functions for performing fftw 3-dimension operations inside Openholo. More...
 
void fftExecute (Complex< Real > *out, bool bReverse=false)
 Execution functions to be called after fft1, fft2, and fft3. More...
 
void fftFree (void)
 Resource release method. More...
 
void fftInit2D (ivec2 size, int sign, unsigned int flag)
 initialize method for 2D FFT More...
 
void fft2 (Complex< Real > *src, Complex< Real > *dst, int nx, int ny, int type, bool bNormalized=false)
 Convert data from the spatial domain to the frequency domain using 2D FFT on CPU. More...
 
void fftShift (int nx, int ny, Complex< Real > *input, Complex< Real > *output)
 Swap the top-left quadrant of data with the bottom-right , and the top-right quadrant with the bottom-left. More...
 
void setPixelNumberOHC (const ivec2 pixel_number)
 getter/setter for OHC file read and write More...
 
void setPixelPitchOHC (const vec2 pixel_pitch)
 
void setWavelengthOHC (const Real wavelength, const LenUnit wavelength_unit)
 
void setWaveLengthNumOHC (const uint wavelength_num)
 
void setColorTypeOHC (const ColorType color_type)
 
void setColorArrangeOHC (const ColorArran color_arrange)
 
void setWaveLengthUnitOHC (const LenUnit length_unit)
 
void setFieldEncodingOHC (const FldStore field_store, const FldCodeType field_code_type)
 
void setPhaseEncodingOHC (const BPhaseCode phase_code, const vec2 phase_code_range)
 
void addWaveLengthNComplexFieldDataOHC (const Real wavelength, const OphComplexField &complex_field)
 Function to add ComplexField when adding wavelength data. More...
 
void addWaveLengthOHC (const Real wavelength)
 
void addComplexFieldDataOHC (const OphComplexField &complex_field)
 
void getPixelNumberOHC (ivec2 &pixel_number)
 
void getPixelPitchOHC (vec2 &pixel_pitch)
 
void getWavelengthOHC (vector< Real > &wavelength)
 
void getWaveLengthNumOHC (uint &wavelength_num)
 
void getColorTypeOHC (ColorType &color_type)
 
void getColorArrangeOHC (ColorArran &color_arrange)
 
void getWaveLengthUnitOHC (LenUnit &length_unit)
 
void getComplexFieldDataOHC (Complex< Real > **cmplx, uint wavelen_idx)
 
void getComplexFieldDataOHC (OphComplexField &cmplx, uint wavelen_idx)
 
- Protected Member Functions inherited from Base
virtual ~Base (void)
 Destructor. More...
 
virtual ~Base (void)
 Destructor. More...
 
virtual ~Base (void)
 Destructor. More...
 
virtual ~Base (void)
 Destructor. More...
 

Additional Inherited Members

- Public Types inherited from ophGen
enum  PRECISION {
  SINGLE, DOUBLE, SINGLE, DOUBLE,
  SINGLE, DOUBLE, SINGLE, DOUBLE
}
 
enum  ENCODE_FLAG {
  ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY,
  ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB,
  ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE,
  ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI,
  ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB,
  ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE,
  ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT,
  ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY,
  ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL,
  ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE,
  ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY
}
 
enum  SSB_PASSBAND {
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM
}
 Passband in Single-side band encoding. More...
 
enum  ED_WType {
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN
}
 
enum  PRECISION {
  SINGLE, DOUBLE, SINGLE, DOUBLE,
  SINGLE, DOUBLE, SINGLE, DOUBLE
}
 
enum  ENCODE_FLAG {
  ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY,
  ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB,
  ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE,
  ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI,
  ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB,
  ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE,
  ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT,
  ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY,
  ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL,
  ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE,
  ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY
}
 
enum  SSB_PASSBAND {
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM
}
 
enum  ED_WType {
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN
}
 
enum  PRECISION {
  SINGLE, DOUBLE, SINGLE, DOUBLE,
  SINGLE, DOUBLE, SINGLE, DOUBLE
}
 
enum  ENCODE_FLAG {
  ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY,
  ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB,
  ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE,
  ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI,
  ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB,
  ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE,
  ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT,
  ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY,
  ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL,
  ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE,
  ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY
}
 
enum  SSB_PASSBAND {
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM
}
 
enum  ED_WType {
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN
}
 
enum  PRECISION {
  SINGLE, DOUBLE, SINGLE, DOUBLE,
  SINGLE, DOUBLE, SINGLE, DOUBLE
}
 
enum  ENCODE_FLAG {
  ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY,
  ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB,
  ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE,
  ENCODE_AMPLITUDE, ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI,
  ENCODE_BURCKHARDT, ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB,
  ENCODE_SIMPLEBINARY, ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE,
  ENCODE_REAL, ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT,
  ENCODE_TWOPHASE, ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY,
  ENCODE_EDBINARY, ENCODE_PHASE, ENCODE_AMPLITUDE, ENCODE_REAL,
  ENCODE_IMAGINARY, ENCODE_SIMPLENI, ENCODE_BURCKHARDT, ENCODE_TWOPHASE,
  ENCODE_SSB, ENCODE_OFFSSB, ENCODE_SIMPLEBINARY, ENCODE_EDBINARY
}
 
enum  SSB_PASSBAND {
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM,
  SSB_LEFT, SSB_RIGHT, SSB_TOP, SSB_BOTTOM
}
 
enum  ED_WType {
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN,
  FLOYD_STEINBERG, SINGLE_RIGHT, SINGLE_DOWN, ITERATIVE_DESIGN
}
 
- Protected Attributes inherited from ophGen
ivec2 m_vecEncodeSize
 Encoded hologram size, varied from encoding type. More...
 
int ENCODE_METHOD
 Encoding method flag. More...
 
int SSB_PASSBAND
 Passband in Single-side band encoding. More...
 
Real m_elapsedTime
 Elapsed time of generate hologram. More...
 
Real ** m_lpEncoded
 buffer to encoded. More...
 
uchar ** m_lpNormalized
 buffer to normalized. More...
 
Real m_dFieldLength
 
int m_nStream
 
unsigned int m_mode
 
Complex< Real > * AS
 Binary Encoding - Error diffusion. More...
 
Complex< Real > * normalized
 
Complex< Real > * fftTemp
 
Realweight
 
Complex< Real > * weightC
 
Complex< Real > * freqW
 
RealrealEnc
 
Realbinary
 
RealmaskSSB
 
RealmaskHP
 
bool m_bRandomPhase
 
- Protected Attributes inherited from Openholo
OphConfig context_
 
ResolutionConfig resCfg
 
ImageConfig imgCfg
 
Complex< Real > ** complex_H
 
ImgEncoderOhcOHC_encoder
 OHC file format Variables for read and write. More...
 
ImgDecoderOhcOHC_decoder
 
- Protected Attributes inherited from Base
unsigned long refCnt
 

Detailed Description

Definition at line 38 of file ophPAS_GPU.h.

Constructor & Destructor Documentation

◆ ophPAS_GPU() [1/4]

ophPAS_GPU::ophPAS_GPU ( void  )
explicit

Definition at line 25 of file ophPAS_GPU.cpp.

◆ ~ophPAS_GPU() [1/4]

ophPAS_GPU::~ophPAS_GPU ( )
protectedvirtual

Definition at line 30 of file ophPAS_GPU.cpp.

◆ ophPAS_GPU() [2/4]

ophPAS_GPU::ophPAS_GPU ( )
explicit

◆ ~ophPAS_GPU() [2/4]

virtual ophPAS_GPU::~ophPAS_GPU ( )
protectedvirtual

◆ ophPAS_GPU() [3/4]

ophPAS_GPU::ophPAS_GPU ( )
explicit

◆ ~ophPAS_GPU() [3/4]

virtual ophPAS_GPU::~ophPAS_GPU ( )
protectedvirtual

◆ ophPAS_GPU() [4/4]

ophPAS_GPU::ophPAS_GPU ( )
explicit

◆ ~ophPAS_GPU() [4/4]

virtual ophPAS_GPU::~ophPAS_GPU ( )
protectedvirtual

Member Function Documentation

◆ CalcCompensatedPhase() [1/4]

void ophPAS_GPU::CalcCompensatedPhase ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
int *  cf_cx,
int *  cf_cy,
float *  COStbl,
float *  SINtbl,
float **  inRe,
float **  inIm,
OphPointCloudConfig conf 
)

Definition at line 790 of file ophPAS_GPU.cpp.

◆ CalcCompensatedPhase() [2/4]

void ophPAS_GPU::CalcCompensatedPhase ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
int *  cf_cx,
int *  cf_cy,
float *  COStbl,
float *  SINtbl,
float **  inRe,
float **  inIm,
OphPointCloudConfig conf 
)

◆ CalcCompensatedPhase() [3/4]

void ophPAS_GPU::CalcCompensatedPhase ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
int *  cf_cx,
int *  cf_cy,
float *  COStbl,
float *  SINtbl,
float **  inRe,
float **  inIm,
OphPointCloudConfig conf 
)

◆ CalcCompensatedPhase() [4/4]

void ophPAS_GPU::CalcCompensatedPhase ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
int *  cf_cx,
int *  cf_cy,
float *  COStbl,
float *  SINtbl,
float **  inRe,
float **  inIm,
OphPointCloudConfig conf 
)

◆ CalcSpatialFrequency() [1/4]

void ophPAS_GPU::CalcSpatialFrequency ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
float *  sf_cx,
float *  sf_cy,
int *  pp_cx,
int *  pp_cy,
int *  cf_cx,
int *  cf_cy,
float  xiint,
float  etaint,
OphPointCloudConfig conf 
)

◆ CalcSpatialFrequency() [2/4]

void ophPAS_GPU::CalcSpatialFrequency ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
float *  sf_cx,
float *  sf_cy,
int *  pp_cx,
int *  pp_cy,
int *  cf_cx,
int *  cf_cy,
float  xiint,
float  etaint,
OphPointCloudConfig conf 
)

Definition at line 756 of file ophPAS_GPU.cpp.

◆ CalcSpatialFrequency() [3/4]

void ophPAS_GPU::CalcSpatialFrequency ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
float *  sf_cx,
float *  sf_cy,
int *  pp_cx,
int *  pp_cy,
int *  cf_cx,
int *  cf_cy,
float  xiint,
float  etaint,
OphPointCloudConfig conf 
)

◆ CalcSpatialFrequency() [4/4]

void ophPAS_GPU::CalcSpatialFrequency ( float  cx,
float  cy,
float  cz,
float  amp,
int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float  sf_base,
float *  xc,
float *  yc,
float *  sf_cx,
float *  sf_cy,
int *  pp_cx,
int *  pp_cy,
int *  cf_cx,
int *  cf_cy,
float  xiint,
float  etaint,
OphPointCloudConfig conf 
)

◆ DataInit() [1/8]

void ophPAS_GPU::DataInit ( int  segsize,
int  cghwidth,
int  cghheight,
float  xiinter,
float  etainter 
)

◆ DataInit() [2/8]

void ophPAS_GPU::DataInit ( int  segsize,
int  cghwidth,
int  cghheight,
float  xiinter,
float  etainter 
)

Definition at line 602 of file ophPAS_GPU.cpp.

◆ DataInit() [3/8]

void ophPAS_GPU::DataInit ( int  segsize,
int  cghwidth,
int  cghheight,
float  xiinter,
float  etainter 
)

◆ DataInit() [4/8]

void ophPAS_GPU::DataInit ( int  segsize,
int  cghwidth,
int  cghheight,
float  xiinter,
float  etainter 
)

◆ DataInit() [5/8]

void ophPAS_GPU::DataInit ( OphPointCloudConfig conf)

Definition at line 314 of file ophPAS_GPU.cpp.

◆ DataInit() [6/8]

void ophPAS_GPU::DataInit ( OphPointCloudConfig conf)

◆ DataInit() [7/8]

void ophPAS_GPU::DataInit ( OphPointCloudConfig conf)

◆ DataInit() [8/8]

void ophPAS_GPU::DataInit ( OphPointCloudConfig conf)

◆ encodeHologram() [1/4]

void ophPAS_GPU::encodeHologram ( const vec2  band_limit,
const vec2  spectrum_shift 
)

Definition at line 974 of file ophPAS_GPU.cpp.

◆ encodeHologram() [2/4]

void ophPAS_GPU::encodeHologram ( const vec2  band_limit,
const vec2  spectrum_shift 
)

◆ encodeHologram() [3/4]

void ophPAS_GPU::encodeHologram ( const vec2  band_limit,
const vec2  spectrum_shift 
)

◆ encodeHologram() [4/4]

void ophPAS_GPU::encodeHologram ( const vec2  band_limit,
const vec2  spectrum_shift 
)

◆ encoding() [1/4]

void ophPAS_GPU::encoding ( unsigned int  ENCODE_FLAG)

◆ encoding() [2/4]

void ophPAS_GPU::encoding ( unsigned int  ENCODE_FLAG)

Definition at line 1064 of file ophPAS_GPU.cpp.

◆ encoding() [3/4]

void ophPAS_GPU::encoding ( unsigned int  ENCODE_FLAG)

◆ encoding() [4/4]

void ophPAS_GPU::encoding ( unsigned int  ENCODE_FLAG)

◆ generateHologram() [1/4]

void ophPAS_GPU::generateHologram ( )

◆ generateHologram() [2/4]

void ophPAS_GPU::generateHologram ( )

◆ generateHologram() [3/4]

void ophPAS_GPU::generateHologram ( )

◆ generateHologram() [4/4]

void ophPAS_GPU::generateHologram ( void  )

Definition at line 733 of file ophPAS_GPU.cpp.

◆ loadPoint() [1/4]

int ophPAS_GPU::loadPoint ( const char *  _filename)

Definition at line 166 of file ophPAS_GPU.cpp.

◆ loadPoint() [2/4]

int ophPAS_GPU::loadPoint ( const char *  _filename)

◆ loadPoint() [3/4]

int ophPAS_GPU::loadPoint ( const char *  _filename)

◆ loadPoint() [4/4]

int ophPAS_GPU::loadPoint ( const char *  _filename)

◆ ltrim() [1/4]

char* ophPAS_GPU::ltrim ( char *  s)

◆ ltrim() [2/4]

char * ophPAS_GPU::ltrim ( char *  s)

Definition at line 282 of file ophPAS_GPU.cpp.

◆ ltrim() [3/4]

char* ophPAS_GPU::ltrim ( char *  s)

◆ ltrim() [4/4]

char* ophPAS_GPU::ltrim ( char *  s)

◆ MemoryRelease() [1/4]

void ophPAS_GPU::MemoryRelease ( void  )

◆ MemoryRelease() [2/4]

void ophPAS_GPU::MemoryRelease ( void  )

◆ MemoryRelease() [3/4]

void ophPAS_GPU::MemoryRelease ( void  )

Definition at line 690 of file ophPAS_GPU.cpp.

◆ MemoryRelease() [4/4]

void ophPAS_GPU::MemoryRelease ( void  )

◆ PAS() [1/4]

void ophPAS_GPU::PAS ( long  voxelnum,
OphPointCloudData data,
double *  m_pHologram,
OphPointCloudConfig conf 
)

◆ PAS() [2/4]

void ophPAS_GPU::PAS ( long  voxelnum,
OphPointCloudData data,
double *  m_pHologram,
OphPointCloudConfig conf 
)

◆ PAS() [3/4]

void ophPAS_GPU::PAS ( long  voxelnum,
OphPointCloudData data,
double *  m_pHologram,
OphPointCloudConfig conf 
)

Definition at line 494 of file ophPAS_GPU.cpp.

◆ PAS() [4/4]

void ophPAS_GPU::PAS ( long  voxelnum,
OphPointCloudData data,
double *  m_pHologram,
OphPointCloudConfig conf 
)

◆ PASCalculation() [1/4]

void ophPAS_GPU::PASCalculation ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

◆ PASCalculation() [2/4]

void ophPAS_GPU::PASCalculation ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

Definition at line 373 of file ophPAS_GPU.cpp.

◆ PASCalculation() [3/4]

void ophPAS_GPU::PASCalculation ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

◆ PASCalculation() [4/4]

void ophPAS_GPU::PASCalculation ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

◆ PASCalculation_GPU() [1/4]

void ophPAS_GPU::PASCalculation_GPU ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

◆ PASCalculation_GPU() [2/4]

void ophPAS_GPU::PASCalculation_GPU ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

◆ PASCalculation_GPU() [3/4]

void ophPAS_GPU::PASCalculation_GPU ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

◆ PASCalculation_GPU() [4/4]

void ophPAS_GPU::PASCalculation_GPU ( long  voxnum,
unsigned char *  cghfringe,
OphPointCloudData data,
OphPointCloudConfig conf 
)

Definition at line 746 of file ophPAS_GPU.cpp.

◆ readConfig() [1/4]

bool ophPAS_GPU::readConfig ( const char *  fname)

Definition at line 43 of file ophPAS_GPU.cpp.

◆ readConfig() [2/4]

bool ophPAS_GPU::readConfig ( const char *  fname)

◆ readConfig() [3/4]

bool ophPAS_GPU::readConfig ( const char *  fname)

◆ readConfig() [4/4]

bool ophPAS_GPU::readConfig ( const char *  fname)

◆ rtrim() [1/4]

char* ophPAS_GPU::rtrim ( char *  s)

◆ rtrim() [2/4]

char* ophPAS_GPU::rtrim ( char *  s)

◆ rtrim() [3/4]

char* ophPAS_GPU::rtrim ( char *  s)

◆ rtrim() [4/4]

char * ophPAS_GPU::rtrim ( char *  s)

Definition at line 266 of file ophPAS_GPU.cpp.

◆ RunFFTW() [1/4]

void ophPAS_GPU::RunFFTW ( int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float **  inRe,
float **  inIm,
fftw_complex *  in,
fftw_complex *  out,
fftw_plan *  plan,
double *  pHologram,
OphPointCloudConfig conf 
)

◆ RunFFTW() [2/4]

void ophPAS_GPU::RunFFTW ( int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float **  inRe,
float **  inIm,
fftw_complex *  in,
fftw_complex *  out,
fftw_plan *  plan,
double *  pHologram,
OphPointCloudConfig conf 
)

Definition at line 936 of file ophPAS_GPU.cpp.

◆ RunFFTW() [3/4]

void ophPAS_GPU::RunFFTW ( int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float **  inRe,
float **  inIm,
fftw_complex *  in,
fftw_complex *  out,
fftw_plan *  plan,
double *  pHologram,
OphPointCloudConfig conf 
)

◆ RunFFTW() [4/4]

void ophPAS_GPU::RunFFTW ( int  segnumx,
int  segnumy,
int  segsize,
int  hsegsize,
float **  inRe,
float **  inIm,
fftw_complex *  in,
fftw_complex *  out,
fftw_plan *  plan,
double *  pHologram,
OphPointCloudConfig conf 
)

◆ save() [1/8]

int ophPAS_GPU::save ( const char *  fname,
uint8_t  bitsperpixel,
uchar src,
uint  px,
uint  py 
)

◆ save() [2/8]

int ophPAS_GPU::save ( const char *  fname,
uint8_t  bitsperpixel,
uchar src,
uint  px,
uint  py 
)

Definition at line 175 of file ophPAS_GPU.cpp.

◆ save() [3/8]

int ophPAS_GPU::save ( const char *  fname,
uint8_t  bitsperpixel,
uchar src,
uint  px,
uint  py 
)

◆ save() [4/8]

int ophPAS_GPU::save ( const char *  fname,
uint8_t  bitsperpixel,
uchar src,
uint  px,
uint  py 
)

◆ save() [5/8]

void ophPAS_GPU::save ( const char *  fname)

◆ save() [6/8]

void ophPAS_GPU::save ( const char *  fname)

Definition at line 204 of file ophPAS_GPU.cpp.

◆ save() [7/8]

void ophPAS_GPU::save ( const char *  fname)

◆ save() [8/8]

void ophPAS_GPU::save ( const char *  fname)

◆ trim() [1/4]

char* ophPAS_GPU::trim ( char *  s)

◆ trim() [2/4]

char * ophPAS_GPU::trim ( char *  s)

Definition at line 301 of file ophPAS_GPU.cpp.

◆ trim() [3/4]

char* ophPAS_GPU::trim ( char *  s)

◆ trim() [4/4]

char* ophPAS_GPU::trim ( char *  s)

Member Data Documentation

◆ cgh_fringe

unsigned char * ophPAS_GPU::cgh_fringe

Definition at line 113 of file ophPAS_GPU.h.

◆ m_amp

float ophPAS_GPU::m_amp

Definition at line 129 of file ophPAS_GPU.h.

◆ m_Coefficient_cx

int * ophPAS_GPU::m_Coefficient_cx

Definition at line 109 of file ophPAS_GPU.h.

◆ m_Coefficient_cy

int * ophPAS_GPU::m_Coefficient_cy

Definition at line 110 of file ophPAS_GPU.h.

◆ m_COStbl

float * ophPAS_GPU::m_COStbl

Definition at line 94 of file ophPAS_GPU.h.

◆ m_cx

float ophPAS_GPU::m_cx

Definition at line 126 of file ophPAS_GPU.h.

◆ m_cy

float ophPAS_GPU::m_cy

Definition at line 127 of file ophPAS_GPU.h.

◆ m_cz

float ophPAS_GPU::m_cz

Definition at line 128 of file ophPAS_GPU.h.

◆ m_dsegSize

int ophPAS_GPU::m_dsegSize

Definition at line 99 of file ophPAS_GPU.h.

◆ m_hsegNumx

int ophPAS_GPU::m_hsegNumx

Definition at line 102 of file ophPAS_GPU.h.

◆ m_hsegNumy

int ophPAS_GPU::m_hsegNumy

Definition at line 103 of file ophPAS_GPU.h.

◆ m_hsegSize

int ophPAS_GPU::m_hsegSize

Definition at line 98 of file ophPAS_GPU.h.

◆ m_in

fftw_complex * ophPAS_GPU::m_in

Definition at line 118 of file ophPAS_GPU.h.

◆ m_inIm

float ** ophPAS_GPU::m_inIm

Definition at line 122 of file ophPAS_GPU.h.

◆ m_inIm_h

float * ophPAS_GPU::m_inIm_h

Definition at line 124 of file ophPAS_GPU.h.

◆ m_inImHost

float * ophPAS_GPU::m_inImHost

Definition at line 117 of file ophPAS_GPU.h.

◆ m_inRe

float ** ophPAS_GPU::m_inRe

Definition at line 121 of file ophPAS_GPU.h.

◆ m_inRe_h

float * ophPAS_GPU::m_inRe_h

Definition at line 123 of file ophPAS_GPU.h.

◆ m_inReHost

float * ophPAS_GPU::m_inReHost

Definition at line 116 of file ophPAS_GPU.h.

◆ m_out

fftw_complex * ophPAS_GPU::m_out

Definition at line 118 of file ophPAS_GPU.h.

◆ m_pHologram

double * ophPAS_GPU::m_pHologram

Definition at line 92 of file ophPAS_GPU.h.

◆ m_PickPoint_cx

int * ophPAS_GPU::m_PickPoint_cx

Definition at line 107 of file ophPAS_GPU.h.

◆ m_PickPoint_cy

int * ophPAS_GPU::m_PickPoint_cy

Definition at line 108 of file ophPAS_GPU.h.

◆ m_plan

fftw_plan ophPAS_GPU::m_plan

Definition at line 119 of file ophPAS_GPU.h.

◆ m_segNumx

int ophPAS_GPU::m_segNumx

Definition at line 100 of file ophPAS_GPU.h.

◆ m_segNumy

int ophPAS_GPU::m_segNumy

Definition at line 101 of file ophPAS_GPU.h.

◆ m_segSize

int ophPAS_GPU::m_segSize

Definition at line 97 of file ophPAS_GPU.h.

◆ m_sf_base

float ophPAS_GPU::m_sf_base

Definition at line 115 of file ophPAS_GPU.h.

◆ m_SFrequency_cx

float * ophPAS_GPU::m_SFrequency_cx

Definition at line 105 of file ophPAS_GPU.h.

◆ m_SFrequency_cy

float * ophPAS_GPU::m_SFrequency_cy

Definition at line 106 of file ophPAS_GPU.h.

◆ m_SINtbl

float * ophPAS_GPU::m_SINtbl

Definition at line 95 of file ophPAS_GPU.h.

◆ m_xc

float * ophPAS_GPU::m_xc

Definition at line 111 of file ophPAS_GPU.h.

◆ m_yc

float * ophPAS_GPU::m_yc

Definition at line 112 of file ophPAS_GPU.h.

◆ se

ivec3 ophPAS_GPU::se

Definition at line 131 of file ophPAS_GPU.h.


The documentation for this class was generated from the following files: