Commit graph

13 commits

Author SHA1 Message Date
835f468e1b Prototype/Demo: minor bugfix
Add failure check when opening next URing slot for a submission;
this ''can'' fail when the ring is fully populated -- which in theory
should never happen in our setup, yet can always, in practice...
2026-08-10 04:40:37 +02:00
703e60c85a Review: identify and resolve problem with sync logic
''Review supported by Claude Code''

Control flow logic was scrutinised, and a race identified
in the solution to pass on the display action to the GUI thread.

Reconsidering the design, cross-thread synchronisation is now
hinged rather on a single atomic buffer pointer, where the GUI
thread notifies back completion of display work by setting that
pointer to NULL. Overall this simplifies the control logic

----
As an aside, I setup an outline of topics for documentation in `DemoSpec.txt`
and then instructed Claude to fill in the paragraphs, based on insight gained
as part of the code validation / review. Furthermore, I requested to generate
some diagrams that could be useful later when preparting the presentation
2026-07-19 03:48:16 +02:00
72e1838b36 Prototype/Demo: add IO timing measurement
- use a helper class with a series of timer variables
- these can be addressed like the buffer ring »slots«
- commit each individual measurement into an EMA
2026-07-18 01:25:17 +02:00
b92977883c Prototype: Playback parameters for a 1200px-50fps video
Search for suitable footage to show in the demo:
Using a scene from New-Year 2023/24 at the Munich "Reichenbachbrücke"
2026-07-17 19:00:14 +02:00
0cda45278c Prototype: demo works — after fixing obvious mistakes
No fundamental problem discovered thus far...
 - GTK-3 does not resize the window, need to `set_size_request()` (instead of `resize()`)
 - forgot to set slot-state to READ ⟹ submissions flood the full queue
 - condition to allow frame display was too tight, thus slipping at first frame
 - forgot to submit follow-up read tasks
2026-07-17 00:14:29 +02:00
c9f9fec117 Prototype: code improvements
- rename the states to better reflect their purpose
 - introduce getters for in BufferDispatcher
2026-07-16 19:31:34 +02:00
0cb388d4a7 Prototype: implement complete Proactor buffer state-engine
Turns out we need to add further states and transitions,
to establish full sync-link (backpressure) in both directions...
 - need to introduce a third cursor since the callback from GUI-Thread can be late
 - consequently also need a further state transition SHOW -> WAIT to create the barrier
 - furthermore, need marker state STOP to halt playback after a short read (end-of-file)
2026-07-16 04:02:18 +02:00
ae74bd323e Prototype: establish buffer data structure and initialise URing
- setup a IORING_OP_TIMEOUT to drive the frame loop
- use the status mark of buffers ahead to supply new IORING_OP_READ
- rely on two running framecount cursors with modulus to map onto buffer slots
2026-07-15 23:53:23 +02:00
2a61def8a4 Prototype: need to introduce an interface for the frame data feed
Since I want to segregate the code according to the domain,
several methods must be provided to the video display to conduct
a properly synchronised handover of video pixel data; by using
`Glib::Dispatcher` as base class, all aspects of feed synchronisation
can be packaged into a single connection interface, without having
to share implementation details between the video display and player.
2026-07-15 20:40:59 +02:00
4699ae8f03 Prototype: settle wiring and configuration of UringVideoPlayer and EglDisplay
This implies a basic decision regarding the buffer and state data to use,
and how this can be defined, parameterised and passed between threads.

I decided to place separation of domains first and to prefer
using a functional callback over using a shared data structure.
2026-07-15 18:56:37 +02:00
6bf8a0da7a Prototype: integrate EglDisplay as self-contained component 2026-07-14 20:16:18 +02:00
b92de63d25 Prototype: establish a top-level structure
leaning heavily on the similar structure used for last year's
FrOSCon talk regarding video output (by Benny Lyons and myself).

However, this time we'll use a process state object (the player)
and, furthermore, there is some cross-wiring of components involved...
2026-07-14 19:27:27 +02:00
9e0f2aed6b Prototype: setup for example code ++ GPL v2+
Hereby I use the setup and framework from last year's FrOSCon talk
to bootstrap the demo example code for the talk at FrOSCon-26

Notably, the modern OpenGL output pipeline based on EGL is intended for reuse.
Insights in this code were based essentially on existing code bases under GPL.
Furthermore, using GPL is seen as a statement in support of "The Commons"
2026-07-11 20:43:45 +02:00