OpenDAFF C++ API  v1.7
Directional Audio File Format
DAFFContent.h
Go to the documentation of this file.
1 /*
2  * -------------------------------------------------------------------------------------
3  *
4  * OpenDAFF - A free, open source software package for directional audio data
5  * Copyright 2016 Institute of Technical Acoustics, RWTH Aachen University
6  * OpenDAFF is distributed under the Apache License Version 2.0.
7  *
8  * ------------------------------------------------------------------------------------
9  *
10  */
11 
12 #ifndef IW_DAFF_CONTENT
13 #define IW_DAFF_CONTENT
14 
15 #include <DAFFDefs.h>
16 
17 // Forward declarations
18 class DAFFProperties;
19 class DAFFReader;
20 class DAFFMetadata;
21 
23 
41 {
42 public:
43  inline virtual ~DAFFContent() {};
44 
46  /*
47  * @return The pointer to parent reader
48  */
49  virtual DAFFReader* getParent() const=0;
50 
52  /*
53  * @return The const pointer to properties
54  */
55  virtual const DAFFProperties* getProperties() const=0;
56 
58 
67  virtual const DAFFMetadata* getRecordMetadata( int iRecordIndex ) const=0;
68 
70 
78  virtual int getRecordCoords( int iRecordIndex, int iView, float& fAngle1Deg, float& fAngle2Deg ) const=0;
79 
81 
96  virtual void getNearestNeighbour( int iView, float fAngle1Deg, float fAngle2Deg, int& iRecordIndex ) const=0;
97 
99 
116  virtual void getNearestNeighbour( int iView, float fAngle1Deg, float fAngle2Deg, int& iRecordIndex, bool& bOutOfBounds ) const=0;
117 
119 
193  virtual void getCell(int iView, float fAngle1Deg, float fAngle2Deg, DAFFQuad& qIndices) const = 0;
194 
195  // --= Coordinate transformations =--
196 
198 
208  virtual void transformAnglesD2O( float fAlphaDeg, float fBetaDeg, float& fAzimuthDeg, float& fElevationDeg ) const=0;
209 
211 
221  virtual void transformAnglesO2D( float fAzimuthDeg, float fElevationDeg, float& fAlphaDeg, float& fBetaDeg) const=0;
222 };
223 
224 #endif // IW_DAFF_CONTENT
#define DAFF_API
Definition: DAFFDefs.h:29
Reader interface for DAFF files.
Definition: DAFFReader.h:116
virtual ~DAFFContent()
Definition: DAFFContent.h:43
Common content interface.
Definition: DAFFContent.h:40
Pure data class that describes the points of a quad by their indices and coordinates.
Definition: DAFFDefs.h:122
Metadata interface.
Definition: DAFFMetadata.h:31
Properties of a DAFF file that uses regular sphere grids (or parts of a regular grid) ...
OpenDAFF is a project from the Institute of Technical Acoustics, RWTH Aachen University, Germany.