]> git.saurik.com Git - wxWidgets.git/blame - utils/wxMMedia2/lib/vidbase.h
some changes to make wxHtmlHelpController easier to subclass
[wxWidgets.git] / utils / wxMMedia2 / lib / vidbase.h
CommitLineData
4d6306eb
GL
1// /////////////////////////////////////////////////////////////////////////////
2// Name: vidbase.h
3// Purpose: wxMMedia
4// Author: Guilhem Lavaux
5// Created: 1997
6// Updated: 1998
7// Copyright: (C) 1997, 1998, Guilhem Lavaux
8// CVS: $Id$
9// License: wxWindows license
10// /////////////////////////////////////////////////////////////////////////////
11/* Real -*- C++ -*- */
12#ifndef __VID_bdrv_H__
13#define __VID_bdrv_H__
14
15#ifdef __GNUG__
16#pragma interface
17#endif
18
4d6306eb
GL
19#include "wx/string.h"
20#include "wx/window.h"
7f42cff1 21#include "wx/frame.h"
4d6306eb
GL
22
23///
24typedef enum {
25 wxVIDEO_MSAVI,
26 wxVIDEO_MPEG,
27 wxVIDEO_QT,
28 wxVIDEO_GIF,
29 wxVIDEO_JMOV,
30 wxVIDEO_FLI,
31 wxVIDEO_IFF,
32 wxVIDEO_SGI,
33 wxVIDEO_MPEG2
34} ///
35 wxVideoType;
36
37///
38class wxVideoBaseDriver;
39class wxVideoOutput : public wxWindow {
40 ///
41 DECLARE_DYNAMIC_CLASS(wxVideoOutput)
42protected:
526ddb13 43 bool m_dyn_size;
4d6306eb
GL
44public:
45 ///
46 wxVideoOutput();
47 ///
48 wxVideoOutput(wxWindow *parent, const wxWindowID id,
49 const wxPoint& pos = wxDefaultPosition,
50 const wxSize& size = wxDefaultSize, const long style = 0,
51 const wxString& name = "video_output");
52 ///
53 virtual ~wxVideoOutput();
54
55 ///
526ddb13 56 bool DynamicSize() { return m_dyn_size; }
4d6306eb 57 ///
526ddb13 58 void DynamicSize(bool dyn) { m_dyn_size = dyn; }
4d6306eb
GL
59};
60
61///
526ddb13 62class wxVideoBaseDriver : public wxObject {
4d6306eb
GL
63 ///
64 DECLARE_ABSTRACT_CLASS(wxVideoBaseDriver)
65protected:
526ddb13 66 wxVideoOutput *m_video_output;
4d6306eb
GL
67public:
68 friend class wxVideoOutput;
69
b83290c3 70 //
4d6306eb 71 wxVideoBaseDriver();
b83290c3 72 //
526ddb13 73 wxVideoBaseDriver(wxInputStream& str);
b83290c3 74 //
4d6306eb
GL
75 virtual ~wxVideoBaseDriver();
76
b83290c3
GL
77
78 //
79 virtual bool Play() = 0;
80 //
81 virtual bool Stop() = 0;
82 //
4d6306eb 83 virtual bool Pause() = 0;
b83290c3 84 //
4d6306eb
GL
85 virtual bool Resume() = 0;
86
b83290c3 87 //
4d6306eb 88 virtual bool SetVolume(wxUint8 vol) = 0;
b83290c3 89 //
4d6306eb 90 virtual bool Resize(wxUint16 w, wxUint16 h) = 0;
b83290c3
GL
91 //
92 virtual bool GetSize(wxSize& size) const = 0;
4d6306eb 93
b83290c3 94 //
4d6306eb
GL
95 virtual bool IsCapable(wxVideoType WXUNUSED(v_type)) { return FALSE; }
96
b83290c3 97 //
4d6306eb
GL
98 virtual void OnFinished() {}
99
b83290c3 100 //
4d6306eb 101 virtual bool AttachOutput(wxVideoOutput& output);
b83290c3 102 //
4d6306eb
GL
103 virtual void DetachOutput();
104};
105
106extern wxFrame *wxVideoCreateFrame(wxVideoBaseDriver *vid_drv);
107
108
109#endif