Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

exotkMaterial Class Reference

Utility class to handle materials. More...

#include <exotkMaterial.hxx>

List of all members.

Public Methods

void * operator new (size_t, void *anAddress)
 OCC new. More...

void * operator new (size_t size)
 OCC new. More...

void operator delete (void *anAddress)
 OCC delete. More...


Static Public Methods

Standard_EXPORT Standard_Boolean AddMaterial (const TCollection_AsciiString &aName, const Graphic3d_MaterialAspect &aMaterial, const Standard_Boolean aIsModifiable)
 Add aMaterial with aName and the flag aIsModifiable to the list of known materials. More...

Standard_EXPORT Standard_Boolean ReplaceMaterial (const TCollection_AsciiString &aName, const Graphic3d_MaterialAspect &aNewMaterial)
 Replace the material named aName with aNewMaterial. More...

Standard_EXPORT Standard_Boolean NameExists (const TCollection_AsciiString &aName)
 Return true if aNAme already exists. More...

Standard_EXPORT Standard_Boolean CurrentMaterial (Graphic3d_MaterialAspect &aMaterial)
 Returns the current material. More...

Standard_EXPORT Standard_Boolean CurrentName (TCollection_AsciiString &aName)
 Returns the current material name. More...

Standard_EXPORT void NextMaterialIterator ()
 iterator. More...

Standard_EXPORT Standard_Boolean MoreMaterialIterator ()
 iterator. More...

Standard_EXPORT void InitMaterialIterator ()
 iterator. More...

Standard_EXPORT Standard_Boolean IsModifiable (const Graphic3d_MaterialAspect &aMaterial, Standard_Boolean &aIsModifiable)
 return the modifiable status of aMaterial. More...

Standard_EXPORT Standard_Boolean IsModifiable (const TCollection_AsciiString &aName, Standard_Boolean &aIsModifiable)
 return the modifiable status of the Material named aName. More...

Standard_EXPORT Standard_Boolean FindName (const Graphic3d_MaterialAspect &aMaterial, TCollection_AsciiString &aFoundName)
 return the name of aMaterial. More...

Standard_EXPORT Standard_Boolean FindMaterial (const TCollection_AsciiString &aName, Graphic3d_MaterialAspect &aFoundMaterial)
 Return the material named aName. More...

Standard_EXPORT Handle_exotkMaterial_Material FindMaterial (const Graphic3d_MaterialAspect &aMaterial)
 return the intern material for aMaterial. More...

Standard_EXPORT Handle_exotkMaterial_Material FindMaterial (const TCollection_AsciiString &aName)
 return the intern material for aName. More...


Static Protected Methods

void InitStandardMaterials ()
 init the standard OpenCASCADE materials. More...


Detailed Description

Utility class to handle materials.

Todo:
methods to read\write materials and material library
Author:
Stephane Routelous

Definition at line 50 of file exotkMaterial.hxx.


Member Function Documentation

exotkMaterial::AddMaterial const TCollection_AsciiString &    aName,
const Graphic3d_MaterialAspect &    aMaterial,
const Standard_Boolean    aIsModifiable
[static]
 

Add aMaterial with aName and the flag aIsModifiable to the list of known materials.

Returns:
Standard_Boolean : true if the material is added
Parameters:
aName  const TCollection_AsciiString&
aMaterial  const Graphic3d_MaterialAspect&
aIsModifiable  const Standard_Boolean

Definition at line 392 of file exotkMaterial.cxx.

References InitStandardMaterials().

exotkMaterial::CurrentMaterial Graphic3d_MaterialAspect &    aMaterial [static]
 

Returns the current material.

Returns:
Standard_Boolean : true if success
Return values:
aMaterial  Graphic3d_MaterialAspect&

Definition at line 137 of file exotkMaterial.cxx.

exotkMaterial::CurrentName TCollection_AsciiString &    aName [static]
 

Returns the current material name.

Returns:
Standard_Boolean
Return values:
aName  TCollection_AsciiString&

Definition at line 156 of file exotkMaterial.cxx.

exotkMaterial::FindMaterial const TCollection_AsciiString &    aName [static]
 

return the intern material for aName.

Returns:
Handle_exotkMaterial_Material : Null if not found
Parameters:
aName  const TCollection_AsciiString&

Definition at line 282 of file exotkMaterial.cxx.

References exotkMaterial_MapIteratorOfMapOfMaterial::Initialize(), InitStandardMaterials(), and exotkMaterial_MapIteratorOfMapOfMaterial::Key().

exotkMaterial::FindMaterial const Graphic3d_MaterialAspect &    aMaterial [static]
 

return the intern material for aMaterial.

Returns:
Handle_exotkMaterial_Material : Null if not found
Parameters:
aMaterial  const Graphic3d_MaterialAspect&

Definition at line 258 of file exotkMaterial.cxx.

References exotkMaterial_MapIteratorOfMapOfMaterial::Initialize(), InitStandardMaterials(), IsSameMaterial(), and exotkMaterial_MapIteratorOfMapOfMaterial::Key().

exotkMaterial::FindMaterial const TCollection_AsciiString &    aName,
Graphic3d_MaterialAspect &    aFoundMaterial
[static]
 

Return the material named aName.

Returns:
Standard_Boolean
Parameters:
aName  const TCollection_AsciiString&
Return values:
aFoundMaterial  Graphic3d_MaterialAspect&

Definition at line 329 of file exotkMaterial.cxx.

References InitStandardMaterials().

Referenced by FindName(), IsModifiable(), NameExists(), and ReplaceMaterial().

exotkMaterial::FindName const Graphic3d_MaterialAspect &    aMaterial,
TCollection_AsciiString &    aFoundName
[static]
 

return the name of aMaterial.

Returns:
Standard_Boolean
Parameters:
aMaterial  const Graphic3d_MaterialAspect&
Return values:
aFoundName  TCollection_AsciiString&

Definition at line 307 of file exotkMaterial.cxx.

References FindMaterial(), and InitStandardMaterials().

exotkMaterial::InitMaterialIterator   [static]
 

iterator.

Definition at line 199 of file exotkMaterial.cxx.

References InitStandardMaterials().

exotkMaterial::InitStandardMaterials   [static, protected]
 

init the standard OpenCASCADE materials.

Definition at line 104 of file exotkMaterial.cxx.

References Graphic3d_NameOfMaterial.

Referenced by AddMaterial(), FindMaterial(), FindName(), InitMaterialIterator(), IsModifiable(), and ReplaceMaterial().

exotkMaterial::IsModifiable const TCollection_AsciiString &    aName,
Standard_Boolean &    aIsModifiable
[static]
 

return the modifiable status of the Material named aName.

Returns:
Standard_Boolean : success
Parameters:
aName  const TCollection_AsciiString&
Return values:
aIsModifiable  Standard_Boolean&

Definition at line 215 of file exotkMaterial.cxx.

References FindMaterial(), and InitStandardMaterials().

exotkMaterial::IsModifiable const Graphic3d_MaterialAspect &    aMaterial,
Standard_Boolean &    aIsModifiable
[static]
 

return the modifiable status of aMaterial.

Returns:
Standard_Boolean : success
Parameters:
aMaterial  const Graphic3d_MaterialAspect&
Return values:
aIsModifiable  Standard_Boolean&

Definition at line 237 of file exotkMaterial.cxx.

References FindMaterial(), and InitStandardMaterials().

exotkMaterial::MoreMaterialIterator   [static]
 

iterator.

Returns:
Standard_Boolean

Definition at line 187 of file exotkMaterial.cxx.

exotkMaterial::NameExists const TCollection_AsciiString &    aName [static]
 

Return true if aNAme already exists.

Returns:
Standard_Boolean
Parameters:
aName  const TCollection_AsciiString&

Definition at line 351 of file exotkMaterial.cxx.

References FindMaterial().

exotkMaterial::NextMaterialIterator   [static]
 

iterator.

Definition at line 175 of file exotkMaterial.cxx.

void exotkMaterial::operator delete void *    anAddress [inline]
 

OCC delete.

Returns:
inline void
Parameters:
void  *anAddress

Definition at line 83 of file exotkMaterial.hxx.

void * exotkMaterial::operator new size_t    size [inline]
 

OCC new.

Returns:
inline void*
Parameters:
size_t  size

Definition at line 72 of file exotkMaterial.hxx.

void * exotkMaterial::operator new size_t   ,
void *    anAddress
[inline]
 

OCC new.

Returns:
inline void*
Parameters:
size_t 
void  * anAddress

Definition at line 61 of file exotkMaterial.hxx.

exotkMaterial::ReplaceMaterial const TCollection_AsciiString &    aName,
const Graphic3d_MaterialAspect &    aNewMaterial
[static]
 

Replace the material named aName with aNewMaterial.

Returns:
Standard_Boolean : true if success ( if the old material is not modifiable, returns false )
Parameters:
aName  const TCollection_AsciiString&
aNewMaterial  const Graphic3d_MaterialAspect&

Definition at line 365 of file exotkMaterial.cxx.

References FindMaterial(), and InitStandardMaterials().


The documentation for this class was generated from the following files:
Generated on Wed Jan 23 12:18:33 2002 for exotk by doxygen1.2.12 written by Dimitri van Heesch, © 1997-2001