dummy.h

Go to the documentation of this file.
00001 //**************************************************************************/
00002 // Copyright (c) 1998-2006 Autodesk, Inc.
00003 // All rights reserved.
00004 // 
00005 // These coded instructions, statements, and computer programs contain
00006 // unpublished proprietary information written by Autodesk, Inc., and are
00007 // protected by Federal copyright law. They may not be disclosed to third
00008 // parties or copied or duplicated in any form, in whole or in part, without
00009 // the prior written consent of Autodesk, Inc.
00010 //**************************************************************************/
00011 // FILE:        dummy.h
00012 // DESCRIPTION: 
00013 // AUTHOR:      Dan Silva
00014 // HISTORY:     
00015 //**************************************************************************/
00016 
00017 #pragma once
00018 #include "coreexp.h"
00019 #include "maxtypes.h"
00020 #include "object.h"
00021 
00022 extern CoreExport Class_ID dummyClassID;
00023 
00032 #pragma warning(push)
00033 #pragma warning(disable:4239 4100)
00034 class DummyObject : public HelperObject {              
00035     friend class LuminaireObject;
00036     friend class LuminaireObjectCreateCallBack;
00037     friend class DummyObjectCreateCallBack;
00038     friend INT_PTR CALLBACK DummyParamDialogProc( HWND hDlg, UINT message, 
00039         WPARAM wParam, LPARAM lParam );
00040 
00041     friend class CharacterObject;
00042     
00043         // Mesh cache
00044         Mesh mesh;  
00045         long dumFlags;  
00046         Point3 color;
00047         Box3 box;
00048         Interval valid;
00049         void BuildMesh();
00050         void UpdateMesh();
00051 
00052     //  inherited virtual methods for Reference-management
00053         RefResult NotifyRefChanged( Interval changeInt, RefTargetHandle hTarget, 
00054            PartID& partID, RefMessage message );
00055 
00056     public:
00060         CoreExport DummyObject();
00061 
00064         CoreExport Box3 GetBox() const;
00066         CoreExport void SetBox(Box3& b);
00069         CoreExport void SetColor(Point3 color);
00072         CoreExport void EnableDisplay();
00075         CoreExport void DisableDisplay();
00076         CoreExport void SetValidity(Interval v);
00077 
00078         //  inherited virtual methods:
00079         // From BaseObject
00080         CoreExport int HitTest(TimeValue t, INode* inode, int type, int crossing, int flags, IPoint2 *p, ViewExp *vpt);
00081         CoreExport void Snap(TimeValue t, INode* inode, SnapInfo *snap, IPoint2 *p, ViewExp *vpt);
00082         CoreExport int Display(TimeValue t, INode* inode, ViewExp *vpt, int flags);
00083         CoreExport CreateMouseCallBack* GetCreateMouseCallBack();
00084         CoreExport RefTargetHandle Clone(RemapDir& remap);
00085         Interval ObjectValidity(TimeValue t) { return valid; }
00086 
00087         // From Object
00088         CoreExport ObjectState Eval(TimeValue time);
00089         void InitNodeName(MSTR& s);
00090         int DoOwnSelectHilite() {return 1; }        
00091         int IsRenderable(){ return 0; }
00092         MCHAR *GetObjectName();
00093 
00094         //  From Object
00095         CoreExport void GetWorldBoundBox(TimeValue t, INode *mat, ViewExp *vpt, Box3& box );
00096         CoreExport void GetLocalBoundBox(TimeValue t, INode *mat, ViewExp *vpt, Box3& box );
00097         CoreExport void GetDeformBBox(TimeValue t, Box3& box, Matrix3 *tm, BOOL useSel=FALSE );
00098 
00099 
00100         // IO
00101         CoreExport IOResult Save(ISave *isave);
00102         CoreExport IOResult Load(ILoad *iload);
00103 
00104         // From ReferenceMaker
00105         CoreExport void RescaleWorldUnits(float f);
00106 
00107         // Animatable methods
00108         CoreExport void DeleteThis();
00109         Class_ID ClassID() { return dummyClassID; }  
00110         void GetClassName(MSTR& s);
00111         int IsKeyable(){ return 1;}
00112         LRESULT CALLBACK TrackViewWinProc( HWND hwnd,  UINT message, 
00113                 WPARAM wParam,   LPARAM lParam ){return(0);}
00114     };
00115 #pragma warning(pop)
00116 CoreExport ClassDesc* GetDummyObjDescriptor();