summaryrefslogtreecommitdiffstats
path: root/media/player/movie.h
diff options
context:
space:
mode:
authorfbarchard@chromium.org <fbarchard@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-05 18:31:35 +0000
committerfbarchard@chromium.org <fbarchard@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-05 18:31:35 +0000
commit2f31e009401121b71f03cc233aa2e6b360697fdb (patch)
treece91dedea61036dcbd758089125f69eef95805b1 /media/player/movie.h
parent28c47ee963812e92e2eb921ed1778f5db74041bc (diff)
downloadchromium_src-2f31e009401121b71f03cc233aa2e6b360697fdb.zip
chromium_src-2f31e009401121b71f03cc233aa2e6b360697fdb.tar.gz
chromium_src-2f31e009401121b71f03cc233aa2e6b360697fdb.tar.bz2
Media Player mainfrm.h
This module contains all event handling for menus in the Media Player. The implementation is WTL (Windows Template Library) based. The main menu is: File Edit View Play Options Help File opens/closes movies and has print features. Edit has copy/paste features. View has spatial controls, such as scaling, and tool and status bars and a properties dialogue box. Play has temporal controls, such as play speed and pause. Options controls details such as Audio and Video on/off. Help is just an about box. Right clicking brings up a context menu with edit and view items. A tool bar exposes the most common menu items as buttons. Hotkeys (accelerators) are mapped to most menu items. A .RC file is used to edit the menus using the resource editor in visual studio. Dialogue boxes are each handled by a different .h. ie props.h for properties. Mainfrm.h does some minor dialogue boxes directly, such as the file selector and alert boxes for errors. Review URL: http://codereview.chromium.org/99087 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15311 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'media/player/movie.h')
-rw-r--r--media/player/movie.h52
1 files changed, 46 insertions, 6 deletions
diff --git a/media/player/movie.h b/media/player/movie.h
index f6d79be..d44126b 100644
--- a/media/player/movie.h
+++ b/media/player/movie.h
@@ -26,11 +26,14 @@ class Movie : public Singleton<Movie> {
// Set playback rate.
void Play(float rate);
- // Enable/Disable audio.
- void SetAudioEnable(bool enable_audio);
+ // Set playback rate.
+ float GetPlayRate();
- // Get Enable/Disable audio state.
- bool GetAudioEnable();
+ // Set playback pause.
+ void SetPause(bool pause);
+
+ // Get playback pause state.
+ bool GetPause();
// Set buffer to render into.
void SetFrameBuffer(HBITMAP hbmp, HWND hwnd);
@@ -41,6 +44,36 @@ class Movie : public Singleton<Movie> {
// Query if movie is currently open.
bool IsOpen();
+ // Enable/Disable audio.
+ void SetAudioEnable(bool enable_audio);
+
+ // Get Enable/Disable audio state.
+ bool GetAudioEnable();
+
+ // Enable/Disable draw.
+ void SetDrawEnable(bool enable_draw);
+
+ // Get Enable/Disable draw state.
+ bool GetDrawEnable();
+
+ // Enable/Disable swscaler.
+ void SetSwscalerEnable(bool enable_swscaler);
+
+ // Get Enable/Disable swscaler state.
+ bool GetSwscalerEnable();
+
+ // Enable/Disable dump yuv file.
+ void SetDumpYuvFileEnable(bool enable_dump_yuv_file);
+
+ // Get Enable/Disable dump yuv file state.
+ bool GetDumpYuvFileEnable();
+
+ // Enable/Disable OpenMP.
+ void SetOpenMpEnable(bool enable_openmp);
+
+ // Get Enable/Disable OpenMP state.
+ bool GetOpenMpEnable();
+
private:
// Only allow Singleton to create and delete Movie.
friend struct DefaultSingletonTraits<Movie>;
@@ -48,10 +81,17 @@ class Movie : public Singleton<Movie> {
virtual ~Movie();
scoped_ptr<PipelineImpl> pipeline_;
- HBITMAP movie_dib_;
- HWND movie_hwnd_;
+
bool enable_audio_;
+ bool enable_swscaler_;
+ bool enable_draw_;
+ bool enable_dump_yuv_file_;
+ bool enable_pause_;
+ bool enable_openmp_;
+ int max_threads_;
float play_rate_;
+ HBITMAP movie_dib_;
+ HWND movie_hwnd_;
DISALLOW_COPY_AND_ASSIGN(Movie);
};