Isomet Modular Synthesiser (iMS) API  v1.4.2
iMS API
Public Member Functions | Static Public Member Functions | List of all members
iMS::Frequency Class Reference

Type Definition for all operations that require a frequency specification. More...

#include <include/IMSTypeDefs.h>

Inheritance diagram for iMS::Frequency:
Inheritance graph
[legend]

Public Member Functions

 Frequency (double arg=0.0)
 Construct a Frequency object from a double argument representing Hertz. More...
 
Frequencyoperator= (double arg)
 Assignment of a double argument in Hertz to an existing Frequency object. More...
 
 operator double () const
 Return a double representing the Frequency value in Hertz. More...
 

Static Public Member Functions

static unsigned int RenderAsPointRate (const IMSSystem &, const Frequency, const bool PrescalerDisable=false)
 Used internally by the library to convert a Frequency object into an hardware-dependent integer representation used by the Image for Internal Oscillator frequency. More...
 

Detailed Description

Type Definition for all operations that require a frequency specification.

Internally, the Frequency value is stored as a double precision variable specified in Hertz

Author
Dave Cowan
Date
2015-11-03
Since
1.0

Constructor & Destructor Documentation

iMS::Frequency::Frequency ( double  arg = 0.0)
inline

Construct a Frequency object from a double argument representing Hertz.

Parameters
[in]argFrequency in Hertz
Since
1.0

Member Function Documentation

iMS::Frequency::operator double ( ) const
inline

Return a double representing the Frequency value in Hertz.

kHz f1(1.2);
Frequency f2 = f1();
std::cout << "f2's Frequency is: " << f2() << "Hz" << std::endl;

prints:

f2's Frequency is 1200.0Hz
Since
1.0
Frequency& iMS::Frequency::operator= ( double  arg)
inline

Assignment of a double argument in Hertz to an existing Frequency object.

f = 1000.0;
// f contains 1000Hz
Since
1.0
static unsigned int iMS::Frequency::RenderAsPointRate ( const IMSSystem ,
const Frequency  ,
const bool  PrescalerDisable = false 
)
static

Used internally by the library to convert a Frequency object into an hardware-dependent integer representation used by the Image for Internal Oscillator frequency.

Not intended for use in application code


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