SDRAngel  4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
leansdr::simplequeue< T, _SIZE > Struct Template Reference

#include <dvbs2.h>

Public Member Functions

 simplequeue ()
 
bool full ()
 
T * put ()
 
bool empty ()
 
const T * peek ()
 
const T * get ()
 

Public Attributes

int rd
 
int wr
 
int count
 
q [SIZE]
 

Static Public Attributes

static const int SIZE = _SIZE
 

Detailed Description

template<typename T, int _SIZE>
struct leansdr::simplequeue< T, _SIZE >

Definition at line 2181 of file dvbs2.h.

Constructor & Destructor Documentation

◆ simplequeue()

template<typename T, int _SIZE>
leansdr::simplequeue< T, _SIZE >::simplequeue ( )
inline

Definition at line 2184 of file dvbs2.h.

2184 { rd = wr = count = 0; }

Member Function Documentation

◆ empty()

template<typename T, int _SIZE>
bool leansdr::simplequeue< T, _SIZE >::empty ( )
inline

Definition at line 2193 of file dvbs2.h.

2193 { return count == 0; }

◆ full()

template<typename T, int _SIZE>
bool leansdr::simplequeue< T, _SIZE >::full ( )
inline

Definition at line 2185 of file dvbs2.h.

2185 { return count == SIZE; }
static const int SIZE
Definition: dvbs2.h:2183

◆ get()

template<typename T, int _SIZE>
const T* leansdr::simplequeue< T, _SIZE >::get ( )
inline

Definition at line 2195 of file dvbs2.h.

2196  {
2197  const T *res = &q[rd];
2198  rd = (rd + 1) % SIZE;
2199  --count;
2200  return res;
2201  }
static const int SIZE
Definition: dvbs2.h:2183

◆ peek()

template<typename T, int _SIZE>
const T* leansdr::simplequeue< T, _SIZE >::peek ( )
inline

Definition at line 2194 of file dvbs2.h.

2194 { return &q[rd]; }

◆ put()

template<typename T, int _SIZE>
T* leansdr::simplequeue< T, _SIZE >::put ( )
inline

Definition at line 2186 of file dvbs2.h.

Referenced by leansdr::s2_fecdec_helper< SOFTBIT, SOFTBYTE >::send_frame().

2187  {
2188  T *res = &q[wr];
2189  wr = (wr + 1) % SIZE;
2190  ++count;
2191  return res;
2192  }
static const int SIZE
Definition: dvbs2.h:2183
+ Here is the caller graph for this function:

Member Data Documentation

◆ count

template<typename T, int _SIZE>
int leansdr::simplequeue< T, _SIZE >::count

Definition at line 2203 of file dvbs2.h.

◆ q

template<typename T, int _SIZE>
T leansdr::simplequeue< T, _SIZE >::q[SIZE]

Definition at line 2204 of file dvbs2.h.

◆ rd

template<typename T, int _SIZE>
int leansdr::simplequeue< T, _SIZE >::rd

Definition at line 2203 of file dvbs2.h.

◆ SIZE

template<typename T, int _SIZE>
const int leansdr::simplequeue< T, _SIZE >::SIZE = _SIZE
static

Definition at line 2183 of file dvbs2.h.

◆ wr

template<typename T, int _SIZE>
int leansdr::simplequeue< T, _SIZE >::wr

Definition at line 2203 of file dvbs2.h.


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