#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  This file contains the parameters settings for the Gpiv and Gpivtools
#  packages and is installed for system-wide use during installation
#  of Libgpiv (at /etc for most of *nix-like systems).
#
#  For personalizing the parameters, copy this file to $HOME/.gpivrc and adapt 
#  it ti your needs. The system-wide configuration and the personalized parameters
#  may be overruled by ./gpivrc (at local directory) or by the 
#  command-line keys of the Gpivtools programs.
#
#  If a parameter is not defined by the command-line keys or in one of
#  the parameter resources $HOME/.gpivrc and (system-wide) gpivr.conf, its 
#  default value will be taken from Libgpiv, as defined in the headers. 
#  
#  Each parameter is described by the module key (CAM, TRIG, IMG,
#  IMGPROC, PIV, VALID or POST) and the parameter name, separated by
#  a dot (.), followed by its value. Some of the parameters are
#  optional. The parameters may be defined in arbitrary order. Blank
#  lines and comment (starting with a pound sign (#) at the first
#  column) may be included in the parameter files.
#
#------------------------------------------------------------------------------


#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Camera parameters (key: CAM)
#  Only active if camera has been enabled during compilation by:
# ./configure --enable-cam
#------------------------------------------------------------------------------

#  Operating mode (indefinite/interrupt/definite)
#  Default 1
CAM.Mode 1

#  number of cycles (equal to number of images to be recorded?)
#  Default 1
CAM.Cycles 1

#  Image filename
#  Default gpiv_img
CAM.Fname gpiv_img



#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Real Time Application Interface (RTAI) trigger parameters (key TRIG)
#  Only active if triggering has been enabled during compilation by:
# ./configure --enable-trig
#------------------------------------------------------------------------------

#  Trigger time settings:
#  All timings are internally expressed in nano seconds. The parameters here
#  are expressed in milliseconds. It is thought that this is more convenient,
#  while this policy is used as well by the gpivtrig module and Rtai packages.
#  Camera acquisition period time
#  Default 250
TRIG.Ttime_cap 250.0

#  Laser trigger pulse width
#  Default 0.02
TRIG.Ttime_lpw 0.02

#  Time from laser trigger->Hi until laser pulse 0.19 ms
#  Default 0.19
TRIG.Ttime_t2l 0.19

#  Time between 2 laser exposures
#  Default 10
TRIG.Ttime_dt 10

#  Operating mode (indefinite/interrupt/definite)
#  Default 2
TRIG.Ttime_mode 2

#  number of cycles (equal to number of images to be recorded?)
#  Default 1
TRIG.Ttime_cycles 1

#  Increment in dt
#  Default 1
TRIG.Ttime_incr_dt 1



#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Image parameters
#  Required parameters for reading the image should be present in the 
#  image header or the software will return an error
#------------------------------------------------------------------------------

#  DEPRECIATED should be defined in image header
#  Number of columns containing the image
#  Default 256
##IMG.ncolumns 256


#  DEPRECIATED should be defined in image header
#  Number of rowss containing the image
#  Default 256
##IMG.nrows 256

#  DEPRECIATED should be defined in image header
#  Image color depth (1 - 16)
#  Default 8
IMG.depth 8

#  Image contains a single frame for autocorrelation (0) or 
#  or two frames fror cross-correlation (1)
#  Default 1
IMG.x_corr 1


#  --------------------------------------------- used by gpiv_post_scale()
#  Spatial scale expressed in mm/pixel * 10-3
#  Default 1.0
IMG.s_scale 9.0


#  Time scale; separation time between subsequent image recordings,
#  expressed in milliseconds
#  Default 1.0
IMG.t_scale 7.0


#  Zero offset of pixel(0,0) in relatation to a specific point in the 
#  experiment, expressed in meters

#  Default 0.0
IMG.zoff_x 10.0

#  Default 0.0
IMG.zoff_y 20.0


#  ------------------------------------------------- Optional parameters
# IMG.title 
# IMG.creation_date:
# IMG.location 
# IMG.author 
# IMG.software:
# IMG.source:
# IMG.usertext 
# IMG.warning:
# IMG.disclaimer:
# IMG.comment:
# IMG.copyright:
# IMG.email:
IMG.url gpiv.sourceforge.net


#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Parameters for image processing (key: IMGPROC)
#------------------------------------------------------------------------------

#  Used for mean image value calculation
#  First numbered directory to search for (numbered) images for processing
#  Default 0
#IMGPROC.First_dir:

#  Last numbered directory to search for (numbered) images for processing
#  Default 0
#IMGPROC.Last_dir:

# Prefix to directory name
#  Default ./
#IMGPROC.Dir_prefix:

# First numbered file name of image for processing
#  Default 0
#IMGPROC.First_file:

# Last numbered file name of image for processing
#  Default 0
#IMGPROC.Last_file:

# Prefix to file name
#  Default img
#IMGPROC.File_Prefix:


#  Used for filtering on single image or image pair:
#  NONE = 0
#  SMOOTH = 1
#  HILO = 2
#  CLIP = 3
#  FFT = 4
#  INVFFT = 5
#  CORR = 6
#  CONV = 7
#  BANDPASS = 8
#  PT_GETBIT = 9
#IMGPROC.Filter:

#  Default 0
#IMGPROC.Smooth_operator:

#  Default 10
#IMGPROC.Window:

#  Default 30
#IMGPROC.Threshold:



#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Parameters of PIV image evaluation (= interrogation) (key: PIV)
#------------------------------------------------------------------------------

#  Column to start first interrogation area (start with 0)
#  Default 0
PIV.Col_start 0


#  Column to start last interrogation area
#  Default 255
PIV.Col_end 255


#  Line (or row) to start first interrogation area (start with 0)
#  Default 0
PIV.Row_start 0


#  Line (or row) to start last interrogation area
#  Default 255
PIV.Row_end 255


#  First interrogation size (not necessary to be power of 2).
#  Default 64
PIV.Int_size_i 32


#  Second interrogation size (not necessary to be power of 2), 
#  has to be equal or larger than the First interrogation size).
#  Default 32
PIV.Int_size_f 32


#  shift of adjacent interrogation area
#  Default 16
PIV.Int_shift 16


#  pre-shift in x-direction (columns)
#  Default 0
PIV.Pre_shift_col 0


#  pre-shift in y-direction (rows)
#  Default 0
PIV.Pre_shift_row 0


#  Adopt image data to interrogation area in order to correct for biasing
#  effects 
#  0; no correction
#  1; linear kernel weighting
#  2; zero offsettting
#  3; zero ofsetting using central differential scheme
#  4; image deformation
#  Default 4
PIV.Int_scheme 4


#  Applies Gauss weighting to the Interrogation Area's to reduce the high 
#  spatial frequency signal generated from teh I.A. borders. This may improve 
#  the accuracy of the analyses.
#  Default 1
PIV.Gauss_weight_ia 1

#  Applies Symmetric Phase Only filtering
#  This may reduce background scatter or flare light, reflected from surfaces
#  and improve SNR
#  Default 0
PIV.Spof_filter 0


#  Calculates first (1),second (2) or third (3) highest peak in the covariance 
#  function
#  Default 1
PIV.Peak 1


#  type of sub-pixel fit; 
#  None = 0, 
#  Gauss=1, 
#  Power law=2, 
#  Grav=3
#  Default 1
PIV.Ifit 1



#  Interrogation geometry to be analysed: Area of Interest (0),
#  defined by col/row start/end, vertical line (1) defined by int_line_col,
#  horizontal line (2), defined by int_line_row or point (3), defined by 
#  point_col and point_row
#  Default 0
PIV.Int_geo 0

#  Default 64
PIV.Int_line_col 64
#  Default 0
PIV.Int_line_row_start 0 
#  Default 127
PIV.Int_line_row_end 127

#  Default 64
PIV.Int_line_row 64
#  Default 0
PIV.Int_line_col_start 0 
#  Default 127
PIV.Int_line_col_end 127


#  Select a single interrogation region with centre PIV.Point_col 
#  PIV.Point_row to interrogate (optional parameter)
#  Default 64
#PIV.Int_point_col 64
#  Default 64
#PIV.Int_point_row 64


#  Sub-pixel maximum estimation. Obtains peak (at integer pixel level)
#  from an old piv file and uses as it pre-shifted values. 
#  RR Still needs the images for
#  calculation of covariance function! (1/0)
#  Default 0
PIV.Old_piv 0



#  Sets automatically parameters that belong to others  (optional parameter):
#  Set zero_off 1 if ad_int is set
#  Set weight  0 if zero_off is set and Set weight 1 if zero_off is not set
#  Default 1
PIV.Autokey 1




#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#   Parameters PIV data validation (key: VALID)
#-----------------------------------------------------------------------------

#  Maximum allowed residu value (from mean or median calculation) for 
#  acceptance. 
#  Default GPIV_RESIDU_MAX__RELMEDIAN, if VALID.Residu_Type = 2, else
#  Default 2.0
VALID.Residu_max 2.0

#  Odd number, representing the number of neighboring PIV data that will
*  be used to calculate the (median) residu and average local mean. 
#  Typically 3x3, maximum 9x9.
#  Default 3
VALID.Neighbors 3


#  Determines the residual of a particle displacement 
#  0: from the SNR value
#  1: from the median residual with its surroundings
#  2: normalized median: ratio between median residu with current datapoint 
#  included and between median residu of surroundigs (with datapoint excluded) 
#  Default 2
VALID.Residu_type 2


#  Substitutes erroneous displacements by:
#  0: not substituted, only peak_nr in PIV data set is set to 0
#  1: the mean of surroundings
#  2: median
#  3: the next highest correlation peak
#  Default 2
VALID.Subst_type 2


#  Use histogram (0) or cumulative histogram (1)
#  Default 0
VALID.Histo_type 0


#  Checking on outliers after substituion (REMOVE??)
VALID.Check 0


#  TODO:: Automatic threshold detection (from histogram analysis) 
VALID.Auto_thresh 0


#  Estimation of the data yield from particle image concentration, 
#  out-of plane flow, velocity gradient within interrogation area.
#  ref: Keane and Adrian 1992
#  Default 0.95
VALID.Data_yield 0.95




#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Parameters post-processing, used by program manipiv (key: POST)
#-----------------------------------------------------------------------------

#  Operation on PIV data:
#   fast_y = 0
#   flip_x = 1 
#   flip_y = 2 
#   revert = 3 
#   rot90 = 4  
#   rot180 = 5  
#   filter_block = 6 
#   pass_block = 7
#  Default 0
POST.Operator_manipiv 0

#  Set disabled data to a specified value (1/0):
#  Default 1
POST.Set 1


#  Define x-displacement (columns, horizontal direction) to be set for 
#  disabled data:
#  Default 0.0
POST.Set_dx 0.0


#  Define y-displacement (rows, vertical direction) to be set for 
#  disabled data:
#  Default 0.0
POST.Set_dy 0.0

#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Parameters post-processing, used by program s-avg (key: POST)
#-----------------------------------------------------------------------------

#  Subtracting displacements or velocity estimators with:
#  NONE (0), 
#  mean value (1) or 
#  Zoff_dx and Zoff_dy (2)

#  Default 0
POST.Subtract 0

#  Default 0.0
POST.Zoff_dx 0.0

#  Default 0.0
POST.Zoff_dy 0.0


#++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
#  Parameters post-processing, used by program vorstra (key: POST)
#-----------------------------------------------------------------------------

#  Differentiation_Type:
#  central = 0 
#  least_squares = 1 
#  richardson = 2 
#  circulation = 3
#  Default 2
POST.Differential_type 2


#  Calculate from PIV data:
#  vorticity = 0 
#  shear strain = 1
#  normal strain = 2
#  Default 0
POST.Operator_vorstra 0

#  Normal (0) or inverse (1) scaling
#  Default 0
POST.Scale_type 0









