wosh::interfaces::entertainment::PlayerAudio Class Reference
[WOSH Interfaces]

Specification of a generic audio player (device). More...

#include <H:/WOSH/win32_vc2010/src/interfaces/entertainment/PlayerAudio.h>

List of all members.

Public Member Functions

PlayerAudio Interface - Playback
virtual WRESULT play (const std::string &file_url, int volume=-1, bool override_current=false)=0
 Play a resource.
virtual WRESULT play (unsigned int index)=0
virtual WRESULT play ()=0
 Play the current media.
virtual WRESULT pause ()=0
 Pause the current media, keeping track of position. Continue calling play()
virtual WRESULT stop ()=0
 Stop the current media.
virtual WRESULT first ()=0
 Play the first element in the playlist.
virtual WRESULT next ()=0
 Play the next element in the playlist.
virtual WRESULT prev ()=0
 Play the previous element in the playlist.
virtual WRESULT last ()=0
 Play the last element in the playlist.
virtual WRESULT enqueue (const std::string &file_url)=0
virtual WRESULT remove (unsigned int index)=0
virtual WRESULT clear ()=0
 Clear the playlist. Won't necessary stop current playback.
PlayerAudio Interface - Setters
virtual WRESULT setVolume (int newVolume)=0
 Set the volume of device.
virtual WRESULT setVolumeOffset (int volume_span)=0
virtual WRESULT setMute (bool on)=0
virtual WRESULT setRandom (short value)=0
virtual WRESULT setRepeat (short value)=0
virtual WRESULT setCrossfade (int crossfade_seconds)=0
virtual WRESULT setPosition (float position_rate)=0
virtual WRESULT setPositionOffset (float position_rate_offset)=0
virtual WRESULT setPositionMs (int64 position_ms)=0
PlayerAudio Interface - Getters
virtual bool isPlaying () const =0
virtual long getPlayListIndex () const =0
virtual long getPlayListLength () const =0
virtual int getVolume () const =0
virtual bool isMuted () const =0
virtual int getCrossfade () const =0
virtual short getRepeat () const =0
virtual short getRandom () const =0
virtual float getPosition () const =0
virtual std::string getPositionStr () const =0
virtual int64 getPositionMs () const =0
virtual int64 getLengthMs () const =0
virtual std::string getLengthStr () const =0

Detailed Description

Specification of a generic audio player (device).

The interface provides field and method definitions for a standard audio player device. Implementations act as software-abstraction of the real device (or driver).

Properties:

Methods:

See also:
wosh::entertainment, WOSH Entertainment Framework
wosh::rmi::skeletons::PlayerAudio
wosh::bundles::PlayerGStreamerBundle
wosh::bundles::PlayerPhononBundle
wosh::bundles::VlcPlayerBundle
wosh::interfaces::entertainment::PlayerAudioMpd
Version:
0.8.558
Id:
PlayerAudio.h 3775 2011-01-01 16:38:17Z alex
Author:
Alessandro Polo

Definition at line 124 of file PlayerAudio.h.


Member Function Documentation

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::clear (  ) [pure virtual]

Clear the playlist. Won't necessary stop current playback.

Returns:
WRET_OK if playlist has been cleared. Check custom implementation error codes.

Implemented in PlayerGStreamer, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::first (  ) [pure virtual]

Play the first element in the playlist.

Returns:
WRET_ERR_ILLEGAL_USE when playlist is empty/invalid; WRET_OK when playback is starting

Implemented in PlayerGStreamer, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::last (  ) [pure virtual]

Play the last element in the playlist.

Returns:
WRET_ERR_ILLEGAL_USE when playlist is empty/invalid; WRET_OK when playback is starting

Implemented in PlayerGStreamer, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::next (  ) [pure virtual]

Play the next element in the playlist.

Returns:
WRET_ERR_ILLEGAL_USE when playlist is empty/invalid; WRET_ERR_PARAM when out of index; WRET_OK when playback is starting

Implemented in PlayerGStreamer, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::pause (  ) [pure virtual]

Pause the current media, keeping track of position. Continue calling play()

Returns:
See also:
play()

Implemented in PlayerGStreamer010, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::play ( const std::string &  file_url,
int  volume = -1,
bool  override_current = false 
) [pure virtual]

Play a resource.

Parameters:
file_url[in] the URI of the resource to be played. Multiple protocols are supported:

Implemented in PlayerGStreamer, PlayerGStreamer010, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::play (  ) [pure virtual]
virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::prev (  ) [pure virtual]

Play the previous element in the playlist.

Returns:
WRET_ERR_ILLEGAL_USE when playlist is empty/invalid; WRET_ERR_PARAM when out of index; WRET_OK when playback is starting

Implemented in PlayerGStreamer, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::setVolume ( int  newVolume ) [pure virtual]

Set the volume of device.

Parameters:
[in]newVolumethe volume level expressed in range [0; 100]
Returns:

Implemented in PlayerGStreamer010, wosh::bundles::PlayerGStreamerBundle, PlayerMPD2, wosh::bundles::PlayerMPDBundle, wosh::bundles::PlayerPhononBundle, and wosh::rmi::stubs::PlayerAudio.

virtual WRESULT wosh::interfaces::entertainment::PlayerAudio::stop (  ) [pure virtual]

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

Generated on Tue Feb 8 2011 09:33:39 for WOSH system 0.8.888 [wolf] by Alessandro Polo, using DoxyGen 1.7.2 hosted by WOSH Framework