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

osg::ImageBase Class Reference

Image Base Class.

#include <OSGImageBase.h>

Inheritance diagram for osg::ImageBase:

osg::AttachmentContainer osg::FieldContainer osg::Image List of all members.

Public Types

typedef ImagePtr Ptr
enum  {
  ParentsFieldId = Inherited::NextFieldId, DimensionFieldId = ParentsFieldId + 1, WidthFieldId = DimensionFieldId + 1, HeightFieldId = WidthFieldId + 1,
  DepthFieldId = HeightFieldId + 1, BppFieldId = DepthFieldId + 1, MipMapCountFieldId = BppFieldId + 1, FrameCountFieldId = MipMapCountFieldId + 1,
  FrameDelayFieldId = FrameCountFieldId + 1, PixelFormatFieldId = FrameDelayFieldId + 1, PixelFieldId = PixelFormatFieldId + 1, FrameSizeFieldId = PixelFieldId + 1,
  NameFieldId = FrameSizeFieldId + 1, DataTypeFieldId = NameFieldId + 1, ComponentSizeFieldId = DataTypeFieldId + 1, SideCountFieldId = ComponentSizeFieldId + 1,
  SideSizeFieldId = SideCountFieldId + 1, ForceCompressedDataFieldId = SideSizeFieldId + 1, ForceAlphaChannelFieldId = ForceCompressedDataFieldId + 1, ForceColorChannelFieldId = ForceAlphaChannelFieldId + 1,
  NextFieldId = ForceColorChannelFieldId + 1
}

Public Member Functions

FieldContainer Get
*virtual FieldContainerTypegetType (void)
virtual const FieldContainerTypegetType (void) const
virtual UInt32 getContainerSize (void) const
Field Get
*MFFieldContainerPtrgetMFParents (void)
 Get the Image::_mfParents field.
SFInt32getSFDimension (void)
 Get the Image::_sfDimension field.
SFInt32getSFWidth (void)
 Get the Image::_sfWidth field.
SFInt32getSFHeight (void)
 Get the Image::_sfHeight field.
SFInt32getSFDepth (void)
 Get the Image::_sfDepth field.
SFInt32getSFBpp (void)
 Get the Image::_sfBpp field.
SFInt32getSFMipMapCount (void)
 Get the Image::_sfMipMapCount field.
SFInt32getSFFrameCount (void)
 Get the Image::_sfFrameCount field.
SFTimegetSFFrameDelay (void)
 Get the Image::_sfFrameDelay field.
SFUInt32getSFPixelFormat (void)
 Get the Image::_sfPixelFormat field.
MFUInt8getMFPixel (void)
 Get the Image::_mfPixel field.
SFInt32getSFFrameSize (void)
 Get the Image::_sfFrameSize field.
SFStringgetSFName (void)
 Get the Image::_sfName field.
SFInt32getSFDataType (void)
 Get the Image::_sfDataType field.
SFInt32getSFSideCount (void)
 Get the Image::_sfSideCount field.
SFInt32getSFSideSize (void)
 Get the Image::_sfSideSize field.
SFBoolgetSFForceCompressedData (void)
 Get the Image::_sfForceCompressedData field.
SFBoolgetSFForceAlphaChannel (void)
 Get the Image::_sfForceAlphaChannel field.
SFBoolgetSFForceColorChannel (void)
 Get the Image::_sfForceColorChannel field.
Int32getDimension (void)
 Get the value of the Image::_sfDimension field.
const Int32getDimension (void) const
 Get the value of the Image::_sfDimension field.
Int32getWidth (void)
 Get the value of the Image::_sfWidth field.
const Int32getWidth (void) const
 Get the value of the Image::_sfWidth field.
Int32getHeight (void)
 Get the value of the Image::_sfHeight field.
const Int32getHeight (void) const
 Get the value of the Image::_sfHeight field.
Int32getDepth (void)
 Get the value of the Image::_sfDepth field.
const Int32getDepth (void) const
 Get the value of the Image::_sfDepth field.
Int32getBpp (void)
 Get the value of the Image::_sfBpp field.
const Int32getBpp (void) const
 Get the value of the Image::_sfBpp field.
Int32getMipMapCount (void)
 Get the value of the Image::_sfMipMapCount field.
const Int32getMipMapCount (void) const
 Get the value of the Image::_sfMipMapCount field.
Int32getFrameCount (void)
 Get the value of the Image::_sfFrameCount field.
const Int32getFrameCount (void) const
 Get the value of the Image::_sfFrameCount field.
TimegetFrameDelay (void)
 Get the value of the Image::_sfFrameDelay field.
const TimegetFrameDelay (void) const
 Get the value of the Image::_sfFrameDelay field.
UInt32getPixelFormat (void)
 Get the value of the Image::_sfPixelFormat field.
const UInt32getPixelFormat (void) const
 Get the value of the Image::_sfPixelFormat field.
Int32getFrameSize (void)
 Get the value of the Image::_sfFrameSize field.
const Int32getFrameSize (void) const
 Get the value of the Image::_sfFrameSize field.
std::string & getName (void)
 Get the value of the Image::_sfName field.
const std::string & getName (void) const
 Get the value of the Image::_sfName field.
Int32getDataType (void)
 Get the value of the Image::_sfDataType field.
const Int32getDataType (void) const
 Get the value of the Image::_sfDataType field.
Int32getSideCount (void)
 Get the value of the Image::_sfSideCount field.
const Int32getSideCount (void) const
 Get the value of the Image::_sfSideCount field.
Int32getSideSize (void)
 Get the value of the Image::_sfSideSize field.
const Int32getSideSize (void) const
 Get the value of the Image::_sfSideSize field.
bool & getForceCompressedData (void)
 Get the value of the Image::_sfForceCompressedData field.
const bool & getForceCompressedData (void) const
 Get the value of the Image::_sfForceCompressedData field.
bool & getForceAlphaChannel (void)
 Get the value of the Image::_sfForceAlphaChannel field.
const bool & getForceAlphaChannel (void) const
 Get the value of the Image::_sfForceAlphaChannel field.
bool & getForceColorChannel (void)
 Get the value of the Image::_sfForceColorChannel field.
const bool & getForceColorChannel (void) const
 Get the value of the Image::_sfForceColorChannel field.
FieldContainerPtrgetParents (const UInt32 index)
 Get the value of the index element the Image::_mfParents field.
MFFieldContainerPtrgetParents (void)
 Get the Image::_mfParents field.
const MFFieldContainerPtrgetParents (void) const
 Get the Image::_mfParents field.
UInt8getPixel (const UInt32 index)
 Get the value of the index element the Image::_mfPixel field.
MFUInt8getPixel (void)
 Get the Image::_mfPixel field.
const MFUInt8getPixel (void) const
 Get the Image::_mfPixel field.
Field Set
*void setDimension (const Int32 &value)
 Set the value of the Image::_sfDimension field.
void setWidth (const Int32 &value)
 Set the value of the Image::_sfWidth field.
void setHeight (const Int32 &value)
 Set the value of the Image::_sfHeight field.
void setDepth (const Int32 &value)
 Set the value of the Image::_sfDepth field.
void setBpp (const Int32 &value)
 Set the value of the Image::_sfBpp field.
void setMipMapCount (const Int32 &value)
 Set the value of the Image::_sfMipMapCount field.
void setFrameCount (const Int32 &value)
 Set the value of the Image::_sfFrameCount field.
void setFrameDelay (const Time &value)
 Set the value of the Image::_sfFrameDelay field.
void setPixelFormat (const UInt32 &value)
 Set the value of the Image::_sfPixelFormat field.
void setFrameSize (const Int32 &value)
 Set the value of the Image::_sfFrameSize field.
void setName (const std::string &value)
 Set the value of the Image::_sfName field.
void setDataType (const Int32 &value)
 Set the value of the Image::_sfDataType field.
void setSideCount (const Int32 &value)
 Set the value of the Image::_sfSideCount field.
void setSideSize (const Int32 &value)
 Set the value of the Image::_sfSideSize field.
void setForceCompressedData (const bool &value)
 Set the value of the Image::_sfForceCompressedData field.
void setForceAlphaChannel (const bool &value)
 Set the value of the Image::_sfForceAlphaChannel field.
void setForceColorChannel (const bool &value)
 Set the value of the Image::_sfForceColorChannel field.
Binary Access
*virtual UInt32 getBinSize (const BitVector &whichField)
virtual void copyToBin (BinaryDataHandler &pMem, const BitVector &whichField)
virtual void copyFromBin (BinaryDataHandler &pMem, const BitVector &whichField)
Copy
*virtual FieldContainerPtr shallowCopy (void) const
Handle Attachments
*void addAttachment (const AttachmentPtr &fieldContainerP, UInt16 binding=0)
void subAttachment (const AttachmentPtr &fieldContainerP, UInt16 binding=0)
AttachmentPtr findAttachment (UInt32 groupId, UInt16 binding=0)
AttachmentPtr findAttachment (const FieldContainerType &type, UInt16 binding=0)
Field Access *SFAttachmentMapgetSFAttachments (void)
Changed
*virtual void changed (BitVector whichField, UInt32 origin)
Dump
*virtual void dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const
Get Instance Type Information
UInt32 getTypeId (void) const
UInt16 getGroupId (void) const
const Char8getTypeName (void) const
Generic Field Access *FieldgetField (UInt32 fieldId)
FieldgetField (const Char8 *fieldName)

Static Public Member Functions

Class Get
*static FieldContainerTypegetClassType (void)
 access the type of the class
static UInt32 getClassTypeId (void)
 access the numerical type of the class
Construction
*static ImagePtr create (void)
 create a new instance of the class
static ImagePtr createEmpty (void)
 create an empty new instance of the class, do not copy the prototype
Get Class Type Information
static UInt16 getClassGroupId (void)

Static Public Attributes

static const osg::BitVector ParentsFieldMask
static const osg::BitVector DimensionFieldMask
static const osg::BitVector WidthFieldMask
static const osg::BitVector HeightFieldMask
static const osg::BitVector DepthFieldMask
static const osg::BitVector BppFieldMask
static const osg::BitVector MipMapCountFieldMask
static const osg::BitVector FrameCountFieldMask
static const osg::BitVector FrameDelayFieldMask
static const osg::BitVector PixelFormatFieldMask
static const osg::BitVector PixelFieldMask
static const osg::BitVector FrameSizeFieldMask
static const osg::BitVector NameFieldMask
static const osg::BitVector DataTypeFieldMask
static const osg::BitVector ComponentSizeFieldMask
static const osg::BitVector SideCountFieldMask
static const osg::BitVector SideSizeFieldMask
static const osg::BitVector ForceCompressedDataFieldMask
static const osg::BitVector ForceAlphaChannelFieldMask
static const osg::BitVector ForceColorChannelFieldMask
static const osg::BitVector MTInfluenceMask
static const BitVector AttachmentsFieldMask
static const BitVector NextFieldMask
CoredNodePtr helper
static const bool isNodeCore = false

Protected Member Functions

Constructors
ImageBase (void)
 ImageBase (const ImageBase &source)
Destructors
*virtual ~ImageBase (void)
Field Get
*SFInt32getSFComponentSize (void)
 Get the Image::_sfComponentSize field.
Int32getComponentSize (void)
 Get the value of the Image::_sfComponentSize field.
const Int32getComponentSize (void) const
 Get the value of the Image::_sfComponentSize field.
Field Set
*void setComponentSize (const Int32 &value)
 Set the value of the Image::_sfComponentSize field.
Sync
*void executeSyncImpl (ImageBase *pOther, const BitVector &whichField)
virtual void executeSync (FieldContainer &other, const BitVector &whichField)
Sync
void executeSyncImpl (AttachmentContainer *pOther, const BitVector &whichField)
Sync
void executeSyncImpl (FieldContainer *pOther, const BitVector &whichField)
Pointer
*AttachmentContainerPtr getPtr (void)
MT Edit
template<class FieldTypeT>
*void beginEditX (const BitVector &whichField, FieldTypeT &field)
template<class FieldTypeT>
void endEditX (const BitVector &whichField, FieldTypeT &field)
MT Construction
*void onCreate (const FieldContainer *source=NULL)
void onCreateAspect (const FieldContainer *aspect0, const FieldContainer *source=NULL)
MT Destruction
*virtual void onDestroy (void)

Static Protected Member Functions

Create Fieldcontainer
template<class ObjectPtrT>
*static void newPtr (ObjectPtrT &result, const typename ObjectPtrT::StoredObjectType *prototypeP)
template<class ObjectPtrT>
static void newPtr (ObjectPtrT &result)

Protected Attributes

Fields
*MFFieldContainerPtr _mfParents
SFInt32 _sfDimension
SFInt32 _sfWidth
SFInt32 _sfHeight
SFInt32 _sfDepth
SFInt32 _sfBpp
SFInt32 _sfMipMapCount
SFInt32 _sfFrameCount
SFTime _sfFrameDelay
SFUInt32 _sfPixelFormat
MFUInt8 _mfPixel
SFInt32 _sfFrameSize
SFString _sfName
SFInt32 _sfDataType
SFInt32 _sfComponentSize
SFInt32 _sfSideCount
SFInt32 _sfSideSize
SFBool _sfForceCompressedData
SFBool _sfForceAlphaChannel
SFBool _sfForceColorChannel
Fields
*SFAttachmentMap _attachmentMap
Member
*UInt32 _shares

Private Types

typedef AttachmentContainer Inherited

Private Member Functions

void operator= (const ImageBase &source)

Static Private Attributes

static FieldDescription_desc []
 Image description.
static FieldContainerType _type

Friends

class FieldContainer

Detailed Description

Definition at line 100 of file OSGImageBase.h.


Member Typedef Documentation

typedef AttachmentContainer osg::ImageBase::Inherited [private]
 

Reimplemented from osg::AttachmentContainer.

Reimplemented in osg::Image.

Definition at line 104 of file OSGImageBase.h.

typedef ImagePtr osg::ImageBase::Ptr
 

Definition at line 109 of file OSGImageBase.h.


Member Enumeration Documentation

anonymous enum
 

Enumerator:
ParentsFieldId 
DimensionFieldId 
WidthFieldId 
HeightFieldId 
DepthFieldId 
BppFieldId 
MipMapCountFieldId 
FrameCountFieldId 
FrameDelayFieldId 
PixelFormatFieldId 
PixelFieldId 
FrameSizeFieldId 
NameFieldId 
DataTypeFieldId 
ComponentSizeFieldId 
SideCountFieldId 
SideSizeFieldId 
ForceCompressedDataFieldId 
ForceAlphaChannelFieldId 
ForceColorChannelFieldId 
NextFieldId 

Reimplemented from osg::AttachmentContainer.

Definition at line 111 of file OSGImageBase.h.

00112     {
00113         ParentsFieldId             = Inherited::NextFieldId,
00114         DimensionFieldId           = ParentsFieldId             + 1,
00115         WidthFieldId               = DimensionFieldId           + 1,
00116         HeightFieldId              = WidthFieldId               + 1,
00117         DepthFieldId               = HeightFieldId              + 1,
00118         BppFieldId                 = DepthFieldId               + 1,
00119         MipMapCountFieldId         = BppFieldId                 + 1,
00120         FrameCountFieldId          = MipMapCountFieldId         + 1,
00121         FrameDelayFieldId          = FrameCountFieldId          + 1,
00122         PixelFormatFieldId         = FrameDelayFieldId          + 1,
00123         PixelFieldId               = PixelFormatFieldId         + 1,
00124         FrameSizeFieldId           = PixelFieldId               + 1,
00125         NameFieldId                = FrameSizeFieldId           + 1,
00126         DataTypeFieldId            = NameFieldId                + 1,
00127         ComponentSizeFieldId       = DataTypeFieldId            + 1,
00128         SideCountFieldId           = ComponentSizeFieldId       + 1,
00129         SideSizeFieldId            = SideCountFieldId           + 1,
00130         ForceCompressedDataFieldId = SideSizeFieldId            + 1,
00131         ForceAlphaChannelFieldId   = ForceCompressedDataFieldId + 1,
00132         ForceColorChannelFieldId   = ForceAlphaChannelFieldId   + 1,
00133         NextFieldId                = ForceColorChannelFieldId   + 1
00134     };


Constructor & Destructor Documentation

ImageBase::ImageBase void   )  [protected]
 

Definition at line 376 of file OSGImageBase.cpp.

00376                          :
00377     _mfParents                (), 
00378     _sfDimension              (Int32(0)), 
00379     _sfWidth                  (Int32(0)), 
00380     _sfHeight                 (Int32(1)), 
00381     _sfDepth                  (Int32(1)), 
00382     _sfBpp                    (Int32(1)), 
00383     _sfMipMapCount            (Int32(1)), 
00384     _sfFrameCount             (Int32(1)), 
00385     _sfFrameDelay             (Time(0)), 
00386     _sfPixelFormat            (UInt32(0)), 
00387     _mfPixel                  (), 
00388     _sfFrameSize              (Int32(0)), 
00389     _sfName                   (), 
00390     _sfDataType               (Int32(GL_UNSIGNED_BYTE)), 
00391     _sfComponentSize          (Int32(1)), 
00392     _sfSideCount              (Int32(1)), 
00393     _sfSideSize               (Int32(0)), 
00394     _sfForceCompressedData    (bool(false)), 
00395     _sfForceAlphaChannel      (bool(false)), 
00396     _sfForceColorChannel      (bool(false)), 
00397     Inherited() 
00398 {
00399 }

ImageBase::ImageBase const ImageBase source  )  [protected]
 

Definition at line 405 of file OSGImageBase.cpp.

00405                                             :
00406     _mfParents                (source._mfParents                ), 
00407     _sfDimension              (source._sfDimension              ), 
00408     _sfWidth                  (source._sfWidth                  ), 
00409     _sfHeight                 (source._sfHeight                 ), 
00410     _sfDepth                  (source._sfDepth                  ), 
00411     _sfBpp                    (source._sfBpp                    ), 
00412     _sfMipMapCount            (source._sfMipMapCount            ), 
00413     _sfFrameCount             (source._sfFrameCount             ), 
00414     _sfFrameDelay             (source._sfFrameDelay             ), 
00415     _sfPixelFormat            (source._sfPixelFormat            ), 
00416     _mfPixel                  (source._mfPixel                  ), 
00417     _sfFrameSize              (source._sfFrameSize              ), 
00418     _sfName                   (source._sfName                   ), 
00419     _sfDataType               (source._sfDataType               ), 
00420     _sfComponentSize          (source._sfComponentSize          ), 
00421     _sfSideCount              (source._sfSideCount              ), 
00422     _sfSideSize               (source._sfSideSize               ), 
00423     _sfForceCompressedData    (source._sfForceCompressedData    ), 
00424     _sfForceAlphaChannel      (source._sfForceAlphaChannel      ), 
00425     _sfForceColorChannel      (source._sfForceColorChannel      ), 
00426     Inherited                 (source)
00427 {
00428 }

ImageBase::~ImageBase void   )  [protected, virtual]
 

Definition at line 432 of file OSGImageBase.cpp.

00433 {
00434 }


Member Function Documentation

osg::FieldContainerType & osg::ImageBase::getClassType void   )  [inline, static]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 58 of file OSGImageBase.inl.

References _type.

Referenced by create().

00059 {
00060     return _type; 
00061 } 

osg::UInt32 osg::ImageBase::getClassTypeId void   )  [inline, static]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 65 of file OSGImageBase.inl.

References _type, and osg::TypeBase::getId().

00066 {
00067     return _type.getId(); 
00068 } 

FieldContainerType & ImageBase::getType void   )  [virtual]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 316 of file OSGImageBase.cpp.

References _type.

00317 {
00318     return _type; 
00319 } 

const FieldContainerType & ImageBase::getType void   )  const [virtual]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 321 of file OSGImageBase.cpp.

References _type.

00322 {
00323     return _type;
00324 } 

UInt32 ImageBase::getContainerSize void   )  const [virtual]
 

Reimplemented from osg::AttachmentContainer.

Definition at line 336 of file OSGImageBase.cpp.

00337 { 
00338     return sizeof(Image); 
00339 }

MFFieldContainerPtr * osg::ImageBase::getMFParents void   )  [inline]
 

Definition at line 101 of file OSGImageBase.inl.

References _mfParents.

00102 {
00103     return &_mfParents;
00104 }

SFInt32 * osg::ImageBase::getSFDimension void   )  [inline]
 

Definition at line 108 of file OSGImageBase.inl.

References _sfDimension.

00109 {
00110     return &_sfDimension;
00111 }

SFInt32 * osg::ImageBase::getSFWidth void   )  [inline]
 

Definition at line 115 of file OSGImageBase.inl.

References _sfWidth.

00116 {
00117     return &_sfWidth;
00118 }

SFInt32 * osg::ImageBase::getSFHeight void   )  [inline]
 

Definition at line 122 of file OSGImageBase.inl.

References _sfHeight.

00123 {
00124     return &_sfHeight;
00125 }

SFInt32 * osg::ImageBase::getSFDepth void   )  [inline]
 

Definition at line 129 of file OSGImageBase.inl.

References _sfDepth.

00130 {
00131     return &_sfDepth;
00132 }

SFInt32 * osg::ImageBase::getSFBpp void   )  [inline]
 

Definition at line 136 of file OSGImageBase.inl.

References _sfBpp.

00137 {
00138     return &_sfBpp;
00139 }

SFInt32 * osg::ImageBase::getSFMipMapCount void   )  [inline]
 

Definition at line 143 of file OSGImageBase.inl.

References _sfMipMapCount.

00144 {
00145     return &_sfMipMapCount;
00146 }

SFInt32 * osg::ImageBase::getSFFrameCount void   )  [inline]
 

Definition at line 150 of file OSGImageBase.inl.

References _sfFrameCount.

00151 {
00152     return &_sfFrameCount;
00153 }

SFTime * osg::ImageBase::getSFFrameDelay void   )  [inline]
 

Definition at line 157 of file OSGImageBase.inl.

References _sfFrameDelay.

00158 {
00159     return &_sfFrameDelay;
00160 }

SFUInt32 * osg::ImageBase::getSFPixelFormat void   )  [inline]
 

Definition at line 164 of file OSGImageBase.inl.

References _sfPixelFormat.

00165 {
00166     return &_sfPixelFormat;
00167 }

MFUInt8 * osg::ImageBase::getMFPixel void   )  [inline]