TclVideoPlayer.hGo to the documentation of this file.00001 /* ****************************************************************** ** 00002 ** OpenSees - Open System for Earthquake Engineering Simulation ** 00003 ** Pacific Earthquake Engineering Research Center ** 00004 ** ** 00005 ** ** 00006 ** (C) Copyright 1999, The Regents of the University of California ** 00007 ** All Rights Reserved. ** 00008 ** ** 00009 ** Commercial use of this program without express permission of the ** 00010 ** University of California, Berkeley, is strictly prohibited. See ** 00011 ** file 'COPYRIGHT' in main directory for information on usage and ** 00012 ** redistribution, and for a DISCLAIMER OF ALL WARRANTIES. ** 00013 ** ** 00014 ** Developed by: ** 00015 ** Frank McKenna (fmckenna@ce.berkeley.edu) ** 00016 ** Gregory L. Fenves (fenves@ce.berkeley.edu) ** 00017 ** Filip C. Filippou (filippou@ce.berkeley.edu) ** 00018 ** ** 00019 ** ****************************************************************** */ 00020 00021 // $Revision: 1.4 $ 00022 // $Date: 2003/02/25 23:34:46 $ 00023 // $Source: /usr/local/cvs/OpenSees/SRC/tcl/TclVideoPlayer.h,v $ 00024 00025 00026 // File: ~/modelbuilder/tcl/TclVideoPlayer.h.h 00027 // 00028 // Written: fmk 00029 // Created: 11/99 00030 // Revision: A 00031 // 00032 // Description: This file contains the class definition for TclVideoPlayer. 00033 // A TclVideoPlayer can be used to playback movies. 00034 // 00035 // What: "@(#) ModelBuilder.h, revA" 00036 00037 #ifndef TclVideoPlayer_h 00038 #define TclVideoPlayer_h 00039 00040 #include <fstream> 00041 using std::ifstream; 00042 00043 class Renderer; 00044 class ColorMap; 00045 00046 extern "C" { 00047 #include <tcl.h> 00048 #include <tk.h> 00049 } 00050 00051 class TclVideoPlayer 00052 { 00053 public: 00054 TclVideoPlayer(const char *title, const char *fileName, const char *imageName, 00055 Tcl_Interp *interp, const char *offsetFileName = 0, double factor = 1.0); 00056 00057 ~TclVideoPlayer(); 00058 00059 int play(void); 00060 00061 protected: 00062 00063 private: 00064 ColorMap *theMap; 00065 Renderer *theRenderer; 00066 00067 char *theFileName; // file name conatining image commands 00068 ifstream theFile; // input stream for this file 00069 00070 char *theOffsetFileName; // file name containing nodal offsets 00071 ifstream theOffsetFile; // input stream for this file 00072 00073 double factor; 00074 }; 00075 00076 #endif 00077 00078 00079 00080 00081 00082 00083 |