VR-Vantage 3.0.3 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ciElectronics.h
Go to the documentation of this file.
1 
2 // Copyright JRM Enterprises, Inc. 2004
3 // All rights reserved.
4 //
5 // This code is the intellectual property of JRM Enterprises, Inc.
6 // It may not be used or released as source or compiled binary form
7 // without the prior written consent of JRM Enterprises, Inc.
8 //
9 // Original Author: Mike Ortalano
10 // Date: Nov 2004
11 //
12 //
13 //
15 
16 #if !defined(_ciELECTRONICS_H_)
17 #define _ciELECTRONICS_H_
18 
19 #if _MSC_VER > 1000
20 #pragma once
21 #endif // _MSC_VER > 1000
22 
26 #include "ciApi.h"
27 #include <stdio.h>
28 #include <string.h>
29 #include <fstream>
30 #include <iostream>
31 #include <assert.h>
32 #include <string.h>
33 #include "clXML.h"
34 #include "clXMLNode.h"
35 
37 {
38 
39 public: // methods
40 
41 
43  // getFrameRate
50  double getFrameRate() { return m_frameRate; }
51 
52 
54  // setFrameRate
62  void setFrameRate( double frameRate ) { m_frameRate = frameRate; }
63 
64 
66  // getPreCutonFreq
73  double getPreCutonFreq() { return m_preCutonFreq; }
74 
76  // setPreCutonFreq
84  void setPreCutonFreq( double preCutonFreq ){ m_preCutonFreq = preCutonFreq; }
86  // getPostCutoffFreq
93  double getPostCutoffFreq() { return m_postCutoffFreq; }
94 
96  // setPostCutoffFreq
104  void setPostCutoffFreq( double postCutoffFreq ){ m_postCutoffFreq = postCutoffFreq; }
105 
107  // getGain
114  double getGain() { return m_gain; }
115 
117  // setGain
125  void setGain( double gain ) { m_gain = gain; }
127  //setAGCMaxGain
132  void setAGCMaxGain(const double gain) {
133  m_AGCMaxGain = gain;
134  }
135 
137  //getAGCMaxGain
142  double getAGCMaxGain(){return m_AGCMaxGain;}
143 
145  //setAGCMinGain
150  void setAGCMinGain(const double gain) {
151  m_AGCMinGain = gain;
152  }
153 
155  //getAGCMinGain
160  double getAGCMinGain(){return m_AGCMinGain;}
161 
162 
164  //setPercentGain
169  void setPercentGain(double percent){m_percentGain = percent;}
170 
172  //getPercentGain
177  double getPercentGain(){return m_percentGain;}
178 
180  //setPercentLevel
185  void setPercentLevel(double percent){m_percentLevel = percent;}
186 
188  //getPercentLevel
193  double getPercentLevel(){return m_percentLevel;}
194 
195 
197  // getLevel
204  double getLevel() { return m_level; }
205 
207  // setLevel
215  void setLevel( double level ){ m_level = level; }
216 
218  //getColorMapType
222  int getColorMapType() { return m_colorMapType; }
223 
225  //setColorMapType
229  void setColorMapType(int type) { m_colorMapType = type; }
230 
232  //getColorMapUserDefinedRadFile
236  char* getColorMapUserDefinedRadFile() { return m_colorMapUserDefinedRadFile; }
237 
239  //setColorMapUserDefinedRadFile
243  void setColorMapUserDefinedRadFile(const char* filepath);
244 
246  //getColorMapEnable
250  bool getColorMapEnable() { return m_colorMapEnable; }
251 
253  //setColorMapEnable
257  void setColorMapEnable(bool enable) { m_colorMapEnable = enable; }
258 
260  //setSensorIndex
265  void setSensorIndex(int sensorIndex){m_sensorIndex = sensorIndex;}
267  //getSensorIndex
272  int getSensorIndex(){return m_sensorIndex;}
273 
275  // archive
283  bool archive(std::ofstream &outf, int idx = 0);
284 
286  // serialize
294  int serialize(char *filepath, int idx);
295 
296  //
297  // loadXML
298  //
299  // \par Description:
300  // Loads attributes from an XML node
301  //
302  // \param clXMLNode* xmlParentNode
303  // \return bool
304  //
305  bool loadXML(clXMLNode* xmlParentNode);
306 
307  //
308  // parseXML
309  //
310  // \par Description:
311  // Parses an XML document for specific tags
312  //
313  // \param clXML xmlDocument
314  // \return bool
315  //
316  bool parseXML(clXML& xmlDocument);
317 
319  //loadXMLNode
326  bool loadXMLNode(std::string tag, char *nodeString);
328  //loadXMLNode
335  bool loadXMLNode(std::string tag, bool *nodeBool);
337  //loadXMLNode
344  bool loadXMLNode(std::string tag, int *nodeInt);
346  //loadXMLNode
353  bool loadXMLNode(std::string tag, long *nodeLong);
355  //loadXMLNode
362  bool loadXMLNode(std::string tag, double *nodeDouble);
363 
364  //
365  // saveXML
366  //
367  // \par Description:
368  // Saves XML nodes to an XML document
369  //
370  // \param clXML* xmlDocument
371  //
372  void saveXML(clXML* xmlDocument);
373 
375  //serializeCheck
381  int serializeCheck(char *filepath);
382 
384  // operator =
392  ciElectronics operator = (ciElectronics &obj);
393 
394 protected: // methods
395 
396 public: // construction/destruction
397 
399  // ciElectronics
404  ciElectronics();
405 
407  // ciElectronics
415 
417  //~ciElectronics
422  virtual ~ciElectronics();
423 
424 protected: // variables
425 
426  double m_frameRate; // frame rate [hz]
427  double m_preCutonFreq; // pre-cuton frequency [hz]
428  double m_postCutoffFreq; // post-cutoff frequency [hz]
429  double m_gain; // gain
430  double m_level; // level
431  double m_AGCMaxGain; // maximum gain used by AGC
432  double m_AGCMinGain; // minimum level used by AGC
436  int m_colorMapType; //color map type. in seElectronics it is an enum
437  char m_colorMapUserDefinedRadFile[512]; //*.rad file
438  bool m_colorMapEnable; //Is color mapping turned enabled
440 
441 private: // variables
442 
443 };
444 
445 #endif // _ciELECTRONICS_H_


Copyright © 2005-2023 MAK Technologies. All Rights Reserved (www.mak.com)