00001 // Copyright (c) 2000-2001 Brad Hughes <bhughes@trolltech.com> 00002 // 00003 // Use, modification and distribution is allowed without limitation, 00004 // warranty, or liability of any kind. 00005 // 00006 00007 #ifndef __visual_h 00008 #define __visual_h 00009 00010 #include <qmutex.h> 00011 00012 class Decoder; 00013 class AudioOutput; 00014 namespace MythTV 00015 { 00016 class Visual 00017 { 00018 public: 00019 Visual() : dec(0), out(0) { ; } 00020 virtual ~Visual() { ; } 00021 00022 virtual void add(uchar *b, unsigned long b_len, unsigned long w, int c, int p) = 0; 00023 virtual void prepare() = 0; 00024 00025 Decoder *decoder() const { return dec; } 00026 void setDecoder(Decoder *d) { dec = d; } 00027 00028 AudioOutput *output() const { return out; } 00029 void setOutput(AudioOutput *o) { out = o; } 00030 00031 QMutex *mutex() { return &mtx; } 00032 00033 00034 private: 00035 Decoder *dec; 00036 AudioOutput *out; 00037 QMutex mtx; 00038 }; 00039 }; 00040 00041 #endif // __visual_h
1.5.5