foobar2000 SDK  2015-01-14
Public Types | Public Member Functions
visualisation_managerabstract

#include <vis.h>

+ Inheritance diagram for visualisation_manager:

Public Types

enum  { KStreamFlagNewFFT = 1 << 0 }
 
- Public Types inherited from service_base
typedef service_base t_interface
 

Public Member Functions

virtual void create_stream (service_ptr_t< visualisation_stream > &p_out, unsigned p_flags)=0
 
template<typename t_streamptr >
void create_stream (t_streamptr &out, unsigned flags)
 
 FB2K_MAKE_SERVICE_INTERFACE_ENTRYPOINT (visualisation_manager)
 
- Public Member Functions inherited from service_base
template<typename outPtr_t >
bool cast (outPtr_t &outPtr)
 
virtual int service_add_ref ()=0 throw ()
 
virtual bool service_query (service_ptr_t< service_base > &p_out, const GUID &p_guid)
 
template<class T >
bool service_query_t (service_ptr_t< T > &p_out)
 
virtual int service_release ()=0 throw ()
 

Additional Inherited Members

- Protected Member Functions inherited from service_base
 service_base ()
 
 ~service_base ()
 

Detailed Description

Entrypoint service for visualisation processing; use this to create visualisation_stream objects that can be used to retrieve properties of currently played audio.
Implemented by core; do not reimplement.
Use static_api_ptr_t to access it, e.g. static_api_ptr_t<visualisation_manager>()->create_stream(mystream,0);.

Definition at line 55 of file vis.h.

Member Enumeration Documentation

anonymous enum
Enumerator
KStreamFlagNewFFT 

New FFT behavior for spectrum-generating methods, available in 0.9.5.2 and newer: output normalized to 0..1, Gauss window used instead of rectangluar (better quality / less aliasing). It's recommended to always set this flag. The old behavior is preserved for backwards compatibility.

Definition at line 63 of file vis.h.

63  {
66  KStreamFlagNewFFT = 1 << 0,
67  };
New FFT behavior for spectrum-generating methods, available in 0.9.5.2 and newer: output normalized t...
Definition: vis.h:66

Member Function Documentation

virtual void visualisation_manager::create_stream ( service_ptr_t< visualisation_stream > &  p_out,
unsigned  p_flags 
)
pure virtual

Creates a visualisation_stream object. See visualisation_stream for more info.

Parameters
p_outReceives newly created visualisation_stream instance.
p_flagsCombination of one or more KStreamFlag* values. Currently only KStreamFlagNewFFT is defined. It's recommended that you set p_flags to KStreamFlagNewFFT to get the new FFT behavior (better quality and result normalization), the old behavior for null flags is preserved for compatibility with old components that rely on it.
template<typename t_streamptr >
void visualisation_manager::create_stream ( t_streamptr &  out,
unsigned  flags 
)
inline

Wrapper around non-template create_stream(); retrieves one of newer visualisation_stream_* interfaces rather than base visualisation_stream interface. Throws exception_service_extension_not_found() when running too old foobar2000 version for the requested interface.

Definition at line 72 of file vis.h.

72  {
73  visualisation_stream::ptr temp; create_stream(temp, flags);
74  if (!temp->service_query_t(out)) throw exception_service_extension_not_found();
75  }
virtual void create_stream(service_ptr_t< visualisation_stream > &p_out, unsigned p_flags)=0
Creates a visualisation_stream object. See visualisation_stream for more info.
visualisation_manager::FB2K_MAKE_SERVICE_INTERFACE_ENTRYPOINT ( visualisation_manager  )

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