00001
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #pragma once
00018
00019 #include "PFExport.h"
00020 #include "..\ifnpub.h"
00021
00022 class Box3;
00023
00024
00025
00026 #define PARTICLECHANNELMESHR_INTERFACE Interface_ID(0x74f93c11, 0x1eb34500)
00027 #define PARTICLECHANNELMESHW_INTERFACE Interface_ID(0x74f93c11, 0x1eb34501)
00028
00029
00030
00031
00032
00033
00034 class IParticleChannelMeshR : public FPMixinInterface
00035 {
00036 public:
00037
00038
00039 enum { kIsShared,
00040 kGetValueCount,
00041 kGetValueIndex,
00042 kGetValueByIndex,
00043 kGetValue,
00044 kGetValueFirst,
00045 kGetMaxBoundingBox
00046 };
00047
00048 BEGIN_FUNCTION_MAP
00049
00050 FN_0(kIsShared, TYPE_bool, IsShared);
00051 FN_0(kGetValueCount, TYPE_INT, GetValueCount);
00052 FN_1(kGetValueIndex, TYPE_INT, GetValueIndex, TYPE_INT);
00053 FN_1(kGetValueByIndex, TYPE_MESH, GetValueByIndex, TYPE_INT);
00054 FN_1(kGetValue, TYPE_MESH, GetValue, TYPE_INT);
00055 FN_0(kGetValueFirst, TYPE_MESH, GetValue);
00056 VFN_2(kGetMaxBoundingBox, GetMaxBoundingBox, TYPE_POINT3_BR, TYPE_POINT3_BR);
00057
00058 END_FUNCTION_MAP
00059
00060
00061
00062 virtual bool IsShared() const = 0;
00063
00064 virtual int GetValueCount() const = 0;
00065
00066 virtual int GetValueIndex(int particleIndex) const = 0;
00067
00068 virtual const Mesh* GetValueByIndex(int valueIndex) const = 0;
00069
00070 virtual const Mesh* GetValue(int particleIndex) const = 0;
00071
00072
00073 virtual const Mesh* GetValue() const = 0;
00074
00075 virtual const Box3& GetMaxBoundingBox() const = 0;
00076
00077 PFExport void GetMaxBoundingBox(Point3& corner1, Point3& corner2) const;
00078
00079 FPInterfaceDesc* GetDesc() { return GetDescByID(PARTICLECHANNELMESHR_INTERFACE); }
00080 };
00081
00082 class IParticleChannelMeshW : public FPMixinInterface
00083 {
00084 public:
00085
00086
00087 enum { kSetValue,
00088 kSetValueMany,
00089 kSetValueAll,
00090 kCopyValue,
00091 kCopyValueMany,
00092 kCopyValueAll,
00093 kBuildMaxBoundingBox
00094 };
00095
00096 BEGIN_FUNCTION_MAP
00097
00098 FN_2(kSetValue, TYPE_bool, SetValue, TYPE_INT, TYPE_MESH);
00099 FN_2(kSetValueMany, TYPE_bool, SetValue, TYPE_INT_TAB_BR, TYPE_MESH);
00100 FN_1(kSetValueAll, TYPE_bool, SetValue, TYPE_MESH);
00101 FN_2(kCopyValue, TYPE_bool, CopyValue, TYPE_INT, TYPE_INT);
00102 FN_2(kCopyValueMany, TYPE_bool, CopyValue, TYPE_INT, TYPE_INT_TAB_BR);
00103 FN_1(kCopyValueAll, TYPE_bool, CopyValue, TYPE_INT);
00104 VFN_0(kBuildMaxBoundingBox, BuildMaxBoundingBox);
00105
00106 END_FUNCTION_MAP
00107
00108
00109
00110 virtual bool SetValue(int particleIndex, Mesh* mesh) = 0;
00111
00112
00113 virtual bool SetValue(Tab<int>& particleIndices, Mesh* mesh) = 0;
00114
00115
00116 virtual bool SetValue(Mesh* mesh) = 0;
00117
00118 virtual bool CopyValue(int fromParticle, int toParticle) = 0;
00119
00120 virtual bool CopyValue(int fromParticle, Tab<int>& toParticles) = 0;
00121
00122 virtual bool CopyValue(int fromParticle) = 0;
00123
00124 virtual void BuildMaxBoundingBox() = 0;
00125
00126 FPInterfaceDesc* GetDesc() { return GetDescByID(PARTICLECHANNELMESHW_INTERFACE); }
00127 };
00128