Commit Graph
6 Commits
Author SHA1 Message Date
Mark.lin 024df690c3 Fix zero-copy frame lifecycle
Enable zero-copy through the public API before opening the device and configure a driver-owned zero-copy ring slot.

Return every delivered frame through IOCTL_GIGA_RELEASE_VIDEO_FRAME and validate the complete frame token before release.

Preserve ownership when the release IOCTL fails so stop, close, or the next start can retry instead of discarding the driver pointer.

Stop DMA and join the backend acquire/event thread before draining frames, preventing acquire from racing stop or disable.

Drain caller-held, ready, unread, and pending zero-copy frames before stop, restart, disable, device close, or process destruction.

Block restart and zero-copy disable when outstanding frames cannot be released successfully.

Release unread frames on signal unplug and before format or resolution changes rebuild the frame ring.

Propagate stop and release errors through the public API and report release failures in the standalone preview.

Document zero-copy ownership, lifecycle requirements, diagnostics, and data flow.

Verified with Standalone Debug and Release builds.
2026-08-19 15:34:37 +08:00
Mark.lin d7500ed9fd feat(gvfg): add event-driven signal and format control
Expose gvfg_set_video_format() so applications select YUY2 or Y210 through the SDK while the backend temporarily writes absolute register 0x80 (0=YUY2, 1=Y210).

Define RX mode/timing lock registers and treat the input as connected only when both lock values equal one. Keep plug/unplug/format monitoring active for the complete open-channel lifetime, cache signal metadata, and avoid unnecessary resolution/format register queries.

Keep the driver-compatible GET_VIDEO_DONE_INDEX then GET_FRAME sequence, reject repeated consecutive DMA done indexes, and calculate capture FPS over a one-second delivery window instead of adjacent-frame timing.

Update the standalone Qt sample with YUY2/Y210 selection, event-driven signal state, no-signal Start blocking, streamlined diagnostics, and monitoring that remains active while capture is stopped.

Validation: Release builds completed for the Visual Studio and Qt Creator build trees; the Qt Creator DLL relink requires the consuming viewer to be closed when it is running.
2026-08-14 16:36:38 +08:00
Mark.lin 17fb9bfabd feat: align GVFG output with YUY2
- expose YUY2 across the public API, preview helper, backend, and GPU conversion paths while translating the legacy FPGA format value internally
- correct YUY2 chroma byte interpretation and update customer/internal documentation
- centralize the Standalone SDK version and expose it through gvfg_get_version
- show the SDK version in the sample and enable preview-window controls only after the first valid frame
- close and disable external preview windows when capture stops
2026-08-13 16:14:16 +08:00
Mark.lin 08da3c9000 Update preview controls and debug packaging 2026-08-07 09:51:53 +08:00
Mark.lin 7918b79480 Simplify XDMA types and add fullscreen preview 2026-06-09 17:41:06 +08:00
Mark.lin 53378c6495 Initial standalone GVFG SDK 2026-06-09 10:02:10 +08:00