The MMGIS Interactive Mapping Tools system is a comprehensive plugin-based architecture providing users with 15 specialized geospatial analysis, measurement, drawing, and visualization tools. Each tool follows a unified lifecycle interface, enabling consistent integration, configuration, and user experience across diverse mapping functionalities for planetary science missions.
This specification documents all user-facing interactive tools (15 total), excluding deprecated tools in the _OLD directory and plugin-specific tools not in the public repository.
Each tool in the system follows a standardized plugin pattern that enables:
- Dynamic tool loading and registration
- Consistent lifecycle management (make/destroy)
- Configuration-driven behavior
- Independent or toolbar-integrated presentation
- State management and URL persistence
All tools implement the following interface contract:
{
height: Number, // Panel height in pixels (0 for variable)
width: Number, // Panel width in pixels
MMGISInterface: Object, // Interface with MMGIS core
make: function(), // Initialize and render tool
destroy: function(), // Clean up and remove tool
getUrlString: function() // Serialize tool state to URL
}ToolController Integration
The ToolController_ (src/essence/Basics/ToolController_/ToolController_.js) manages all tool plugins through:
- Tool Registration: Tools are loaded from
toolModulesandtoolConfigsexported from the build system - Lifecycle Management: Handles
make()anddestroy()calls based on user interaction - UI Positioning: Supports two presentation modes:
- Toolbar Tools: Integrated into left-hand expandable toolbar
- Separated Tools: Floating icons with independent panels (left/center/right justification)
- State Coordination: Ensures only one toolbar tool active at a time; separated tools can coexist
Each tool provides a configuration definition in configure/public/toolConfigs.json that includes:
- Metadata: name, description, icon, toolbar priority
- Variables: Runtime configuration options
- UI Config: Form fields for administrative configuration interface
- Expandable: Whether tool supports panel expansion/collapse
- Separated Tool: Whether tool lives outside main toolbar
Note: The Kinds system (src/essence/Tools/Kinds/Kinds.js) is a configuration plugin that defines layer interaction behaviors, not a user-facing tool. It specifies how layers respond to click events:
infokind: Opens Info Tool with feature propertieswaypointkind: Shows rover/vehicle overlays with rotationchemistry_toolkind: Activates Chemistry Tool for clicked featuredraw_toolkind: Enables Draw Tool editing for clicked feature
The Kinds system is extensible for custom layer interaction patterns but is not directly exposed to end users.
Location: src/essence/Tools/Animation/AnimationTool.js
Purpose: Create animated map sequences with custom time ranges and export options
Toolbar Priority: 1002
Expandable: Yes
- 4-Step Wizard Interface: Guides users through animation creation
- Select bounding box area for animation
- Define time range and interval
- Configure playback options (FPS, looping)
- Export as GIF, MP4, or PNG sequence
- Multiple Export Formats:
- GIF: Animated GIF using
gifshotlibrary - MP4: H.264 video using FFmpeg (via
@ffmpeg/ffmpeg) - PNG Sequence: Individual frame export as ZIP
- GIF: Animated GIF using
- Time-Enabled Layer Support: Automatically updates layers with time configuration
- Custom Frame Rates: 1-60 FPS playback
- Progress Tracking: Real-time rendering progress bar
Technology Stack:
- HTML2Canvas: Captures map canvas for each frame
- gifshot: Client-side GIF encoding
- @ffmpeg/ffmpeg: WebAssembly-based video encoding
- JSZip: PNG sequence packaging
Workflow:
- User draws bounding box on map
- Tool hides UI elements and zooms to bbox
- For each time step:
- Update TimeControl to target time
- Wait for layer rendering
- Capture canvas with HTML2Canvas
- Store frame in memory
- Encode frames to selected format
- Trigger browser download
Variables (from toolConfigs.json):
- None - tool is self-contained with UI-driven configuration
Runtime Configuration (UI-driven):
- Bounding Box: Interactive map selection
- Start Time: Date/time picker or Sol number
- End Time: Date/time picker or Sol number
- Time Interval: Step size (seconds, minutes, hours, days)
- Frame Rate: 1-60 FPS
- Loop: Enable/disable looping
- Export Format: GIF, MP4, or PNG sequence
- TimeControl: Drives time-enabled layer updates
- Map_: Canvas capture source
- Layers_: Ensures proper layer visibility during capture
- ToolController_: Manages tool visibility during rendering
- Large animations (100+ frames) consume significant memory
- MP4 encoding is CPU-intensive (uses Web Workers)
- GIF encoding limited to 256 colors
- Recommended max: 1920x1080 resolution, 10 second duration
Location: src/essence/Tools/Chemistry/ChemistryTool.js
Purpose: Display chemical composition charts from clicked point features
Toolbar Priority: (default)
Expandable: No
- Chemical Composition Charts: D3-based bar/pie charts showing element percentages
- Single & Multi-Mode Selection: Click single point or select multiple for comparison
- Custom Chart Library: Uses
chemistrychart.jsandchemistryplot.jsfor specialized visualization - Dataset Integration: Reads chemistry data from feature properties or linked datasets
Chart Types:
- Bar Chart: Element percentages as vertical bars
- Pie Chart: Proportional element distribution
- Scatter Plot: Multi-point comparison (multi-mode)
Data Sources:
- Feature properties with chemistry keys (e.g.,
SiO2,Fe2O3,Al2O3) - Linked CSV datasets via
properties.datasets - Remote chemistry data endpoints
Variables (from toolConfigs.json):
- None - chemistry data driven by layer configuration and feature properties
Expected Feature Properties:
{
"name": "Sample Site A",
"SiO2": 45.2,
"Fe2O3": 15.8,
"Al2O3": 10.3,
"MgO": 8.5,
// ... additional oxide percentages
}- Map_: Receives feature click events
- Layers_: Identifies chemistry-enabled layers via
kind: "chemistry_tool" - Info Tool: Can display chemistry charts inline with feature properties
- Planetary geology: Analyze rock/soil composition from rover instruments
- Mineralogy: Compare chemistry across multiple sample sites
- Temporal analysis: Track chemistry changes in time-enabled datasets
Location: src/essence/Tools/Curtain/CurtainTool.js
Purpose: Visualize Ground Penetrating Radar (GPR) subsurface data as vertical curtains
Toolbar Priority: (default)
Expandable: No
- Vertical Imagery Curtains: Display GPR radargrams aligned under terrain surface
- 3D Subsurface Visualization: Render radar data in Globe view beneath rover paths
- Sol/RMC Metadata Display: Show mission Sol number and Rover Motion Counter
- Vertical Exaggeration Controls: Adjust depth scale for emphasis
- Offset Controls: Fine-tune curtain positioning relative to surface
- "Keep On in 3D" Toggle: Persist curtain visibility when switching to Globe view
Technology Stack:
- OpenSeadragon: High-resolution imagery viewing (for 2D curtain inspection)
- Cesium: 3D curtain rendering beneath terrain
- Custom Shaders: Position radar imagery vertically in 3D space
Data Format:
- Input: Georeferenced radar imagery with depth metadata
- Positioning: Lat/lon path with depth extent
- Metadata: Sol number, RMC range, acquisition parameters
Variables (from toolConfigs.json):
withCredentials(boolean): Enable CORS credentials for remote imagery, default false
Layer Configuration:
Curtain data typically configured as vector layer with custom kind:
{
"name": "GPR Data Sol 015",
"type": "vector",
"url": "geodatasets:gpr_sol015",
"kind": "curtain",
"curtainImagery": "path/to/radargram.png",
"curtainDepth": 10,
"curtainMetadata": {
"sol": 15,
"rmc_start": 1000,
"rmc_end": 1500
}
}- Map_: Display curtain path as polyline
- Globe_: Render 3D curtain geometry
- Viewer_: High-resolution radargram inspection in Viewer panel
- Layers_: Manage curtain visibility per-layer
- Rover GPR data analysis: Visualize subsurface stratigraphy
- Ice detection: Identify subsurface ice layers in polar regions
- Hazard assessment: Detect buried rocks or voids along traverse
Location: src/essence/Tools/Draw/DrawTool.js
Purpose: Advanced collaborative vector drawing and annotation with comprehensive file management
Toolbar Priority: 1001
Expandable: Yes
Test Coverage: DrawTool.test.js
The Draw Tool is MMGIS's most complex tool, providing a comprehensive geospatial vector data creation, editing, and sharing platform. It enables mission teams to collaboratively create, annotate, and manage geographic features with real-time history tracking, advanced geometric operations, and flexible sharing controls.
The drawing system supports seven primary vector geometry types:
- Polygon Drawing - Multi-vertex polygon creation with clip-over/clip-under operations
- Circle Drawing - Radius-based circles with optional forced dimensions
- Rectangle Drawing - Axis-aligned bounding boxes
- Line Drawing - Multi-segment polylines with optional snapping
- Point Drawing - Georeferenced point features with customizable symbols
- Text Annotations - Positioned text labels with rich styling options
- Arrow Annotations - Directional indicators with customizable arrowhead geometry
The system organizes drawings into typed files called "intents" which categorize features by operational purpose:
- ROI (Region of Interest) - L1 Polygons for primary areas of scientific interest
- Campaign - L2 Polygons for mission campaign boundaries
- Campsite - L3 Polygons for operational staging areas
- Trail - Polyline features representing traverse paths
- Signpost - Point features for waypoints and markers
- Note - Standalone text annotations
- All (Map) - Generic geospatial features (polygons, lines, points)
- Master Files - Lead-controlled shared files per intent type
- Private (default) - Only the creator can view and edit
- Public Read-Only - Anyone can view, only owner can edit
- Public List-Edit - Owner designates specific users who can edit
- Public All-Edit - Anyone authenticated can edit
- Group Ownership - Files owned by user groups rather than individuals
- Master Files - System-managed shared files owned by the lead group
- Multiple users can view and edit the same file simultaneously
- File history tracks all edits with author attribution
- Changes propagate to all users viewing the file via WebSocket events
- Optimistic UI updates with server reconciliation
- By Folder - User-defined folders with elevated folder support for leads (syntax:
~@folder_namein description) - By Tag - Hashtag-based categorization (syntax:
#tagnamein description) - By Author - Grouped by file creator
- Alphabetical - A-Z sorted file names
- Ungrouped - Flat file list
- Text search across file names, authors, and descriptions
- Tag-based search using
#tagnamesyntax - Intent-based filtering (show only ROIs, campaigns, etc.)
- Visibility filters (on/off, public/private, owned)
- Multi-criteria advanced filter builder with AND/OR grouping
The backend provides advanced PostGIS-powered spatial operations:
- Clip Over - New geometry clips/removes overlapping portions of existing features
- Clip Under - New geometry is clipped to avoid overlapping existing features
- Both operations utilize recursive PostGIS
ST_DIFFERENCEwith buffering for precision
- Combines multiple selected features into a single unified geometry
ST_UNIONfor polygons with mitered buffering to prevent gapsST_LineMergefor connected line segments- Properties inherited from designated "prop_id" feature
- Divides features using a user-drawn line
ST_SPLIToperation against all selected feature geometries- Creates multiple new features from split results
- Preserves original feature properties on all split children
The feature implements a comprehensive temporal database architecture:
- Every add, edit, delete, merge, split, and clip operation recorded
- History entries stored with:
- Unique
history_idper file - Millisecond timestamp
- Action index (0=add, 1=edit, 2=delete, 3=undo, 5=clip-over, 6=merge, 7=clip-under, 8=split)
- Array of feature IDs active at that point in time
- Author username
- Unique
- Users can scrub through file history to any past timestamp
- Map visualization updates to show features as they existed at selected time
- "Undo to Time" operation reverts all changes after selected timestamp
- History UI displays chronological action list with author attribution
Rather than deleting features, the system implements soft-delete with temporal validity:
extant_start- Timestamp when feature was createdextant_end- Timestamp when feature was removed (NULL if still active)trimmed_start[]- Array of undo timestamps affecting this featuretrimmed_at[]- Array of timestamps when trims were appliedtrimmed_at_final- Most recent trim operation timestamp
The system supports JSON-based feature templates that enforce metadata schemas:
- Field Types: text, number, date, incrementer, dropdown, checkbox, textarea
- Auto-Incrementing Fields - Sequentially numbered features (e.g., SOL001, SOL002)
- Collision Detection - Prevents duplicate incrementer values
- Template Enforcement - Backend validates and auto-populates template fields
- Reusable Templates - Saved templates shared across files
- Template Designer UI - Visual template builder in file settings modal
- Syntax:
prefix#suffix(e.g.,SOL#becomesSOL001) - Scans all features in file to find used values
- Auto-assigns next available number
- Collision detection during edits prevents duplicates
- Manual value changes validated against existing features
- Draw Clipping - Over/Under/Off modes for new geometry clipping
- Draw Resolution - Auto-vertex insertion at specified pixel intervals
- Edit Snapping - Snap vertices to nearby features during editing
- Circle Radius - Force circles to specific meter radius
- Vertex Editing - Drag vertices to reshape geometries
- Style Editing - Color picker, opacity sliders, stroke width, fill patterns
- Property Editing - Key-value metadata editor with template validation
- Bulk Operations - Multi-select for merge, split, delete, copy operations
Specialized plugin for geologic mapping:
- Pattern fills (dots, lines, hashes) for geologic units
- FGDC-compliant line symbology (contacts, faults, boundaries)
- Color-coded stratigraphic units
- SVG-based pattern rendering
- GeoJSON - Native format with MMGIS metadata preservation
- KML - Google Earth compatible with timestamp support
- SHP (Shapefile) - ESRI format with .prj projection files
- Source coordinate system or converted to primary CRS
- Force template schema on export (strip non-template fields)
- Include/exclude metadata tables
- Batch export for multiple files
- GeoJSON file upload into new or existing files
- Automatic intent detection based on geometry types
- Property preservation and UUID assignment
- Bulk upload with drag-and-drop support
Master files implement a lead-controlled review process:
- One master file per intent type (ROI, Campaign, Campsite, Trail, Signpost)
- Owned by
mmgis-groupwith elevated permissions - Always public and visible in "Lead Maps" section
- Read-only for non-lead users
- Review workflow for lead approval of user submissions
- Users create features in personal files
- Lead users open Review modal from Master Files section
- Review UI displays all pending files for that intent
- Lead can preview features on map
- Lead approves (copy to master) or rejects submissions
- Approved features copied with metadata preservation
user_files {
id: SERIAL PRIMARY KEY
file_owner: VARCHAR(50) NOT NULL
file_owner_group: STRING[] -- Group ownership
file_name: VARCHAR(355) NOT NULL
file_description: VARCHAR(10000) -- Supports tags/folders via ~# ~@ ~^ syntax
is_master: BOOLEAN DEFAULT false
intent: ENUM('roi','campaign','campsite','trail','signpost','all')
public: ENUM('0','1') DEFAULT '0'
hidden: ENUM('0','1') DEFAULT '0'
template: JSON -- Feature template schema
publicity_type: VARCHAR(255) -- 'read_only'|'list_edit'|'all_edit'
public_editors: TEXT[] -- Usernames with edit access
created_on: TIMESTAMP NOT NULL
updated_on: TIMESTAMP NOT NULL
}user_features {
id: SERIAL PRIMARY KEY
file_id: INTEGER REFERENCES user_files(id)
level: INTEGER -- Z-order for rendering
intent: ENUM('roi','campaign','campsite','trail','signpost','polygon','line','point','text','arrow')
properties: JSON -- Feature metadata including 'uuid', 'style', custom fields
geom: GEOMETRY(GEOMETRY,4326) -- PostGIS spatial column
extant_start: BIGINT -- Creation timestamp
extant_end: BIGINT -- Deletion timestamp, NULL if active
trimmed_start: BIGINT[] -- Array of undo timestamps
trimmed_at: STRING[] -- Array of trim application timestamps
trimmed_at_final: BIGINT -- Most recent trim timestamp
}file_histories {
id: SERIAL PRIMARY KEY
file_id: INTEGER REFERENCES user_files(id)
history_id: INTEGER -- Sequential per file
time: BIGINT -- Epoch milliseconds
action_index: INTEGER -- 0=add, 1=edit, 2=delete, 3=undo, 5=clip-over, 6=merge, 7=clip-under, 8=split
history: INT[] -- Array of feature IDs active at this point
author: VARCHAR(255) -- Username who performed action
}Every feature stores a standardized properties object:
{
uuid: "generated-uuid-v4", // Unique identifier
_: { // MMGIS metadata
id: 123, // Feature database ID
file_id: 45, // Parent file ID
intent: "roi" // Feature intent
},
style: { // Rendering style
color: "rgb(255,255,255)",
fillColor: "rgb(0,0,0)",
opacity: 1,
fillOpacity: 0.4,
weight: 2,
radius: 4, // For points/circles
geologic: { // Optional geologic symbology
type: "pattern",
tag: "601",
color: "K",
size: 1,
fillColor: "#fff",
fillOpacity: 1
}
},
name: "User-defined name",
description: "User notes",
// ...additional template or custom fields
}-
POST /add - Create a new feature in a file
- Body:
{ file_id, geometry, properties, intent, clip: 'over'|'under'|null } - Returns:
{ status, message, body: { id, intent } }
- Body:
-
POST /edit - Modify an existing feature
- Body:
{ file_id, feature_id, geometry, properties, intent } - Returns:
{ status, message, body: { id, uuid, intent } }
- Body:
-
POST /remove - Soft-delete a feature
- Body:
{ file_id, id } - Returns:
{ status, message }
- Body:
-
POST /undo - Revert file to a past timestamp
- Body:
{ file_id, undo_time } - Returns:
{ status, message }
- Body:
-
POST /merge - Combine multiple features
- Body:
{ file_id, prop_id, ids: [id1, id2, ...] } - Returns:
{ status, message, body: { ids: [new_ids] } }
- Body:
-
POST /split - Divide features with a line
- Body:
{ file_id, split: line_geojson, ids: [id1, id2, ...] } - Returns:
{ status, message, body: { ids: [new_ids] } }
- Body:
- POST /get - Retrieve user's files list
- POST /getfile - Retrieve specific file with features
- POST /make - Create a new file
- POST /change - Update file metadata
- POST /remove - Delete a file and all its features
- POST /gethistory - Retrieve file's edit history
- POST /modifykeyword - Rename or remove folder/tag
- POST /on - Publish selected features to "Latest Map"
- POST /off - Unpublish features from "Latest Map"
Component Structure:
DrawTool.js // Main tool controller
├── DrawTool_Drawing.js // Drawing mode UI and Leaflet.draw integration
├── DrawTool_Editing.js // Feature editing and property modification
├── DrawTool_Files.js // File list, filtering, and file operations
├── DrawTool_History.js // History timeline and undo interface
├── DrawTool_Shapes.js // Feature list, selection, and shape management
├── DrawTool_Publish.js // Publishing and master file review
├── DrawTool_FileModal.js // File creation/upload modal
└── DrawTool_Templater.js // Template designer and enforcement
Leaflet Integration:
L.Draw.Polygon- Extended for clip-over/under supportL.Draw.Circle- Modified for forced radius modeL.Draw.Rectangle- Standard Leaflet.draw implementationL.Draw.Polyline- Extended with auto-vertex resolutionL.Draw.Marker- Symbol-based point placementL.Edit.Poly- Vertex editing with optional snapping
Cesium Integration:
Globe_.litho.addLayer('clamped', {
name: 'camptool_DrawTool_' + fileId,
on: true,
geojson: normalizedFeatures,
opacity: 1,
style: { letPropertiesStyleOverride: true }
})Variables (from toolConfigs.json):
intents(object): Custom intent type names/aliasesleadsCanEditFileInfo(boolean): Allow leads to edit any file metadatamasterFileIds(array): IDs of master files per intenttemplates(object): Pre-defined property templates
- Map_: Drawing canvas, feature rendering
- Globe_: 3D feature visualization
- Layers_: Published features as vector layers
- Authentication: User ownership and permissions
- WebSocket: Real-time file synchronization
- Configure API: File and feature CRUD operations
- Files with 1000+ features may experience rendering lag
- History table grows unbounded (no archival strategy)
- Geometric operations (merge, split, clip) are computationally expensive
- Real-time sync triggers full file refetch (not operational transforms)
- Real-Time Sync - WebSocket events trigger refetch, not operational transforms
- Conflict Resolution - Last-write-wins, no CRDT-style merging
- Large File Performance - No pagination for files with 1000+ features
- Undo Granularity - Undo reverts entire file to timestamp, not single operation
Location: src/essence/Tools/Identifier/IdentifierTool.js
Purpose: Real-time pixel value querying from raster datasets via mouse-over
Toolbar Priority: 1
Separated Tool: Yes (persistent floating panel)
- Real-Time Pixel Queries: Display raster pixel values on mouse-over
- Multi-Band Raster Support: Query and display all bands from GeoTIFF
- Configurable Significant Figures: Control decimal precision per layer
- Unit Display & Scale Factors: Convert raw values to meaningful units
- Time-Enabled Datasets: URL template substitution for time-varying rasters
- Legend-Based Color Matching: Match pixel colors to legend for non-queryable layers
- Layer-Specific Configuration: Per-layer UUID mapping for query parameters
Technology Stack:
- Backend GDAL: Raster pixel extraction via
/api/gdal/rasterendpoint - Frontend Debouncing: Throttle mousemove events to reduce query load
- Cache Layer: Cache recent queries for performance
Query Workflow:
- User hovers over map location
- Tool identifies active raster layers with Identifier configuration
- Constructs GDAL query with lat/lon and layer URL
- Backend extracts pixel values for all bands
- Frontend formats and displays values with units
Variables (from toolConfigs.json): Per-layer configuration object mapping layer UUIDs to query parameters:
{
"layer-uuid-1": {
"url": "path/to/raster.tif", // GeoTIFF file path
"bands": 3, // Number of bands
"sigfigs": 2, // Decimal places
"unit": "meters", // Unit label
"scalefactor": 1.0, // Value multiplier
"timeFormat": "%Y-%m-%dT%H:%M:%SZ" // Time URL format
}
}Layer Configuration Fields:
url(string): Path to GeoTIFF raster filebands(number): Number of bands to query (1-N)sigfigs(number): Significant figures for display, default 2unit(string): Unit label (e.g., "meters", "°C", "mGal")scalefactor(number): Multiply raw pixel value by this factortimeFormat(string): strftime format string for time-enabled layers
- Map_: Mousemove event listener
- Layers_: Identify active raster layers
- GDAL Backend: Pixel value extraction
- TimeControl: Time-enabled URL substitution
- DEM elevation queries: Display terrain elevation under cursor
- Temperature mapping: Show surface temperature from thermal imagery
- Spectral analysis: Query multi-band spectral reflectance data
- Gravity/magnetic: Display geophysical measurements
- Queries debounced to 100ms to reduce server load
- Large rasters (>10GB) may have slow query response
- Cache layer stores last 50 queries for instant re-display
Location: src/essence/Tools/Info/InfoTool.js
Purpose: Display GeoJSON properties of clicked features
Toolbar Priority: 3
Expandable: Yes
- JSON Property Display: Show all feature properties in formatted JSON
- Feature Filtering: Text search to filter displayed properties
- Hide/Show Feature Visibility: Toggle feature rendering on map
- Copy to Clipboard: Export feature as GeoJSON
- Locate Feature: Pan/zoom map to feature extent
- Navigate Overlapping Features: Dropdown for multi-feature selection at click point
- Hidden Properties Toggle: Show/hide properties starting with
_ - Alphabetical Sorting: Option to sort properties A-Z
Event Flow:
- User clicks feature on map
- Map_ emits feature click event
- Info Tool receives feature data
- Tool formats properties as JSON with syntax highlighting
- Displays in expandable panel
Multi-Feature Handling:
- When multiple features at click point, dropdown shows all features
- User selects desired feature from list
- Info panel updates to show selected feature properties
Variables (from toolConfigs.json):
sortAlphabetically(boolean): Sort properties alphabetically, default false
- Map_: Feature click events
- Globe_: 3D feature click events
- Layers_: Feature visibility management
- Kinds System: Respects layer
kindto control Info Tool activation
Property Formatting:
- Nested objects displayed with indentation
- Arrays shown with element count
- Long strings truncated with "Show More" button
- Coordinates displayed with precision controls
Action Buttons:
- Copy: Copy feature GeoJSON to clipboard
- Locate: Zoom map to feature bounds
- Hide/Show: Toggle feature visibility
- Filter: Text search across property keys/values
- Feature inspection: View metadata for clicked science targets
- Quality control: Verify feature properties match expected schema
- Data exploration: Browse feature attributes without external tools
Location: src/essence/Tools/Isochrone/IsochroneTool.js
Purpose: Terrain-aware traversability and travel time analysis
Toolbar Priority: 10
Expandable: No
- Cost-Based Traversability Modeling: Calculate reachable areas within cost budget
- Multiple Cost Models:
- Traverse Time: Time-based accessibility from start point
- Isodistance: Distance-based reachability
- Custom Models: Pluggable cost functions
- Path Visualization: Display cost gradients with color ramps
- Hover for Least-Cost Path: Show optimal path from start point to hover location
- Multiple Data Inputs: DEM, slope, obstacles, cost, shade tilesets
- Configurable Data Sources: Per-zoom-level tile URLs
- Real-Time Computation: Client-side tile-based processing
Technology Stack:
- Tile-Based Algorithm: Dijkstra's algorithm on tile grid
- Web Workers: Offload computation to background threads
- Multiple Tileset Sources: DEM, slope, obstacle, cost, shade
Key Files:
IsochroneTool_Manager.js- Manages multiple isochrone instancesIsochroneTool_Query.js- Data fetching from tile sourcesIsochroneTool_Algorithm.js- Cost computation algorithms
Computation Workflow:
- User places start point on map
- Tool fetches relevant tiles (DEM, slope, cost, etc.) for viewport
- Web Worker constructs graph with edge costs from tile data
- Runs Dijkstra's algorithm to find all reachable cells within budget
- Renders isochrone contours as colored overlay
- On hover, backtraces least-cost path to start
Variables (from toolConfigs.json):
Data Sources (array of tileset objects):
{
"dem": "path/to/dem/{z}/{x}/{y}.tif",
"data": [
{
"name": "High Res DEM",
"demtileurl": "Missions/Mars/DEMs/HighRes/{z}/{x}/{y}.1bto4b",
"minZoom": 10,
"maxZoom": 18,
"resolution": 0.5
},
{
"name": "Slope",
"demtileurl": "Missions/Mars/Slope/{z}/{x}/{y}.1bto4b",
"minZoom": 10,
"maxZoom": 18
},
{
"name": "Obstacle",
"demtileurl": "Missions/Mars/Obstacles/{z}/{x}/{y}.1bto4b",
"minZoom": 10,
"maxZoom": 18
}
]
}Cost Model Configuration:
- Enabled Models: Array of active cost model names
- Seam Interpolation: Smoothing across tile boundaries
- Cost Functions: Custom JavaScript functions for cost calculation
- Map_: Click for start point, hover for path display
- Layers_: Overlay rendering for isochrone zones
- DEM Sources: Multiple tileset queries
- Web Workers: Background computation
- Rover traverse planning: Determine reachable area within energy budget
- Emergency egress: Find accessible safe zones within time limit
- Communication range: Calculate line-of-sight visibility zones
- Resource accessibility: Identify areas reachable for sampling
- Tile-based approach limits computation to visible/cached tiles
- Web Workers prevent UI blocking during long computations
- Seam interpolation can introduce small artifacts at tile edges
- High-resolution DEMs (>1m/pixel) significantly increase compute time
Location: src/essence/Tools/Layers/LayersTool.js
Purpose: Hierarchical layer management and visibility control
Toolbar Priority: 1
Expandable: Yes
- Hierarchical Layer Organization: Tree-based structure with header/sublayer grouping
- Toggle Layers On/Off: Checkbox visibility controls
- Opacity Sliders: Per-layer opacity adjustment (0-100%)
- Search Layers: Text search by name or tags (
#tagsyntax) - Filter by Layer Type: Show only vector, tile, vectortile, query, data, or model layers
- Show/Hide Off Layers Toggle: Collapse inactive layers for cleaner UI
- Layer Info Modal: Display layer metadata (CRS, bounds, data source)
- Download Layers: Export vector layers as GeoJSON, KML, or Shapefile
- Feature Filtering: SQL-like query builder for vector layer filtering
- Data Shader Controls: Adjust colormap and value ranges for Data layers
- Colormap Selection: Choose from scientific colormaps for Image/Data layers
- Sortable Layer Order: Drag-and-drop to change z-index rendering order
Technology Stack:
- jQuery UI: Drag-and-drop layer reordering
- D3: DOM manipulation and data binding
- SortableJS: Layer order management
Component Structure:
- Layer tree renderer with recursive header/sublayer expansion
- Search filter with debounced text input
- Layer type filter with multi-select checkboxes
- Feature filter modal with query builder interface
- Data shader control panel with sliders and dropdowns
Variables (from toolConfigs.json):
expanded(boolean): Whether layer groups default to expanded state, default false
- Layers_: Direct interface to layer visibility, opacity, and configuration
- Map_: Layer z-index reordering
- Globe_: Synchronized layer visibility in 3D
- LegendTool: Update legend when layers change
- TimeUI: Display time controls for time-enabled layers
- DataShaders: Dynamic colormap and range adjustment for Data layers
Query Builder:
- Field selector (property name)
- Operator selector (=, !=, <, >, <=, >=, LIKE, IN)
- Value input (text, number, dropdown)
- AND/OR logic for multiple conditions
- SQL query preview
- Apply/Reset buttons
Example Filter:
SELECT * FROM features
WHERE temperature > 300
AND sample_type IN ('soil', 'rock')
AND name LIKE '%Site A%'Colormap Selection:
- Dropdown of scientific colormaps (viridis, plasma, turbo, etc.)
- Live preview of colormap gradient
- Apply to Data or Image layers
Value Range Adjustment:
- Min/max sliders for data value range
- Viewport-adaptive or fixed range modes
- NoData value toggle
Export Formats:
- GeoJSON: Native format with all properties
- KML: Google Earth compatible
- Shapefile: ESRI format with .prj, .shp, .shx, .dbf files
Export Configuration:
- Choose coordinate system (layer CRS or project CRS)
- Include/exclude hidden properties
- File naming conventions
- Mission operations: Toggle Sol-specific layers on/off
- Data exploration: Search for layers by mission phase tags
- Quality control: Filter features by validation status
- Export: Download science target layers for external analysis
Location: src/essence/Tools/Legend/LegendTool.js
Purpose: Display map legend for active layers with symbology
Toolbar Priority: 2
Separated Tool: Yes (left or right justification)
- Auto-Generate Legends: Create legends from layer configuration
- CSV Legend Files: Load external legend definitions
- JSON Legend Arrays: Define legends in layer Raw Variables
- Gradient Scales: Display continuous data ranges with color ramps
- Discrete Symbology: Show categorical symbols with labels
- Header Layer Display: Option to include header layer names
- COG Colormap Legends: Auto-generate legends from Cloud Optimized GeoTIFF colormaps
- Layer-Synchronized Visibility: Show/hide legend items based on layer state
- Collapsible Legend Items: Expand/collapse individual legend sections
Legend Sources (priority order):
- CSV File:
layer.legendproperty pointing to CSV file - JSON Array:
layer.Raw Variables.legendarray - Auto-Generated: From layer styling configuration
- COG Colormap: TiTiler colormap metadata
Legend Format:
CSV Legend:
value,color,label
0,#0000ff,Ice
1,#00ff00,Vegetation
2,#ffff00,Sand
3,#ff0000,RockJSON Legend:
{
"legend": [
{"value": 0, "color": "#0000ff", "label": "Ice"},
{"value": 1, "color": "#00ff00", "label": "Vegetation"},
{"value": 2, "color": "#ffff00", "label": "Sand"},
{"value": 3, "color": "#ff0000", "label": "Rock"}
]
}Variables (from toolConfigs.json):
displayOnStart(boolean): Auto-display legend on load, default falsejustification(string): Panel placement -"left"or"right", default "left"showHeadersInLegend(boolean): Include header layer names, default false
- Layers_: Synchronize legend visibility with layer state
- LayersTool: Update legend when layers toggled
- Data Layers: Read colormap configuration
- Image Layers: Read COG colormap metadata
Gradient Legend:
- Vertical color bar with min/max labels
- Smooth color transitions
- Unit label at top
Categorical Legend:
- Symbol/color swatch with text label
- One row per category
- Optional group headers
Pattern Legend (Geologic):
- SVG pattern swatch with label
- FGDC geologic unit symbols
- Basemap understanding: Show elevation ranges for DEM layers
- Science data: Display temperature or spectr
al reflectance scales
- Geologic mapping: Show stratigraphic unit symbology
- Vector styling: Display category color codes
Location: src/essence/Tools/Measure/MeasureTool.js
Purpose: Distance measurement and elevation profiling
Toolbar Priority: 5
Expandable: No
- Three Measurement Modes:
- Segment: Measure individual line segments
- Continuous: Cumulative distance along path
- Continuous Color: Color-coded elevation profile
- DEM-Based Elevation Profiling: Interactive elevation charts from DEM data
- Multi-DEM Support: Layer-specific DEM associations
- Line-of-Sight (LOS) Analysis: Visibility analysis with configurable observer/target heights
- Distance Units: Meters, kilometers, miles, feet
- Interactive Profile Charts: Chart.js with React for hover details
- Works in Map, Globe, and Viewer: Measurements across all rendering modes
Technology Stack:
- React: UI components for profile charts
- Chart.js: Interactive elevation profile visualization
- metrics-graphics: Alternative charting library
- GDAL Backend: DEM querying via
/api/gdal/rasterendpoint - Leaflet Layer: Measurement geometry visualization
Key Files:
MeasureTool.js- Main tool controllerMeasureComponents.js- React profile chart components
Workflow:
- User clicks points on map to define measurement path
- Tool queries DEM at each point for elevation
- Calculates distances between points accounting for elevation
- Renders interactive profile chart with distance vs elevation
- LOS mode draws visibility line considering terrain obstruction
Variables (from toolConfigs.json):
dem(string): Primary DEM path for elevation querieslayerDems(object): Object mapping layer names to DEM pathsonlyShowDemIfLayerOn(boolean): Filter DEMs by layer visibility, default falsedefaultMode(string): Starting measurement mode -"segment","continuous", or"continuous_color", default "segment"
Layer-Specific DEM Configuration:
{
"layerDems": {
"High Res Basemap": "Missions/Mars/DEMs/HighRes/dem.tif",
"Global Context": "Missions/Mars/DEMs/Global/dem.tif"
}
}- Map_: Click events for point placement, polyline rendering
- Globe_: 3D measurement support
- Viewer_: Image-space measurements (pixel coordinates)
- GDAL Backend: Elevation queries
- Layers_: DEM visibility filtering
Distance Calculation:
- Great circle distance for long distances
- Elevation-adjusted distance (slant distance)
- Cumulative distance display
Elevation Profile:
- Chart displays distance (X-axis) vs elevation (Y-axis)
- Hover shows exact values at any point
- Color-coded by elevation or slope
- Exportable as PNG or CSV
Line-of-Sight:
- Observer height above terrain
- Target height above terrain
- Visibility determination accounting for terrain obstruction
- Green = visible, Red = obstructed
- Rover traverse planning: Measure path distance and elevation gain
- Communication range: Determine line-of-sight between lander and rover
- Slope analysis: Calculate maximum slope along proposed path
- Energy estimation: Estimate power requirements based on terrain profile
- DEM queries are rate-limited to prevent server overload
- Long paths (>100 points) may have slower profile generation
- High-resolution DEMs (>1m/pixel) increase query time
Location: src/essence/Tools/Shade/ShadeTool.js
Purpose: Sun and orbiter shadow/illumination mapping with SPICE integration
Toolbar Priority: 102
Expandable: No
- SPICE-Based Position Calculation: Accurate spacecraft/body positions from SPICE kernels
- Shadow Casting: Visualize shadows from Sun or orbiting spacecraft
- Line-of-Sight Visibility: Determine visibility to celestial bodies or orbiters
- Observer Time Conversion: Convert between spacecraft time and UTC
- Multiple Source Entities: Sun, orbiters, moons, other bodies
- Height-Above-Surface Parameter: Adjust observer elevation
- Dynamic Tile Generation: Real-time visibility map from DEM data
- Color-Coded Visibility: Green = visible, Red = shadowed
Technology Stack:
- SPICE Toolkit: NASA's navigation and ancillary information system
- Python Backend Scripts:
ll2aerll.py- Lat/lon to azimuth/elevation conversionchronos.py- Time conversion (UTC ↔ spacecraft time)
- DEM Tileset Processing: Visibility calculation from elevation data
Key Files:
ShadeTool.js- Main tool controllerShadeTool_Manager.js- Manages multiple shade instancesShadeTool_Algorithm.js- Shading computation algorithms
Workflow:
- User selects source entity (Sun, orbiter) and time
- Tool queries SPICE backend for entity position (azimuth, elevation)
- For each DEM tile pixel:
- Calculate line-of-sight vector to source
- Ray-trace against terrain to detect obstruction
- Color pixel based on visibility (green/red)
- Render colored overlay on map
Variables (from toolConfigs.json):
DEM Configuration:
{
"dem": "path/to/dem.tif",
"data": [
{
"name": "High Res DEM",
"demtileurl": "Missions/Mars/DEMs/HighRes/{z}/{x}/{y}.1bto4b",
"minZoom": 10,
"maxZoom": 18,
"resolution": 0.5
}
]
}SPICE Source Configuration:
{
"sources": [
{
"name": "Sun",
"spice_id": "10",
"color": "#ffff00"
},
{
"name": "Mars Reconnaissance Orbiter",
"spice_id": "-74",
"color": "#00ff00"
}
]
}Observer Configuration:
{
"observers": [
{
"name": "Perseverance Rover",
"spice_id": "-168",
"time_system": "LMST"
}
]
}Other Variables:
defaultHeight(number): Default observer height above surface in meters, default 0observerTimePlaceholder(string): Placeholder text for observer time inpututcTimeFormat(string): strftime format for UTC time display, default"%Y-%m-%dT%H:%M:%SZ"
- SPICE Backend: Position and time conversion queries
- DEM Sources: Elevation data for shadow calculation
- Map_: Overlay rendering for visibility maps
- TimeControl: Time-driven shading updates
SPICE Kernels Required:
Located in /private/api/spice/kernels:
- SPK (Spacecraft and Planet Kernel): Ephemeris data
- CK (C-Kernel): Spacecraft attitude
- LSK (Leapseconds Kernel): Time conversions
- PCK (Planetary Constants Kernel): Body physical parameters
- FK (Frame Kernel): Reference frame definitions
Backend APIs:
/api/spice/ll2aerll: Convert lat/lon to azimuth/elevation for source body/api/spice/chronos: Convert time between UTC and spacecraft time systems
- Solar panel planning: Determine sunlight availability for power generation
- Communication windows: Calculate visibility to orbiters for data relay
- Thermal analysis: Identify shadowed regions for temperature prediction
- Landing site selection: Assess illumination conditions for proposed sites
- SPICE queries are computationally expensive (cache results)
- High-resolution DEMs significantly increase ray-tracing time
- Multiple source entities multiply computation cost
- Recommend limiting to single source entity for real-time updates
Location: src/essence/Tools/Sites/SitesTool.js
Purpose: Quick navigation to preset map locations
Toolbar Priority: 4
Expandable: No
- Button Bar Interface: Radio buttons for rapid site selection
- Preset Views: Pre-configured lat/lon/zoom combinations
- Header Layer Toggling: Auto-toggle associated header layers by site code
- Single-Click Navigation: Instant map pan/zoom to site
Technology Stack:
- Simple button bar with radio button styling
- Direct Map_ integration for view changes
- Layer_ integration for header layer toggling
Workflow:
- User clicks site button
- Tool calls
Map_.setView(lat, lng, zoom) - If site has
code, tool toggles header layers matching that code - Radio button highlights active site
Variables (from toolConfigs.json):
sites(array): Array of site configuration objects
Site Object Structure:
{
"sites": [
{
"name": "Landing Site",
"code": "LS",
"lat": 18.445,
"lng": 77.451,
"zoom": 14
},
{
"name": "Sample Cache",
"code": "SC",
"lat": 18.450,
"lng": 77.455,
"zoom": 16
}
]
}Site Properties:
name(string, required): Display name for buttoncode(string, optional): Site code matching header layer codeslat(number, required): Latitude in degreeslng(number, required): Longitude in degreeszoom(number, required): Target zoom level
- Map_: View control (pan/zoom)
- Layers_: Header layer visibility toggling
- URL State: Site selection persisted in URL parameters
Header layers can have a code property. When a site with matching code is selected:
- All header layers with that code are toggled on
- Other header layers may be toggled off (configurable)
- Sublayers within header inherit visibility
Example:
// Site configuration
{"name": "Sol 015", "code": "SOL015", "lat": 18.445, "lng": 77.451, "zoom": 14}
// Matching header layer
{
"name": "Sol 015 Imagery",
"type": "header",
"code": "SOL015",
"sublayers": [...]
}- Mission operations: Quickly navigate to Sols or mission phases
- Region of interest: Jump to pre-defined science target areas
- Landing site analysis: Compare multiple candidate sites
- Traverse waypoints: Navigate to planned rover stops
Location: src/essence/Tools/Viewshed/ViewshedTool.js
Purpose: Real-time user-generated viewsheds (line-of-sight visibility analysis)
Toolbar Priority: 101
Expandable: No
- Dynamic Viewshed Generation: Real-time visibility analysis from observer points
- Camera Presets: Pre-configured height, azimuth FOV, elevation FOV settings
- Multiple Simultaneous Viewsheds: Create and manage multiple viewshed overlays
- Planetary Curvature Consideration: Optional curvature calculation for large viewsheds
- Color-Coded Visibility Zones: Green = visible, Red = obstructed, Yellow = edge
- Observer Marker & Camera Wedge: Visualize observer location and field-of-view
- DEM Tile-Based Computation: Efficient processing of elevation data
Technology Stack:
- Ray-Tracing Algorithm: Cast rays from observer to all visible cells
- DEM Tileset Processing: Load relevant elevation tiles for computation
- Canvas Overlay: Render visibility map as colored overlay
Key Files:
ViewshedTool.js- Main tool controllerViewshedTool_Manager.js- Manages multiple viewshed instancesViewshedTool_Algorithm.js- Visibility computation algorithms
Workflow:
- User places observer point on map
- User configures camera parameters (height, FOV, orientation)
- Tool loads DEM tiles covering viewshed area
- For each cell within max range:
- Calculate line-of-sight from observer to cell
- Ray-trace against terrain to detect obstruction
- Color cell based on visibility
- Render overlay with camera wedge visualization
Variables (from toolConfigs.json):
DEM Tileset Configuration:
{
"data": [
{
"name": "High Res DEM",
"demtileurl": "Missions/Mars/DEMs/HighRes/{z}/{x}/{y}.1bto4b",
"minZoom": 10,
"maxZoom": 18,
"resolution": 0.5
}
]
}Camera Presets:
{
"cameraPresets": [
{
"name": "Mastcam",
"height": 2.0,
"azimuthCenter": 0,
"azimuthFOV": 90,
"elevationCenter": 0,
"elevationFOV": 60
},
{
"name": "Navcam",
"height": 1.5,
"azimuthCenter": 0,
"azimuthFOV": 120,
"elevationCenter": -10,
"elevationFOV": 45
}
]
}Other Variables:
curvature(boolean): Enable planetary curvature calculations, default falsedefaultObserverHeight(number): Default observer height in meters, default 2.0defaultTargetHeight(number): Default target height in meters, default 0.0
- Map_: Observer placement, overlay rendering
- DEM Sources: Elevation data for visibility calculation
- Camera Controls: Azimuth/elevation sliders, FOV inputs
Observer Parameters:
- Height: Observer elevation above terrain (meters)
- Azimuth Center: Horizontal direction center (degrees, 0 = North)
- Azimuth FOV: Horizontal field-of-view (degrees)
- Elevation Center: Vertical direction center (degrees, 0 = horizon)
- Elevation FOV: Vertical field-of-view (degrees)
- Max Range: Maximum visibility distance (meters)
Visibility Calculation:
- Green: Cell is visible from observer
- Red: Cell is obstructed by terrain
- Yellow: Cell is at edge of FOV
- Transparent: Cell outside FOV or max range
- Camera planning: Determine what's visible from rover camera positions
- Site reconnaissance: Assess what can be observed from proposed locations
- Communication analysis: Identify locations with line-of-sight to lander
- Hazard assessment: Detect blind spots where obstacles are hidden
- Viewshed computation scales with FOV and max range
- High-resolution DEMs increase computation time
- Multiple simultaneous viewsheds multiply processing cost
- Curvature calculations add 20-30% overhead
- Interface Creation: Tool creates
interfaceWithMMGIS()to manage communication with core - DOM Setup: Injects markup into designated container:
- Toolbar tools:
#toolPanel - Separated tools:
#toolContentSeparated_{name}
- Toolbar tools:
- Event Binding: Attaches event listeners for user interactions
- State Restoration: Parses URL parameters to restore previous state
- Map Integration: Adds map layers, event handlers, or overlays as needed
- Tools respond to user interactions (clicks, inputs, drags)
- Update their UI and map visualizations
- Communicate with backend APIs for data processing
- Emit events for state changes (e.g.,
toolChange,toggleSeparatedTool)
- Event Unbinding: Removes all event listeners
- Map Cleanup: Removes layers, overlays, and event handlers from map
- DOM Removal: Clears tool UI from panel
- Interface Separation: Calls
separateFromMMGIS()to fully disconnect
Each tool implements getUrlString() to serialize its state to URL parameters, enabling:
- Bookmarkable tool configurations
- Session restoration on page reload
- Sharing of specific tool states
Tools interact with the core Map_ system (src/essence/Basics/Map_/Map_.js) to:
- Add/remove Leaflet layers
- Register click/mousemove/mouseout handlers
- Pan/zoom the map programmatically
- Access map bounds and projection
3D-enabled tools (Measure, Draw, Identifier, Viewshed, Shade, Curtain) integrate with Globe_ (src/essence/Basics/Globe_/Globe_.js) for:
- 3D feature rendering
- Globe click/hover events
- Camera control
- Terrain-clamped geometry
Tools supporting image-based views (Measure, Curtain) integrate with Viewer_ (src/essence/Basics/Viewer_/Viewer_.js) for:
- Coordinate transformation
- Image click events
- Overlay rendering
- OpenSeadragon integration
All tools respect the layer system managed by L_ (src/essence/Basics/Layers_/Layers_.js):
- Check layer visibility states
- React to layer toggle events
- Filter tool behavior by active layers
Tools with user-owned data (Draw) integrate with the authentication system:
- Check login state
- Enforce ownership and permissions
- Display user-specific data
Many tools require backend services:
- DEM querying for elevation data (Measure, Identifier, Viewshed, Shade, Isochrone)
- Raster pixel value extraction (Identifier)
- Tile serving (Viewshed, Shade, Isochrone)
- Draw file CRUD operations (
/api/files) - File sharing and permissions
- History tracking (
/api/files/gethistory)
- Spacecraft position calculation (Shade) (
/api/spice/ll2aerll) - Time conversion (Shade) (
/api/spice/chronos)
The administrative configuration interface (configure/public/) dynamically generates forms from each tool's configuration in toolConfigs.json:
Field Types:
- text, number, textarea: Simple inputs
- checkbox, dropdown: Boolean and enumerated choices
- textarray: Comma-separated lists
- objectarray: Structured arrays with nested fields
Validation:
- Min/max constraints
- Required fields
- Regex patterns
- Step sizes
Tools processing large spatial datasets (Viewshed, Shade, Isochrone) use tiled approaches to:
- Limit memory consumption
- Enable progressive rendering
- Support multiple zoom levels
Where possible, tools perform client-side computation to:
- Reduce server load
- Provide immediate feedback
- Work offline (partially)
Tools are loaded on-demand rather than at application startup to:
- Reduce initial bundle size
- Improve page load time
- Load only needed dependencies
New tools can be added by:
- Creating a tool directory under
src/essence/Tools/{ToolName}/ - Implementing the tool interface in
{ToolName}Tool.js - Defining configuration in
configure/public/toolConfigs.json - Registering the tool in
src/pre/tools.js
Some tools (notably Draw) support their own plugin systems for extended functionality:
- Draw supports Geologic and Set Operations plugins
- Plugins extend core tool capabilities without modifying base code
All tools fully support modern desktop browsers:
- Chrome 90+
- Firefox 88+
- Safari 14+
- Edge 90+
Tools adapt to mobile:
- Toolbar tools switch to horizontal icon layout
- Touch event support
- Responsive panel sizing
- Some separated tools hidden on mobile for UI clarity
Tools handle both input methods:
- Click/tap equivalence
- Hover alternatives on touch devices (long-press)
- Multi-touch gestures where appropriate (pinch/zoom)
Tools with user-owned data (Draw) require authentication:
- Display "Please log in" state when not authenticated
- Enforce ownership on file modifications
- Validate permissions server-side
All tools validate user input:
- Numeric ranges (elevation, distances, zoom levels)
- String lengths (file names, descriptions)
- File size limits (imports, uploads)
- Coordinate bounds (lat/lon validation)
Tools properly escape user-generated content:
- Feature properties in Info tool (HTML escaping)
- Draw file names and descriptions (sanitization)
- Template field values (input validation)
The Draw tool includes comprehensive unit tests (DrawTool.test.js) demonstrating the pattern:
- Test tool initialization
- Test state management
- Test file operations
- Test validation logic
Tools should be tested for:
- ToolController integration (lifecycle)
- Map/Globe/Viewer integration (rendering)
- Backend API integration (data operations)
- URL state persistence (bookmarking)
- Tool Presets: Save and restore tool configurations
- Tool Workflows: Chain multiple tools in sequence
- Tool Export: Export tool outputs to standard formats
- Tool Collaboration: Real-time collaborative tool usage
- Tool Analytics: Track tool usage and performance
- Unified Tool State Manager: Centralized tool state management
- Unified Tool API: Standardize additional lifecycle hooks (onResize, onLayerChange, etc.)
- Tool Communication: Enable inter-tool messaging
- Tool Dependencies: Declare and resolve tool dependencies
- Some tools (Animation, Chemistry) have minimal configuration options
- Tool state persistence in URL is inconsistent across tools
- Mobile support varies by tool
- Accessibility features are incomplete (ARIA labels, keyboard shortcuts)
- Testing coverage is sparse (only Draw has comprehensive tests)
- Extract common tool patterns into base class or mixin
- Unify separated tool positioning logic
- Standardize backend API patterns
- Consolidate DEM access patterns across Measure, Identifier, Viewshed, Shade, Isochrone
The MMGIS Interactive Mapping Tools system provides a robust, extensible framework for delivering 15 specialized geospatial capabilities to users. The plugin architecture ensures consistent integration while allowing tools to implement domain-specific functionality. From collaborative drawing to terrain analysis, these tools support a wide range of planetary science and Earth observation use cases.
Version: 2.0 Date: 2025-12-22 Status: Active
Changes:
- Expanded to document all 15 user-facing tools individually
- Merged comprehensive Draw Tool content from spec 003
- Added brief architectural note about Kinds system
- Comprehensive configuration options for each tool
- Integration points documented
- Architecture notes (React vs jQuery, libraries used, file structure)
- Test coverage notes where applicable