feat(web): reproducción de cámara al seleccionar + edición de ROI en vivo - #5
Open
npalmae wants to merge 1 commit into
Open
feat(web): reproducción de cámara al seleccionar + edición de ROI en vivo#5npalmae wants to merge 1 commit into
npalmae wants to merge 1 commit into
Conversation
Camera view: - click a grid tile opens a fullscreen modal with the live stream (Esc to close) ROI configurator: - auto-capture live camera frame as background (go2rtc frame.jpeg) - optional live video background (WHEP) with freeze/resume while drawing - exact image/canvas alignment via JS-computed letterbox stage (fixes click offset on non-16:9 viewports) - drag whole figures or individual vertices (pointer capture) - rubber-band preview and vertex dots while drawing - close polygon by clicking near first vertex; right-click removes last vertex - undo stack (Ctrl+Z) for add/delete/move operations
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Propósito
Mejorar la operatividad del dashboard: ver una cámara individual en grande y hacer la calibración de ROIs usable sobre imagen real de la cámara (frame estático o video en vivo), en lugar de subir imágenes manualmente.
Cambios
Vista de cámara individual (
CameraGrid.tsx)Editor de ROI (
RoiConfiguratorPage.tsx)/api/frame.jpeg). El botón "Frame en vivo" lo recaptura; "Subir" queda como respaldo para cámaras offline.ResizeObserver(letterbox exacto imagen↔SVG en cualquier tamaño de ventana). Antes,aspect-ratioCSS rompía la proporción en contenedores altos y los clics caían desplazados.setPointerCapture, no se pierde el drag al mover rápido).Ctrl/Cmd+Z(alta/borrado/movimiento).Verificación
tsc -b --noEmitlimpio,vite buildOK/go2rtc/Notas
docs/oferta-casos-de-uso.mdqueda fuera de este PR (material comercial)