PFMessages.h

Go to the documentation of this file.
00001 
00004 /**********************************************************************
00005  *<
00006     CREATED BY: Oleg Bayborodin
00007 
00008     HISTORY: created 12-19-01
00009 
00010  *> Copyright (c) 2001, All Rights Reserved.
00011 **********************************************************************/
00012 
00013 #pragma once
00014 #include "..\maxheap.h"
00015 #include "..\ref.h"
00016 #include "..\hitdata.h"
00017 #include "PreciseTimeValue.h"
00018 // forward declarations
00019 class ModContext;
00020 class ViewExp;
00021 class Box3;
00022 class Mesh;
00023 class INode;
00024 class FPMixinInterface;
00025 class SubObjAxisCallback;
00026 class Point3;
00027 class Quat;
00028 class AngAxis;
00029 
00030 // PF notification messages
00031 enum {  kPFMSG_UpdateToTime = REFMSG_USER + 4878,       // x1130E
00032         kPFMSG_HasSurplus,                              // x1130F
00033         kPFMSG_PFShellWiringChanged,                    // x11310
00034         kPFMSG_ActionListWiringChanged,                 // x11311
00035         kPFMSG_GetNextActionList,                       // x11312
00036         kPFMSG_GetNumParticles,                         // x11313
00037         kPFMSG_GetNumParticlesGenerated,                // x11314
00038         kPFMSG_GetUpdateTime,
00039         kPFMSG_GetUpdateInterval,
00040         kPFMSG_GetParticleBornIndex,
00041         kPFMSG_GetParticleIndex,
00042         kPFMSG_GetParticleGroup,
00043         kPFMSG_GetParticleTime,
00044         kPFMSG_SetParticleTime,
00045         kPFMSG_GetParticleAge,
00046         kPFMSG_SetParticleAge,
00047         kPFMSG_GetParticleLifeSpan,
00048         kPFMSG_SetParticleLifeSpan,
00049         kPFMSG_GetParticleEventTime,
00050         kPFMSG_SetParticleEventTime,
00051         kPFMSG_GetParticlePosition,
00052         kPFMSG_SetParticlePosition,
00053         kPFMSG_GetParticleSpeed,
00054         kPFMSG_SetParticleSpeed,
00055         kPFMSG_GetParticleOrientation,
00056         kPFMSG_SetParticleOrientation,
00057         kPFMSG_GetParticleSpin,
00058         kPFMSG_SetParticleSpin,
00059         kPFMSG_GetParticleScale,
00060         kPFMSG_SetParticleScale,
00061         kPFMSG_GetParticleSelected,
00062         kPFMSG_SetParticleSelected,
00063         kPFMSG_GetParticleShape,
00064         kPFMSG_SetParticleShape,
00065         kPFMSG_SetParticleGlobalShape,
00066         kPFMSG_UpdateMaterial,
00067         kPFMSG_ActionListContentChanged,
00068         kPFMSG_OpenParticleView,
00069         kPFMSG_IsDownStream,
00070         kPFMSG_UpdateTypeChanged,
00071         kPFMSG_InvalidateParticles,
00072         kPFMSG_InvalidateViewportParticles,
00073         kPFMSG_InvalidateRenderParticles,
00074         kPFMSG_GetSubObjectCentersRequest,
00075         kPFMSG_GetSubObjectTMsRequest,
00076         kPFMSG_HitTestRequest,
00077         kPFMSG_GetBoundBoxRequest,
00078         kPFMSG_GetNumParticlesActionList,
00079         kPFMSG_GetParticleBornIndexActionList,
00080         kPFMSG_UpdateWireColor,
00081         kPFMSG_GetNodeValue,
00082         kPFMSG_HasUpStreamActionList,
00083         kPFMSG_IsActionActive,
00084         kPFMSG_GetParentActionList,
00085         kPFMSG_PreDeleteNode,
00086         kPFMSG_GetNumParticlesInParticleGroup,
00087         kPFMSG_InvalidateDownStream,
00088         kPFMSG_ActionListActivityChanged,
00089         kPFMSG_SyncRenderState,
00090         kPFMSG_CheckEscape,
00091         kPFMSG_DynamicNameChange,
00092         kPFMSG_ConfirmNotifyCatcherPresence,
00093         kPFMSG_cacheUpdateStart,
00094         kPFMSG_cacheUpdateFinish
00095     };
00096 
00097 struct GetSubObjectRequestData: public MaxHeapOperators {
00098     SubObjAxisCallback* cb;
00099     TimeValue t;
00100     INode* node;
00101     ModContext* mc;
00102 };
00103 
00104 struct HitTestRequestData: public MaxHeapOperators {
00105     TimeValue t;
00106     INode* inode;
00107     int type;
00108     int crossing;
00109     int flags;
00110     IPoint2* p;
00111     ViewExp* vpt;
00112     ModContext* mc;
00113     int hitResult;
00114 };
00115 
00116 struct GetBoundBoxRequestData: public MaxHeapOperators {
00117     TimeValue t;
00118     INode* inode;
00119     ViewExp* vp;
00120     Box3* box;
00121 };
00122 
00123 struct GetParticleDataRequest: public MaxHeapOperators {
00124     int index;
00125     union {
00126         int count;
00127         int bornIndex;
00128         INode* pGroup;
00129         PreciseTimeValue* time;
00130         PreciseTimeValue* age;
00131         PreciseTimeValue* lifeSpan;
00132         PreciseTimeValue* eventTime;
00133         Point3* position;
00134         Point3* speed;
00135         Point3* acceleration;
00136         Quat*   orientation;
00137         AngAxis* spin;
00138         Point3* scale;
00139         bool selected;
00140         Mesh* shape;
00141     };
00142 };
00143 
00144 struct GetTimeDataRequest: public MaxHeapOperators {
00145     TimeValue time;
00146     TimeValue start;
00147     TimeValue finish;
00148 };
00149 
00150 // the class is used to identify particle group
00151 // and action list the hit particle belongs to
00152 class PFHitData : public HitData {
00153 public:
00154     INode* particleGroupNode;
00155     INode* actionListNode;
00156     PFHitData() { particleGroupNode = NULL; actionListNode = NULL; }
00157     PFHitData(INode* pgroup, INode* alist) { particleGroupNode = pgroup; actionListNode = alist; }
00158 };
00159 
00160 // the class is used to retrieve activity status
00161 // of an action item and its parent action list
00162 struct PFActiveActionDataRequest: public MaxHeapOperators {
00163     INode* actionNode;
00164     int active;
00165     FPMixinInterface* iActionList;
00166 };
00167