#include <attrbev.h>
Inheritance diagram for AttrBevelContrast:
Public Member Functions | |
AttrBevelContrast () | |
Default constructor for Line Width Attribute class. | |
AttrBevelContrast (Node *ContextNode, AttachNodeDirection Direction, BOOL Locked=FALSE, BOOL Mangled=FALSE, BOOL Marked=FALSE, BOOL Selected=FALSE) | |
Creates a bValue Attribute. | |
virtual CCRuntimeClass * | GetAttributeType () |
virtual AttributeValue * | GetAttributeValue () |
virtual AttrIndex | GetAttributeIndex () |
void | Render (RenderRegion *pRender) |
'Renders' a Line Width attribute. | |
Node * | SimpleCopy () |
This method returns a shallow copy of the node with all Node pointers NULL. The function is virtual, and must be defined for all derived classes. | |
virtual INT32 | operator== (const NodeAttribute &NodeAttrib) |
A virtual comparison operator. See NodeAttribute::operator== for a description of why it's required. | |
virtual UINT32 | GetAttrNameID (void) |
Returns back a string resource ID describing the attribute. | |
void | ShowDebugTreeDetails () const |
Displays debugging info of the tree. | |
void | GetDebugDetails (StringBase *Str) |
For obtaining debug information about the Node. | |
virtual UINT32 | GetNodeSize () const |
For finding the size of the node. | |
virtual void | Transform (TransformBase &) |
Scale the Line Width. | |
virtual BOOL | EffectsParentBounds () |
Virtual function for determining if the node will effect it's parent bounds. eg. ArrowHeads. | |
virtual BOOL | WritePreChildrenWeb (BaseCamelotFilter *pFilter) |
Writes the line width record to the filter. | |
virtual BOOL | WritePreChildrenNative (BaseCamelotFilter *pFilter) |
void | SetValue (INT32 NewValue) |
BOOL | Blend (BlendAttrParam *pBlendParam) |
Blends this light angle to another. | |
virtual void | PolyCopyNodeContents (NodeRenderable *pNodeCopy) |
Polymorphically copies the contents of this node to another. | |
Public Attributes | |
BevelAttributeValueContrast | Value |
Private Member Functions | |
void | CopyNodeContents (AttrBevelContrast *NodeCopy) |
This method copies the node's contents to the node pointed to by NodeCopy. |
Definition at line 354 of file attrbev.h.
|
Default constructor for Line Width Attribute class.
Definition at line 759 of file attrbev.cpp.
|
|
Creates a bValue Attribute.
Definition at line 734 of file attrbev.cpp. 00740 : AttrBevel(ContextNode, Direction, Locked, Mangled, Marked, Selected) 00741 { 00742 }
|
|
Blends this light angle to another.
Reimplemented from NodeAttribute. Definition at line 937 of file attrbev.cpp. 00938 { 00939 ERROR2IF(pBlendParam == NULL,FALSE,"pBlendParam == NULL"); 00940 ERROR3IF(!(pBlendParam->GetOtherAttr()->IS_KIND_OF(AttrBevelContrast)), 00941 "Blend attribute isn't a bevel contrast attribute"); 00942 00943 AttrBevelContrast * pBlendedAttr = NULL; 00944 00945 // assign the other attribute we're looking at 00946 AttrBevelContrast * pOtherAttr = (AttrBevelContrast *)pBlendParam->GetOtherAttr(); 00947 00948 // split at the half way mark 00949 if (pBlendParam->GetBlendRatio() <= 0.5) 00950 { 00951 pBlendedAttr = (AttrBevelContrast *)SimpleCopy(); 00952 } 00953 else 00954 { 00955 pBlendedAttr = (AttrBevelContrast *)pOtherAttr->SimpleCopy(); 00956 } 00957 00958 // set the blended attribute 00959 pBlendParam->SetBlendedAttr(pBlendedAttr); 00960 00961 if (!pBlendedAttr) 00962 return FALSE; 00963 00964 double Contrast1 = Value.m_Contrast; 00965 double Contrast2 = pOtherAttr->Value.m_Contrast; 00966 double NewContrast = ((Contrast2 - Contrast1) * pBlendParam->GetBlendRatio()) + 00967 Contrast1; 00968 00969 // set the blended attribute's values 00970 pBlendedAttr->Value.m_Contrast = (INT32)NewContrast; 00971 00972 return TRUE; 00973 }
|
|
This method copies the node's contents to the node pointed to by NodeCopy.
Definition at line 896 of file attrbev.cpp. 00897 { 00898 NodeAttribute::CopyNodeContents( NodeCopy ); 00899 00900 NodeCopy->Value = Value; 00901 }
|
|
Virtual function for determining if the node will effect it's parent bounds. eg. ArrowHeads.
Reimplemented from NodeAttribute. Definition at line 384 of file attrbev.h. 00384 { return FALSE; }
|
|
Reimplemented from NodeAttribute. Definition at line 369 of file attrbev.h. 00369 { return ATTR_BEVELCONTRAST; }
|
|
Reimplemented from NodeAttribute. Definition at line 367 of file attrbev.h. 00367 { return CC_RUNTIME_CLASS(AttrBevelContrast); }
|
|
Reimplemented from NodeAttribute. Definition at line 368 of file attrbev.h. 00368 { return &Value; }
|
|
Returns back a string resource ID describing the attribute.
Reimplemented from NodeAttribute. Definition at line 872 of file attrbev.cpp. 00873 { 00874 return (_R(IDS_BEVEL_CONTRAST_ID)); 00875 }
|
|
For obtaining debug information about the Node.
Reimplemented from NodeRenderable. Definition at line 996 of file attrbev.cpp. 00997 { 00998 #ifdef _DEBUG 00999 NodeAttribute::GetDebugDetails( Str ); 01000 01001 String_256 TempStr; 01002 TempStr._MakeMsg( TEXT("\r\nValue=#1%d\r\n"), Value.m_Contrast ); 01003 (*Str)+= TempStr; 01004 #else 01005 if (Str) 01006 { 01007 *Str = wxT(""); 01008 } 01009 #endif 01010 }
|
|
For finding the size of the node.
Reimplemented from Node. Definition at line 1028 of file attrbev.cpp. 01029 { 01030 return (sizeof(AttrBevelContrast)); 01031 }
|
|
A virtual comparison operator. See NodeAttribute::operator== for a description of why it's required.
Reimplemented from NodeAttribute. Definition at line 847 of file attrbev.cpp. 00848 { 00849 ENSURE(Attrib.IsKindOf(CC_RUNTIME_CLASS(AttrBevelContrast)), 00850 "Trying to compare two objects with different types"); 00851 AttrBevelContrast * Attr = (AttrBevelContrast *) &Attrib; 00852 return (Attr->Value.m_Contrast == Value.m_Contrast); 00853 }
|
|
Polymorphically copies the contents of this node to another.
Reimplemented from NodeRenderable. Definition at line 915 of file attrbev.cpp. 00916 { 00917 ENSURE(pNodeCopy, "Trying to copy a node's contents into a NULL node"); 00918 ENSURE(IS_A(pNodeCopy, AttrBevelContrast), "PolyCopyNodeContents given wrong dest node type"); 00919 00920 if (IS_A(pNodeCopy, AttrBevelContrast)) 00921 CopyNodeContents((AttrBevelContrast*)pNodeCopy); 00922 }
|
|
'Renders' a Line Width attribute.
Reimplemented from NodeAttribute. Definition at line 779 of file attrbev.cpp.
|
|
Definition at line 390 of file attrbev.h. 00390 { Value.m_Contrast = NewValue; }
|
|
Displays debugging info of the tree.
Definition at line 986 of file attrbev.cpp. 00987 { 00988 // Display a bit of debugging info 00989 // For now, we will just call the base class version 00990 #ifdef _DEBUG 00991 NodeAttribute::ShowDebugTreeDetails(); 00992 #endif 00993 }
|
|
This method returns a shallow copy of the node with all Node pointers NULL. The function is virtual, and must be defined for all derived classes.
Reimplemented from NodeAttribute. Definition at line 819 of file attrbev.cpp. 00820 { 00821 AttrBevelContrast* NodeCopy = new AttrBevelContrast(); 00822 ERRORIF(NodeCopy == NULL, _R(IDE_NOMORE_MEMORY), NULL); 00823 CopyNodeContents(NodeCopy); 00824 NodeCopy->Value.m_Contrast = Value.m_Contrast; 00825 return NodeCopy; 00826 }
|
|
Scale the Line Width.
Reimplemented from NodeRenderable. Definition at line 795 of file attrbev.cpp.
|
|
Reimplemented from Node. Definition at line 1054 of file attrbev.cpp. 01055 { 01056 #ifdef DO_EXPORT 01057 return WritePreChildrenWeb(pFilter); 01058 #else 01059 return FALSE; 01060 #endif 01061 }
|
|
Writes the line width record to the filter. > virtual BOOL AttrBevelContrast::WritePreChildrenWeb(BaseCamelotFilter* pFilter)
Reimplemented from Node. Definition at line 1046 of file attrbev.cpp. 01047 { 01048 return TRUE; 01049 }
|
|
|