Camera Controls Overview
AI-BIM App uses an OrthoPerspectiveCamera that supports both perspective and orthographic projection modes. The camera provides intuitive controls for navigating 3D models. Reference: Camera setup at/src/main.ts:44
Basic Navigation
Orbit (Rotate)
Rotate the camera around your model to view it from different angles.Left Mouse Button
Click and hold the left mouse button, then drag to rotate the camera around the model center point.
Free Rotation
Move the mouse in any direction to orbit horizontally and vertically around the model.
Pan (Move)
Move the camera parallel to the view plane without rotating.Right Mouse Button or Middle Button
Click and hold the right mouse button (or middle mouse button), then drag to pan the view.
Zoom
Move the camera closer to or farther from the model.Camera Toolbar
Access advanced camera controls from the Selection tab in the floating toolbar. Reference: Camera controls at/src/components/Toolbars/Sections/Camera.ts:7
Fit Model to View
Automatically frame the entire model in the viewport.Camera Adjusts Automatically
The camera calculates the optimal position and zoom level to show all visible elements.
onFitModel function at /src/components/Toolbars/Sections/Camera.ts:7
Lock/Unlock Camera
Freeze camera movement to prevent accidental navigation changes.
Reference:
onLock function at /src/components/Toolbars/Sections/Camera.ts:13
Advanced Navigation Techniques
Focus on Selection
Zoom the camera to selected elements for detailed inspection.
Reference:
onFocusSelection function at /src/components/Toolbars/Sections/Selection.ts:126
Viewport Rest Threshold
The camera system includes intelligent rest detection:- When the camera stops moving for 0.25 seconds, it triggers rest events
- This optimizes rendering and streaming performance
- Tile loading is optimized during camera rest periods
/src/main.ts:90
Projection Modes
The camera supports two projection modes:Perspective Mode
- Objects farther away appear smaller (realistic view)
- Better for understanding spatial relationships
- Default mode for architectural visualization
Orthographic Mode
- Parallel projection with no perspective distortion
- Objects maintain size regardless of distance
- Ideal for measurements and technical drawings
Projection mode switching is currently implemented in the camera system but may need to be enabled in the UI. Check the Camera toolbar for a dropdown to switch modes.
Viewport Grid
The viewport includes a world grid to help with orientation:- Grid color: Dark gray (
#424242) - Primary grid size: 2 units
- Secondary grid size: 8 units
- Grid follows camera movement
/src/main.ts:46
Selection and Highlighting
The viewport includes an integrated highlighter system:Click to Select
Zoom to Selection
When zoomToSelection is enabled (default), clicking an element automatically adjusts the camera to focus on it. Reference: Highlighter setup at/src/main.ts:84
Performance Optimization
Culling System
AI-BIM App uses an automatic culling system that:- Hides objects outside the camera view
- Improves performance for large models
- Updates automatically during camera rest
/src/main.ts:87
Streaming for Large Models
For models loaded as BIM Tiles:- Elements stream in based on camera position
- Visible tiles load automatically
- Hidden elements unload to save memory
- 10-second threshold for tile visibility
/src/main.ts:77
Navigation Tips
Troubleshooting Navigation
Camera Won’t Move
- Check if the camera is locked (lock button shows in Camera toolbar)
- Ensure you’re clicking in the viewport, not on UI elements
- Try clicking Enable in the Camera section
Model Disappeared
- Use Fit Model to reset the camera view
- Check if elements are hidden (use Show All in Selection toolbar)
- Zoom out significantly - you might be inside the model
Navigation Feels Slow
- Large models may have performance constraints
- Close unnecessary browser tabs to free memory
- Consider using BIM Tiles for better streaming performance
Can’t Select Elements
- Ensure the highlighter is enabled (check Settings panel)
- Measurement tools may interfere - disable them in the Measurement tab
- Some fragments may not be selectable if they lack geometry
Keyboard Shortcuts
While most navigation is mouse-based, some useful shortcuts include:- Delete - Delete selected measurements (when measurement mode is active)
- Shift + Drag - Pan view with left mouse button
Next Steps
Now that you can navigate the 3D viewport:- Learn to use measurement tools
- Start querying with AI
- Explore data visualization