|
|
@ -139,6 +139,8 @@ export const radarSketch = function (p) { |
|
|
// Get current frame data
|
|
|
// Get current frame data
|
|
|
const frameData = appState.vizData.radarFrames[appState.currentFrame]; |
|
|
const frameData = appState.vizData.radarFrames[appState.currentFrame]; |
|
|
if (frameData) { |
|
|
if (frameData) { |
|
|
|
|
|
drawPointCloud(p, frameData.pointCloud, plotScales); |
|
|
|
|
|
if (!appState.isRawOnlyMode) { |
|
|
drawRegionsOfInterest(p, frameData, plotScales); |
|
|
drawRegionsOfInterest(p, frameData, plotScales); |
|
|
drawTrackMarkers(p, plotScales); |
|
|
drawTrackMarkers(p, plotScales); |
|
|
|
|
|
|
|
|
@ -197,18 +199,21 @@ export const radarSketch = function (p) { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
// Draw the point cloud for the current frame
|
|
|
|
|
|
drawPointCloud(p, frameData.pointCloud, plotScales); |
|
|
|
|
|
|
|
|
|
|
|
// Draw cluster centroids if enabled
|
|
|
// Draw cluster centroids if enabled
|
|
|
if (toggleClusterColor.checked) { |
|
|
if (toggleClusterColor.checked) { |
|
|
drawClusterCentroids(p, frameData.clusters, plotScales); |
|
|
drawClusterCentroids(p, frameData.clusters, plotScales); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
p.pop(); |
|
|
p.pop(); |
|
|
|
|
|
|
|
|
// 4. Draw the new legend buffer onto the main canvas
|
|
|
// 4. Draw the new legend buffer onto the main canvas
|
|
|
// This is placed at the bottom-right corner.
|
|
|
// This is placed at the bottom-right corner.
|
|
|
if (toggleTracks.checked) { |
|
|
|
|
|
|
|
|
if (toggleTracks.checked && !appState.isRawOnlyMode) { |
|
|
p.image( |
|
|
p.image( |
|
|
trackLegendBuffer, |
|
|
trackLegendBuffer, |
|
|
p.width - trackLegendBuffer.width - 10, |
|
|
p.width - trackLegendBuffer.width - 10, |
|
|
|