⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 wvout.h

📁 Mobile STK for Symbian OS V0.1
💻 H
字号:
/***************************************************//*! \class WvOut    \brief STK audio output abstract base class.    This class provides common functionality for a variety of audio    data output subclasses.    WvOut supports multi-channel data.  It is important to distinguish    the tick() methods, which output single samples to all channels in    a sample frame, from the tickFrame() methods, which take a pointer    or reference to multi-channel sample frame data.    Both interleaved and non-interleaved data is supported via the use    of StkFrames objects.    Currently, WvOut is non-interpolating and the output rate is    always Stk::sampleRate().    by Perry R. Cook and Gary P. Scavone, 1995 - 2005.*//***************************************************/#ifndef STK_WVOUT_H#define STK_WVOUT_H#include "Stk.h"#if !defined(SYMBIAN)#include <vector>#else#include "symbmath.h"#endifclass WvOut : public Stk{ public:  //! Default constructor.  WvOut();  //! Class destructor.  virtual ~WvOut();  //! Return the number of sample frames output.  unsigned long getFrameCount( void ) const;  //! Return the number of seconds of data output.  StkFloat getTime( void ) const;  //! Returns \c true if clipping has been detected during output since instantiation or the last reset.  bool clipStatus( void ) { return clipping_; };  //! Reset the clipping status to \c false.  void resetClipStatus( void ) { clipping_ = false; };  //! Output a single sample to all channels in a sample frame.  /*!    An StkError is thrown if an output error occurs.  */  void tick( const StkFloat sample );  //! Output a channel of the StkFrames object to all channels of the WvOut object.  /*!    The \c channel argument should be 0 or greater (the first    channel is specified by 0).  An StkError will be thrown if an    output error occurs or if the \c channel argument is equal to or    greater than the number of channels in the StkFrames object.  */  void tick( const StkFrames& frames, unsigned int channel = 0 );  //! Output the StkFrames data.  /*!    An StkError will be thrown if an output error occurs or if    there is an incompatability between the number of channels in the    WvOut object and that in the StkFrames object.  */  void tickFrame( const StkFrames& frames ); protected:  // These abstract functions must be implemented in all subclasses.  // They are used to get around a C++ problem with overloaded virtual  // functions.  virtual void computeSample( const StkFloat sample ) = 0;  virtual void computeFrames( const StkFrames& frames ) = 0;  // Check for sample clipping and clamp.  StkFloat& clipTest( StkFloat& sample );  StkFrames data_;  unsigned long frameCounter_;  bool clipping_;};//#endif // SYMBIAN#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -