124 m_matrix2 = m_matrix1;
131 m_matrix1 = m_matrix2;
139 m_matrix1 = m_matrix2;
168 MXM4(mat, m_matrix1, p_transform);
ViewROI * GetPointOfView()
[AI] Returns the current point-of-view object (the ViewROI the camera is following).
BOOL Moved(ViewROI &rROI)
[AI] Notifies the view that a ViewROI has moved.
Camera controller for 3D scenes, handles interactive camera manipulation and view transformation.
void SetWorldTransform(const Vector3 &p_at, const Vector3 &p_dir, const Vector3 &p_up)
Updates the camera's world transformation matrix using view reference parameters.
Mx3DPointFloat GetWorldUp()
Gets the camera's current world-space up vector.
virtual void OnLButtonDown(MxPoint32 p_point)
Called when the left mouse button is pressed at a screen point.
void FUN_10012290(float p_angle)
Rotates the current camera transformation by a given angle around the Z axis.
Mx3DPointFloat GetWorldDirection()
Gets the camera's world-space forward direction vector.
void FUN_10012320(float p_angle)
Rotates the current camera transformation by a given angle around the Y axis.
virtual MxResult Create()
Registers the camera controller with input manager and initializes state with current view.
MxResult FUN_100123b0(Matrix4 &p_matrix)
Retrieves the current point-of-view transformation into a matrix if it exists.
virtual void OnRButtonUp(MxPoint32 p_point)
Called when the right mouse button is released at a screen point.
virtual void OnLButtonUp(MxPoint32 p_point)
Called when the left mouse button is released at a screen point.
void FUN_100123e0(const Matrix4 &p_transform, MxU32 p_und)
Sets the camera's transformation matrix in the 3D view, optionally applying a blend with the internal...
virtual void OnMouseMove(MxU8 p_modifier, MxPoint32 p_point)
Called when the mouse is moved.
virtual void OnRButtonDown(MxPoint32 p_point)
Called when the right mouse button is pressed at a screen point.
MxLong Notify(MxParam &p_param) override
Handles notifications for camera-relevant events (like mouse drag and mouse clicks).
~LegoCameraController() override
Destructor.
Mx3DPointFloat GetWorldLocation()
Gets the camera's current world-space location.
Notification parameter class for LEGO event notifications such as mouse events and modifier keys.
void LeftDrag(int p_x, int p_y) override
[AI] Called when cursor moves with left mouse button held; typically drags the point of view.
void RightDrag(int p_x, int p_y) override
[AI] Called when right button is held and cursor is moved, e.g., for rotational camera movement.
void LeftDown(int p_x, int p_y) override
[AI] Called when left mouse button is pressed; may start point-of-view manipulation.
void LeftUp(int p_x, int p_y) override
[AI] Called when the left button is released, possibly to end the manipulation and update the camera/...
MxDouble m_entityOffsetUp
[AI] Offset along the entity's upward vector (for perspective/camera alignment). [AI]
MxResult Create(Lego3DView *p_lego3DView)
[AI] Initializes the controller with a specific 3D view.
Lego3DView * m_lego3DView
[AI] The active 3D view that input actions are translated into. [AI]
void RightDown(int p_x, int p_y) override
[AI] Called when the right mouse button is pressed; often used for alternative camera controls.
void RightUp(int p_x, int p_y) override
[AI] Called when the right mouse button is released, possibly to finalize alternative camera/entity a...
void UpdateListener(const float *p_position, const float *p_direction, const float *p_up, const float *p_velocity)
[AI] Updates the 3D sound listener properties in DirectSound, reflecting player/world changes.
4x4 Matrix class with virtual interface for manipulation and transformation.
void RotateY(const float &p_angle)
Applies a rotation (in radians or degrees, depending on implementation) about the Y axis.
void RotateZ(const float &p_angle)
Applies a rotation (in radians or degrees) about the Z axis.
[AI] Represents a 3D point with floating-point precision, inheriting from Vector3.
[AI] Represents a 4x4 transformation matrix, specialized for the LEGO Island engine and derived from ...
[AI] Parameter object representing a single notification or event, carrying an identifier and sender ...
[AI] MxParam serves as a polymorphic base class for parameter passing in event and notification syste...
[AI] 2D point with 32-bit signed integer coordinates.
T GetY() const
[AI] Get Y coordinate.
T GetX() const
[AI] Get X coordinate.
MxLong GetTime()
Returns the current timer value in ms, depending on running state.
const float * GetWorldUp() const
Returns a pointer to the world up vector from the transformation matrix.
const float * GetWorldPosition() const
Returns a pointer to the world position from the transformation matrix (translation row).
const float * GetWorldDirection() const
Returns a pointer to the world direction vector (forward axis) from the transformation matrix.
const Matrix4 & GetLocal2World() const
Accessor for the current local-to-world transformation matrix.
void WrappedSetLocalTransform(const Matrix4 &p_transform)
Wraps SetLocalTransform, for possible override or interface uniformity.
const float * GetWorldVelocity() const override
Returns a pointer to the object's velocity vector in world space.
[AI] An extension of LegoROI that adds support for keeping and applying a base time reference (used f...
[AI] 3D vector class, providing vector and cross-product operations in 3D space.
[AI] ViewROI objects represent viewable and placeable objects in the scene, each holding their own tr...
#define DECOMP_SIZE_ASSERT(T, S)
#define NULL
[AI] Null pointer value (C/C++ semantics).
#define FAILURE
[AI] Used to indicate a failed operation in result codes.
#define SUCCESS
[AI] Used to indicate a successful operation in result codes.
LegoVideoManager * VideoManager()
[AI] Accessor for the game's LegoVideoManager subsystem. Used for managing 3D/video hardware....
LegoSoundManager * SoundManager()
[AI] Accessor for the game's LegoSoundManager subsystem from the global LegoOmni instance....
LegoInputManager * InputManager()
[AI] Accessor for the input manager, which handles keyboard, mouse, and controller input....
MxTimer * Timer()
[AI] Returns the global simulation timer.
@ c_notificationDragEnd
[AI] End of drag event [AI]
@ c_notificationDragStart
[AI] Start of a drag event (mouse/touch) [AI]
@ c_notificationDrag
[AI] Ongoing drag/move event [AI]
void CalcLocalTransform(const Vector3 &p_posVec, const Vector3 &p_dirVec, const Vector3 &p_upVec, Matrix4 &p_outMatrix)
[AI] Computes a transformation matrix based on a position, direction, and up vector.