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

osg::Image Class Reference

Image class. See Image for a description. More...

#include <OSGImage.h>

Inheritance diagram for osg::Image:

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

Public Types

enum  PixelFormat {
  OSG_INVALID_PF = 0, OSG_I_PF = GL_INTENSITY, OSG_L_PF = GL_LUMINANCE, OSG_LA_PF = GL_LUMINANCE_ALPHA,
  OSG_BGR_PF = 0, OSG_BGRA_PF = 0, OSG_RGB_DXT1 = GL_COMPRESSED_RGB_S3TC_DXT1_EXT, OSG_RGBA_DXT1 = GL_COMPRESSED_RGBA_S3TC_DXT1_EXT,
  OSG_RGBA_DXT3 = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT, OSG_RGBA_DXT5 = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT, OSG_RGB_PF = GL_RGB, OSG_RGBA_PF = GL_RGBA
}
enum  Type {
  OSG_INVALID_IMAGEDATATYPE = GL_NONE, OSG_UINT8_IMAGEDATA = GL_UNSIGNED_BYTE, OSG_UINT16_IMAGEDATA = GL_UNSIGNED_SHORT, OSG_UINT32_IMAGEDATA = GL_UNSIGNED_INT,
  OSG_FLOAT16_IMAGEDATA = GL_HALF_FLOAT_NV, OSG_FLOAT32_IMAGEDATA = GL_FLOAT
}
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

Sync
*virtual void changed (BitVector whichField, UInt32 origin)
Output
*virtual void dump (UInt32 uiIndent=0, const BitVector bvFlags=0) const
Set Object Data
*bool set (UInt32 pixelFormat, Int32 width, Int32 height=1, Int32 depth=1, Int32 mipmapCount=1, Int32 frameCount=1, Time frameDelay=0.0, const UInt8 *data=0, Int32 type=OSG_UINT8_IMAGEDATA, bool allocMem=true, Int32 sideCount=1)
bool set (ImagePtr image)
bool setData (const UInt8 *data=0)
void clearData (void)
bool setSubData (Int32 offX, Int32 offY, Int32 offZ, Int32 srcW, Int32 srcH, Int32 srcD, const UInt8 *data)
bool flipDepthFrameData (void)
Add Value
*bool addValue (const char *value)
Reformate
*bool reformat (const PixelFormat pixelFormat, ImagePtr destination=NullFC)
Convert dataType
*void swapDataEndian (void)
bool convertDataTypeTo (Int32 destDataType=OSG_UINT8_IMAGEDATA)
Scale
*bool scale (Int32 width, Int32 height=1, Int32 depth=1, ImagePtr destination=NullFC)
bool scaleNextPower2 (ImagePtr destination=NullFC)
SubImage
*bool subImage (Int32 offX, Int32 offY, Int32 offZ, Int32 destW, Int32 destH, Int32 destD, ImagePtr destination=NullFC)
Slice
*bool slice (Int32 offX=-1, Int32 offY=-1, Int32 offZ=-1, ImagePtr destination=NullFC)
Mipmap
*bool createMipmap (Int32 level=-1, ImagePtr destination=NullFC)
Read/Write
*bool write (const Char8 *fileName)
bool read (const Char8 *fileName)
Storage/Restore
*UInt64 store (const Char8 *mimeType, UInt8 *mem, Int32 memSize=-1)
UInt64 restore (const UInt8 *mem, Int32 memSize=-1)
Comparison/Assign
*Imageoperator= (const Image &image)
bool operator< (const Image &image)
bool operator== (const Image &image)
bool operator!= (const Image &image)
Get Methods
*bool isValid (void) const
bool hasAlphaChannel (void)
bool hasColorChannel (void)
bool hasCompressedData (void)
UInt8 getComponents (void) const
Size
*unsigned long getSize (bool withMipmap=true, bool withFrames=true, bool withSides=true) const
Get Methods
*const UInt8getData (UInt32 mipmapNum=0, UInt32 frameNum=0, UInt32 sideNum=0) const
UInt8getData (UInt32 mipmapNum=0, UInt32 frameNum=0, UInt32 sideNum=0)
UInt8getDataByTime (Time time, UInt32 mipmapNum=1)
Calculate
*void calcMipmapGeometry (UInt32 mipmapNum, UInt32 &width, UInt32 &height, UInt32 &depth) const
UInt32 calcMipmapLevelCount (void) const
UInt32 calcFrameNum (Time time, bool loop=true) const
Clear Image
*virtual void clear (UChar8 pixelValue=0)
virtual void clearFloat (Real32 pixelValue=0.0)
virtual void clearHalf (Real16 pixelValue=Real16(0.0))
attachment handling
*bool hasAttachment (void) const
UInt32 attachmentCount (void) const
void setAttachmentField (const std::string &key, const std::string &data)
const std::string * findAttachmentField (const std::string &key) const
Calculate Mipmap Size
*UInt32 calcMipmapLevelSize (UInt32 mipmapNum, UInt32 w, UInt32 h, UInt32 d) const
UInt32 calcMipmapLevelSize (UInt32 mipmapNum) const
UInt32 calcMipmapSumSize (UInt32 mipmapNum, UInt32 w, UInt32 h, UInt32 d) const
UInt32 calcMipmapSumSize (UInt32 mipmapNum) const
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

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

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

Protected Member Functions

Constructors
Image (void)
 Image (const Image &source)
Destructors
*virtual ~Image (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)

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

Static Protected Attributes

static element
*static Int32 _formatDic [][2]
static Int32 _typeDic [][2]

Private Types

typedef ImageBase Inherited

Private Member Functions

Image Data
*bool createData (const UInt8 *data, bool allocMem=true)
bool scaleData (UInt8 *srcData, Int32 srcW, Int32 srcH, Int32 srcD, UInt8 *destData, Int32 destW, Int32 destH, Int32 destD)

Static Private Member Functions

static void initMethod (void)

Friends

class FieldContainer
class ImageBase

Detailed Description

1D/2D/3D Image with various pixel types data, can also optional hold mipMap and simple multi-frame data.

Definition at line 56 of file OSGImage.h.


Member Typedef Documentation

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

Reimplemented from osg::ImageBase.

Definition at line 60 of file OSGImage.h.

typedef ImagePtr osg::ImageBase::Ptr [inherited]
 

Definition at line 109 of file OSGImageBase.h.


Member Enumeration Documentation

enum osg::Image::PixelFormat
 

Enumerator:
OSG_INVALID_PF 
OSG_I_PF 
OSG_L_PF 
OSG_LA_PF 
OSG_BGR_PF 
OSG_BGRA_PF 
OSG_RGB_DXT1 
OSG_RGBA_DXT1 
OSG_RGBA_DXT3 
OSG_RGBA_DXT5 
OSG_RGB_PF 
OSG_RGBA_PF 

Definition at line 65 of file OSGImage.h.

00065                      {   OSG_INVALID_PF = 0,
00066 
00067                          OSG_I_PF       = GL_INTENSITY,
00068 
00069                          OSG_L_PF       = GL_LUMINANCE,
00070                          OSG_LA_PF      = GL_LUMINANCE_ALPHA,
00071 
00072 /*** BGR ***/
00073 #if defined(GL_BGR)
00074                          OSG_BGR_PF     = GL_BGR,
00075 #elif defined(GL_BGR_EXT)
00076                          OSG_BGR_PF     = GL_BGR_EXT,
00077 #else
00078                          OSG_BGR_PF     = 0,
00079 #endif
00080 
00081 /*** BGRA ***/
00082 #if defined(GL_BGRA)
00083                          OSG_BGRA_PF    = GL_BGRA,
00084 #elif defined(GL_BGRA_EXT)
00085                          OSG_BGRA_PF    = GL_BGRA_EXT,
00086 #else
00087                          OSG_BGRA_PF    = 0,
00088 #endif
00089 
00090 /*** RGB_DXT1 ***/
00091 #if defined(GL_COMPRESSED_RGB_S3TC_DXT1_EXT)
00092                          OSG_RGB_DXT1   = GL_COMPRESSED_RGB_S3TC_DXT1_EXT,
00093 #else
00094                          OSG_RGB_DXT1   = 0,
00095 #endif
00096 
00097 /*** RGBA_DXT1 ***/
00098 #if defined(GL_COMPRESSED_RGBA_S3TC_DXT1_EXT)
00099                          OSG_RGBA_DXT1  = GL_COMPRESSED_RGBA_S3TC_DXT1_EXT,
00100 #else
00101                          OSG_RGBA_DXT1   = 0,
00102 #endif
00103 
00104 /*** RGBA_DXT3 ***/
00105 #if defined(GL_COMPRESSED_RGBA_S3TC_DXT3_EXT)
00106                          OSG_RGBA_DXT3  = GL_COMPRESSED_RGBA_S3TC_DXT3_EXT,
00107 #else
00108                          OSG_RGBA_DXT3   = 0,
00109 #endif
00110 
00111 /*** RGBA_DXT5 ***/
00112 #if defined(GL_COMPRESSED_RGBA_S3TC_DXT5_EXT)
00113                          OSG_RGBA_DXT5  = GL_COMPRESSED_RGBA_S3TC_DXT5_EXT,
00114 #else
00115                          OSG_RGBA_DXT5   = 0,
00116 #endif
00117 
00118                          OSG_RGB_PF     = GL_RGB,
00119                          OSG_RGBA_PF    = GL_RGBA
00120     };

enum osg::Image::Type
 

Enumerator:
OSG_INVALID_IMAGEDATATYPE 
OSG_UINT8_IMAGEDATA 
OSG_UINT16_IMAGEDATA 
OSG_UINT32_IMAGEDATA 
OSG_FLOAT16_IMAGEDATA 
OSG_FLOAT32_IMAGEDATA 

Definition at line 122 of file OSGImage.h.

00122               {
00123                          OSG_INVALID_IMAGEDATATYPE  = GL_NONE,
00124                          OSG_UINT8_IMAGEDATA        = GL_UNSIGNED_BYTE,
00125                          OSG_UINT16_IMAGEDATA       = GL_UNSIGNED_SHORT,
00126                          OSG_UINT32_IMAGEDATA       = GL_UNSIGNED_INT,
00127                          OSG_FLOAT16_IMAGEDATA      = GL_HALF_FLOAT_NV,
00128                          OSG_FLOAT32_IMAGEDATA      = GL_FLOAT
00129     };

anonymous enum [inherited]
 

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

Image::Image void   )  [protected]
 

Default Constructor. Creates a invalid Image of the size 0x0x0

Definition at line 2843 of file OSGImage.cpp.

References OSG_INVALID_PF, and osg::ImageBase::setPixelFormat().

02843                  :
02844     Inherited()
02845 {
02846     setPixelFormat(OSG_INVALID_PF);
02847     return;
02848 }

Image::Image const Image obj  )  [protected]
 

Copy Constructor. Creates a copy of the given image

Definition at line 2852 of file OSGImage.cpp.

02852                              :
02853     Inherited(obj)
02854 {
02855 }

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

Destructor.

Definition at line 2859 of file OSGImage.cpp.

02860 {
02861 }


Member Function Documentation

void Image::changed BitVector  whichField,
UInt32  origin
[virtual]
 

Inform parents, when image was changed

Reimplemented from osg::AttachmentContainer.

Definition at line 107 of file OSGImage.cpp.

References osg::ImageBase::_mfParents, _typeDic, osg::MField< FieldTypeT, fieldNameSpace >::begin(), calcMipmapSumSize(), osg::AttachmentContainer::changed(), osg::ChangedOrigin::Child, osg::MField< FieldTypeT, fieldNameSpace >::end(), osg::ImageBase::getDataType(), osg::ImageBase::getMipMapCount(), osg::ImageBase::getSideCount(), osg::ImageBase::getSideSize(), osg::ImageBase::setComponentSize(), osg::ImageBase::setFrameSize(), and osg::ImageBase::setSideSize().

00108 {
00109     MFFieldContainerPtr::iterator parentsIt  = _mfParents.begin();
00110     MFFieldContainerPtr::iterator parentsEnd = _mfParents.end();
00111 
00112     while(parentsIt != parentsEnd)
00113     {
00114         (*parentsIt)->changed(  TypeTraits<BitVector>::One <<
00115                                     parentsIt->getParentFieldPos(),
00116                                 ChangedOrigin::Child);
00117         ++parentsIt;
00118     }
00119     
00120     // Update internals
00121     Int32 mapSizeType = sizeof(_typeDic) / sizeof(UInt32[2]);
00122     UInt32 typeFormat  = 0;
00123     Int32 i;
00124     for(i = 0; i < mapSizeType; i++)
00125     {
00126         if(_typeDic[i][0] == getDataType())
00127             typeFormat = _typeDic[i][1];
00128     }
00129 
00130     setComponentSize( typeFormat );
00131     setSideSize ( calcMipmapSumSize(getMipMapCount()) );
00132     setFrameSize( getSideSize() * getSideCount() );
00133    
00134     Inherited::changed(whichField, origin);
00135 }

void Image::dump