foobar2000 SDK  2015-01-14
Public Member Functions | Static Public Member Functions
album_art_dataabstract

#include <album_art.h>

+ Inheritance diagram for album_art_data:

Public Member Functions

 FB2K_MAKE_SERVICE_INTERFACE (album_art_data, service_base)
 
virtual const void * get_ptr () const =0
 
virtual t_size get_size () const =0
 
bool operator!= (const album_art_data &other) const
 
bool operator== (const album_art_data &other) const
 
- 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 ()
 

Static Public Member Functions

static bool equals (album_art_data const &v1, album_art_data const &v2)
 

Additional Inherited Members

- Public Types inherited from service_base
typedef service_base t_interface
 
- Protected Member Functions inherited from service_base
 service_base ()
 
 ~service_base ()
 

Detailed Description

Common class for handling picture data.
Type of contained picture data is unknown and to be determined according to memory block contents by code parsing/rendering the picture. Commonly encountered types are: BMP, PNG, JPEG and GIF.
Implementation: use album_art_data_impl.

Definition at line 4 of file album_art.h.

Member Function Documentation

static bool album_art_data::equals ( album_art_data const &  v1,
album_art_data const &  v2 
)
inlinestatic

Determine whether two album_art_data objects store the same picture data.

Definition at line 12 of file album_art.h.

12  {
13  const t_size s = v1.get_size();
14  if (s != v2.get_size()) return false;
15  return memcmp(v1.get_ptr(), v2.get_ptr(),s) == 0;
16  }
size_t t_size
Definition: int_types.h:48
album_art_data::FB2K_MAKE_SERVICE_INTERFACE ( album_art_data  ,
service_base   
)
virtual const void* album_art_data::get_ptr ( ) const
pure virtual

Retrieves a pointer to a memory block containing the picture.

Implemented in album_art_data_impl.

virtual t_size album_art_data::get_size ( ) const
pure virtual

Retrieves size of the memory block containing the picture.

Implemented in album_art_data_impl.

bool album_art_data::operator!= ( const album_art_data other) const
inline

Definition at line 18 of file album_art.h.

18 {return !equals(*this,other);}
static bool equals(album_art_data const &v1, album_art_data const &v2)
Determine whether two album_art_data objects store the same picture data.
Definition: album_art.h:12
bool album_art_data::operator== ( const album_art_data other) const
inline

Definition at line 17 of file album_art.h.

17 {return equals(*this,other);}
static bool equals(album_art_data const &v1, album_art_data const &v2)
Determine whether two album_art_data objects store the same picture data.
Definition: album_art.h:12

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