diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-07-23 18:19:00 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-07-23 18:19:00 -0600 |
commit | 90fb19dcd1f6df2dd54b6502d0a9dd75abaa5ea2 (patch) | |
tree | f5fdde6de55f4783c16557fb468c09987d633e3a /NxWidgets/nxwm/include | |
parent | a2f3576b95cf969a21a0a80ccfb08c024d699aa1 (diff) | |
download | nuttx-90fb19dcd1f6df2dd54b6502d0a9dd75abaa5ea2.tar.gz nuttx-90fb19dcd1f6df2dd54b6502d0a9dd75abaa5ea2.tar.bz2 nuttx-90fb19dcd1f6df2dd54b6502d0a9dd75abaa5ea2.zip |
NxWM: Beginning integration of NxPlayer into Nxwm::MediaPlayer. Gets handle, sets device, and releases handle. Lots more to be done
Diffstat (limited to 'NxWidgets/nxwm/include')
-rw-r--r-- | NxWidgets/nxwm/include/cmediaplayer.hxx | 17 | ||||
-rw-r--r-- | NxWidgets/nxwm/include/nxwmconfig.hxx | 4 |
2 files changed, 20 insertions, 1 deletions
diff --git a/NxWidgets/nxwm/include/cmediaplayer.hxx b/NxWidgets/nxwm/include/cmediaplayer.hxx index 0584429a4..b2f5072f6 100644 --- a/NxWidgets/nxwm/include/cmediaplayer.hxx +++ b/NxWidgets/nxwm/include/cmediaplayer.hxx @@ -115,6 +115,7 @@ namespace NxWM * Media player state data. */ + FAR struct nxplayer_s *m_player; /**< NxPlayer handle */ enum EMediaPlayerState m_state; /**< Media player current state */ enum EMediaPlayerState m_prevState; /**< Media player previous state */ enum EPendingRelease m_pending; /**< Pending image release event */ @@ -184,7 +185,21 @@ namespace NxWM * Load media files into the list box. */ - inline bool showMediaFiles(const char *mediaPath); + inline bool showMediaFiles(FAR const char *mediaPath); + +#ifdef CONFIG_NXPLAYER_INCLUDE_PREFERRED_DEVICE + /** + * Set the preferred audio device for playback + */ + + inline bool setDevice(FAR const char *devPath); +#endif + + /** + * Configure the NxPlayer. + */ + + inline bool configureNxPlayer(void); /** * Create the Media Player controls. Only start as part of the application diff --git a/NxWidgets/nxwm/include/nxwmconfig.hxx b/NxWidgets/nxwm/include/nxwmconfig.hxx index 75f860c9d..b2c3f4c54 100644 --- a/NxWidgets/nxwm/include/nxwmconfig.hxx +++ b/NxWidgets/nxwm/include/nxwmconfig.hxx @@ -632,6 +632,10 @@ * Default: CONFIG_NXWM_DEFAULT_FONTID */ +#ifndef CONFIG_NXWM_MEDIAPLAYER_PREFERRED_DEVICE +# define CONFIG_NXWM_MEDIAPLAYER_PREFERRED_DEVICE "pcm0" +#endif + #ifndef CONFIG_NXWM_MEDIAPLAYER_MEDIAPATH # define CONFIG_NXWM_MEDIAPLAYER_MEDIAPATH "/mnt/sdcard" #endif |