00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef __CEL_PF_MESHSEL__
00021 #define __CEL_PF_MESHSEL__
00022
00023 #include "cstypes.h"
00024 #include "csutil/scf.h"
00025
00026 struct iCelEntity;
00027 struct iPcCamera;
00028 struct iPcMovable;
00029 struct iPcMesh;
00030 struct iPcMeshSelect;
00031 class csVector3;
00032
00033 #define CEL_MOUSE_BUTTON1 1
00034 #define CEL_MOUSE_BUTTON2 2
00035 #define CEL_MOUSE_BUTTON3 4
00036
00040 struct iPcMeshSelectListener : public virtual iBase
00041 {
00042 SCF_INTERFACE (iPcMeshSelectListener, 0, 0, 1);
00043
00047 virtual void MouseDown (iPcMeshSelect* meshsel,
00048 int x, int y, int button, iCelEntity* entity) = 0;
00049
00053 virtual void MouseUp (iPcMeshSelect* meshsel,
00054 int x, int y, int button, iCelEntity* entity) = 0;
00055
00059 virtual void MouseMove (iPcMeshSelect* meshsel,
00060 int x, int y, int button, iCelEntity* entity) = 0;
00061 };
00062
00089 struct iPcMeshSelect : public virtual iBase
00090 {
00091 SCF_INTERFACE (iPcMeshSelect, 0, 0, 2);
00092
00097 virtual void AddMeshSelectListener (iPcMeshSelectListener* listener) = 0;
00101 virtual void RemoveMeshSelectListener (iPcMeshSelectListener* listener) = 0;
00102
00106 virtual void SetCamera (iPcCamera* camera) = 0;
00107
00113 virtual void SetMouseButtons (int buttons) = 0;
00114
00120 virtual void SetMouseButtons (const char* buttons) = 0;
00124 virtual int GetMouseButtons () const = 0;
00125
00133 virtual void SetGlobalSelection (bool glob) = 0;
00137 virtual bool HasGlobalSelection () const = 0;
00138
00147 virtual void SetFollowMode (bool follow) = 0;
00151 virtual bool HasFollowMode () const = 0;
00152
00158 virtual void SetFollowAlwaysMode (bool followalways) = 0;
00162 virtual bool HasFollowAlwaysMode () const = 0;
00163
00170 virtual void SetDragMode (bool drag) = 0;
00174 virtual bool HasDragMode () const = 0;
00175
00185 virtual void SetDragPlaneNormal (const csVector3& drag_normal,
00186 bool camera_space) = 0;
00190 virtual void GetDragPlaneNormal (csVector3& drag_normal,
00191 bool& camera_space) const = 0;
00192
00198 virtual void SetSendmoveEvent (bool mov) = 0;
00202 virtual bool HasSendmoveEvent () const = 0;
00203
00208 virtual void SetSendupEvent (bool su) = 0;
00212 virtual bool HasSendupEvent () const = 0;
00213
00218 virtual void SetSenddownEvent (bool sd) = 0;
00222 virtual bool HasSenddownEvent () const = 0;
00223
00228 virtual void SetMaxSelectionDistance (float distance) = 0;
00229
00233 virtual float GetMaxSelectionDistance () const = 0;
00234 };
00235
00236 #endif // __CEL_PF_MESHSEL__
00237