Panda3D
|
00001 // Filename: movieVideo.h 00002 // Created by: jyelon (02Jul07) 00003 // 00004 //////////////////////////////////////////////////////////////////// 00005 // 00006 // PANDA 3D SOFTWARE 00007 // Copyright (c) Carnegie Mellon University. All rights reserved. 00008 // 00009 // All use of this software is subject to the terms of the revised BSD 00010 // license. You should have received a copy of this license along 00011 // with this source code in a file named "LICENSE." 00012 // 00013 //////////////////////////////////////////////////////////////////// 00014 00015 #ifndef MOVIEVIDEO_H 00016 #define MOVIEVIDEO_H 00017 00018 #include "pandabase.h" 00019 #include "namable.h" 00020 #include "pointerTo.h" 00021 #include "typedWritableReferenceCount.h" 00022 class MovieVideoCursor; 00023 00024 //////////////////////////////////////////////////////////////////// 00025 // Class : MovieVideo 00026 // Description : A MovieVideo is actually any source that provides 00027 // a sequence of video frames. That could include an 00028 // AVI file, a digital camera, or an internet TV station. 00029 // 00030 // The difference between a MovieVideo and a 00031 // MovieVideoCursor is like the difference between a 00032 // filename and a file handle. The MovieVideo just 00033 // indicates a particular movie. The MovieVideoCursor 00034 // is what allows access. 00035 //////////////////////////////////////////////////////////////////// 00036 class EXPCL_PANDA_MOVIES MovieVideo : public TypedWritableReferenceCount, public Namable { 00037 00038 PUBLISHED: 00039 MovieVideo(const string &name = "Blank Video"); 00040 virtual ~MovieVideo(); 00041 virtual PT(MovieVideoCursor) open(); 00042 static PT(MovieVideo) get(const Filename &name); 00043 INLINE const Filename &get_filename() const; 00044 00045 protected: 00046 Filename _filename; 00047 00048 public: 00049 static TypeHandle get_class_type() { 00050 return _type_handle; 00051 } 00052 static void init_type() { 00053 TypedWritableReferenceCount::init_type(); 00054 register_type(_type_handle, "MovieVideo", 00055 TypedWritableReferenceCount::get_class_type()); 00056 } 00057 virtual TypeHandle get_type() const { 00058 return get_class_type(); 00059 } 00060 virtual TypeHandle force_init_type() {init_type(); return get_class_type();} 00061 00062 private: 00063 static TypeHandle _type_handle; 00064 }; 00065 00066 /* okcircular */ 00067 #include "movieVideoCursor.h" 00068 00069 #include "movieVideo.I" 00070 00071 #endif