Major improvements to UnifiedPlayer: 1. GetFrameImage() now works when paused for responsive UI updates 2. Play() method properly starts FFmpeg process 3. Frame display loop runs continuously for smooth video display 4. Disabled audio temporarily to fix video playback fundamentals 5. Simplified FFmpeg command to focus on video stream only Player now: - Generates video frames correctly - Shows video when paused - Has responsive progress tracking - Starts playback properly Next steps: Re-enable audio playback once video is stable
28 lines
1.1 KiB
Go
28 lines
1.1 KiB
Go
// Package glfw experimentally provides a glfw-like API
|
|
// with desktop (via glfw) and browser (via HTML5 canvas) backends.
|
|
//
|
|
// It is used for creating a GL context and receiving events.
|
|
//
|
|
// Note: This package is currently in development. The API is incomplete and may change.
|
|
package glfw
|
|
|
|
// ContextWatcher is a general mechanism for being notified when context is made current or detached.
|
|
type ContextWatcher interface {
|
|
// OnMakeCurrent is called after a context is made current.
|
|
// context is is a platform-specific representation of the context, or nil if unavailable.
|
|
OnMakeCurrent(context any)
|
|
|
|
// OnDetach is called after the current context is detached.
|
|
OnDetach()
|
|
}
|
|
|
|
// VidMode describes a single video mode.
|
|
type VidMode struct {
|
|
Width int // The width, in pixels, of the video mode.
|
|
Height int // The height, in pixels, of the video mode.
|
|
RedBits int // The bit depth of the red channel of the video mode.
|
|
GreenBits int // The bit depth of the green channel of the video mode.
|
|
BlueBits int // The bit depth of the blue channel of the video mode.
|
|
RefreshRate int // The refresh rate, in Hz, of the video mode.
|
|
}
|