Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

planybmp.h

Go to the documentation of this file.
00001 /*
00002 /--------------------------------------------------------------------
00003 |
00004 |      $Id: planybmp.h,v 1.1 2004/05/21 21:02:52 maxx Exp $
00005 |
00006 |      Copyright (c) 1996-2002 Ulrich von Zadow
00007 |
00008 \--------------------------------------------------------------------
00009 */
00010 
00011 #ifndef INCL_PLANYBMP
00012 #define INCL_PLANYBMP
00013 
00014 #ifndef INCL_PLBITMAP
00015 #include "plbitmap.h"
00016 #endif
00017 
00022 class PLAnyBmp : public PLBmp
00023 {
00024 
00025 public:
00027   PLAnyBmp
00028     ();
00029 
00031   virtual ~PLAnyBmp
00032     ();
00033 
00035   PLAnyBmp
00036     ( const PLBmp &Orig
00037     );
00038 
00040   PLAnyBmp
00041     ( const PLAnyBmp &Orig
00042     );
00043 
00045   PLAnyBmp &operator=
00046     ( const PLBmp &Orig
00047     );
00048 
00050   PLAnyBmp &operator=
00051     ( const PLAnyBmp &Orig
00052     );
00053 
00054   // PLAnyBmp information
00055 
00057   long GetMemUsed
00058     ();
00059 
00061   long GetBytesPerLine
00062     ();
00063 
00064 
00065   // Static functions
00066 
00068   static long GetMemNeeded
00069     ( PLLONG width,
00070       PLLONG height,
00071       PLWORD BitsPerPixel
00072     );
00073 
00075   static long GetBitsMemNeeded
00076     ( PLLONG width,
00077       PLLONG height,
00078       PLWORD BitsPerPixel
00079     );
00080 
00081 
00082 protected:
00083   // Local functions
00084 
00085   // Create a new bitmap with uninitialized bits. Assumes no memory
00086   // is allocated yet.
00087   virtual void internalCreate
00088     ( PLLONG Width,
00089       PLLONG Height,
00090       PLWORD BitsPerPixel,
00091       bool bAlphaChannel
00092     );
00093 
00094   // Deletes memory allocated by member variables.
00095   virtual void freeMembers
00096     ();
00097 
00098   // Initializes internal table of line addresses.
00099   virtual void initLineArray
00100     ();
00101 
00102   PLBYTE      * m_pBits;        // Pointer to the bits.
00103 };
00104 
00105 // Note that _both_ these copy constructors are needed. If only the 
00106 // second one is there, MSVC generates a default copy 
00107 // constructor anyway :-(.
00108 inline PLAnyBmp::PLAnyBmp
00109     ( const PLAnyBmp &Orig
00110     )
00111     : PLBmp ()
00112 {
00113   internalCopy (Orig);
00114 }
00115 
00116 inline PLAnyBmp::PLAnyBmp
00117     ( const PLBmp &Orig
00118     )
00119     : PLBmp ()
00120 {
00121   internalCopy (Orig);
00122 }
00123 
00124 inline PLAnyBmp & PLAnyBmp::operator=
00125     ( const PLBmp &Orig
00126     )
00127 {
00128   PLBmp::operator=(Orig);
00129   return *this;
00130 }
00131 
00132 inline PLAnyBmp & PLAnyBmp::operator=
00133     ( const PLAnyBmp &Orig
00134     )
00135 {
00136   PLBmp::operator=(Orig);
00137   return *this;
00138 }
00139 
00140 
00141 #endif
00142 /*
00143 /--------------------------------------------------------------------
00144 |
00145 |      $Log: planybmp.h,v $
00146 |      Revision 1.1  2004/05/21 21:02:52  maxx
00147 |      Initial Version of vuVolume, moderatly changed to make it compile on my windows and linux machine.
00148 |
00149 |      Revision 1.1  2002/11/13 01:58:20  mspindle
00150 |      *** empty log message ***
00151 |
00152 |      Revision 1.3  2002/02/24 13:00:17  uzadow
00153 |      Documentation update; removed buggy PLFilterRotate.
00154 |
00155 |      Revision 1.2  2001/10/06 22:03:26  uzadow
00156 |      Added PL prefix to basic data types.
00157 |
00158 |      Revision 1.1  2001/09/16 19:03:22  uzadow
00159 |      Added global name prefix PL, changed most filenames.
00160 |
00161 |      Revision 1.10  2001/01/15 15:05:31  uzadow
00162 |      Added PLBmp::ApplyFilter() and PLBmp::CreateFilteredCopy()
00163 |
00164 |      Revision 1.9  2000/11/02 21:28:47  uzadow
00165 |      Fixed copy constructors.
00166 |
00167 |      Revision 1.8  2000/08/13 12:11:43  Administrator
00168 |      Added experimental DirectDraw-Support
00169 |
00170 |      Revision 1.7  2000/01/16 20:43:12  anonymous
00171 |      Removed MFC dependencies
00172 |
00173 |      Revision 1.6  1999/12/14 12:30:13  Ulrich von Zadow
00174 |      Corrected copy constructor and assignment operator.
00175 |
00176 |      Revision 1.5  1999/12/10 01:27:26  Ulrich von Zadow
00177 |      Added assignment operator and copy constructor to
00178 |      bitmap classes.
00179 |
00180 |      Revision 1.4  1999/12/02 17:07:34  Ulrich von Zadow
00181 |      Changes by bdelmee.
00182 |
00183 \--------------------------------------------------------------------
00184 */

Generated on Wed Dec 15 21:20:30 2004 for vuVolume by  doxygen 1.3.9.1