VisualizationFoundation CATTexturePixelImage

Usage: you must use this class as is. You should never derive it.


public class CATTexturePixelImage

Class to create an image used in texture mapping.


Constructor and Destructor Index


o CATTexturePixelImage(CATPixelImage&)
Copy constructor
o CATTexturePixelImage(CATTexturePixelImage&)
Copy constructor
o CATTexturePixelImage(int,int,CATPixelImageFormat)
Contructs a blank texture of given size.
o CATTexturePixelImage(int,int,CATPixelImageFormat,unsigned char*)
Constructs a texture of given size and data.

Method Index


o AddReference()
Increments the reference counter of the texture.
o ChangeFormat(CATPixelImageFormat)
Changes the image format.
o Destroy()
Deletes the texture.
o GetPathName()
Returns the pathname of the image used as the texture.
o GetReferenceNumber()
Returns the reference counter value of the texture.
o IsEqual(CATTexturePixelImage&)
Call this method to check that two textures are the same.
o Modify(int,int,CATPixelImageFormat,unsigned char*,CATDeallocatePixels)
Modify the image used as the texture.
o SendMaterialNotification(CATMaterialNotificationType)
Updates the display after a modification of the graphic material.
o SetPathName(CATString&)
Sets the pathname of the image used as the texture.
o SubReference()
Decrements the reference counter of the texture.
o WriteToFile(CATString&,CATString&)
Writes the texture to a file.

Constructor and Destructor


o CATTexturePixelImage
public CATTexturePixelImage( const iImage)
Copy constructor
o CATTexturePixelImage
public CATTexturePixelImage( const iImage)
Copy constructor
o CATTexturePixelImage
public CATTexturePixelImage( const iWidth,
const iHeight,
const iPixelDataFormat)
Contructs a blank texture of given size.
Parameters:
iWidth
Width of the image used as the texture.
iHeight
Height of the image used as the texture.
iPixelDataFormat
Format of the data. @see CATPixelImageFormat
o CATTexturePixelImage
public CATTexturePixelImage( const iWidth,
const iHeight,
const iPixelDataFormat,
const iPixelData)
Constructs a texture of given size and data.
Parameters:
iWidth
Width of the image used as the texture.
iHeight
Height of the image used as the texture.
iPixelDataFormat
Format of the data. @see CATPixelImageFormat
iPixelData
Data of the image used as the texture.

Methods


o AddReference
public AddReference()
Increments the reference counter of the texture.
o ChangeFormat
public virtual ChangeFormat( iFormat)
Changes the image format.
Valid conversions are: RGB to RGBA and RGBA to RGB.
Parameters:
iFormat
The new format.
Returns:

Legal values
0
Success.
o Destroy
public virtual Destroy()
Deletes the texture.
o GetPathName
public virtual GetPathName()
Returns the pathname of the image used as the texture.
o GetReferenceNumber
public GetReferenceNumber()
Returns the reference counter value of the texture.
o IsEqual
public virtual IsEqual( const iCompare)
Call this method to check that two textures are the same.
o Modify
public virtual Modify( iWidth,
iHeight,
iFormat,
iPixels,
iFlag= PixDeallocateYESfree)
Modify the image used as the texture.
Parameters:
iWidth
Width of new image used as the texture.
iHeight
Height of new image used asthe texture.
iFormat
Pixel data format of new image used as the texture.
iPixels
Pixel data of new image used as the texture
iFormat
Inactive.
o SendMaterialNotification
public virtual SendMaterialNotification( iType)
Updates the display after a modification of the graphic material.
o SetPathName
public virtual SetPathName( const iPathName)
Sets the pathname of the image used as the texture.
Parameters:
iPathName
Pathname of the image.
o SubReference
public SubReference()
Decrements the reference counter of the texture.
o WriteToFile
public virtual WriteToFile( const iFileFormat,
const iPathName)
Writes the texture to a file.
Parameters:
iFileFormat
The output file format.
Legal values
iFileFormat
The output file format.
Legal values
"TIFF"
True color uncompressed TIFF file.
"TIFFTCPB"
True color PackBits compressed TIFF file.
"TIFFINDEX"
Indexed (256 colors) uncompressed TIFF file.
"TIFFPB"
Indexed (256 colors) PackBits compressed TIFF file.
"TIFFGREY"
Grey scale PackBits compressed TIFF file.
"TIFFBWPB"
Bilevel (black and white) PackBits compressed TIFF file.
"RGB"
RGB file (SGI format).
"HPRTL"
HP/RTL - 300 dpi.
"BMP"
Windows Bitmap.
"JPEG_FAIR"
JPEG, fair quality.
"JPEG"
JPEG, medium quality.
"JPEG_HIGH"
JPEG, high quality.
"PNG"
Portable Network Graphics.
"DDS"
Microsoft DirectDraw Surface.
iPathName
The file to save the image in.
Returns:

Legal values
0
Success.

This object is included in the file: CATTexturePixelImage.h
If needed, your Imakefile.mk should include the module: CATVisFoundation

Copyright © 1999-2015, Dassault Systèmes. All rights reserved.