Skip to main content

Crate playback

Crate playback 

Source
Expand description

playback — player state machine that pumps decoded frames into wisp.

Sits between [decode::VideoStream] (the upstream codec backend) and wisp::VideoTexture (the GPU upload target). The shell (Tauri / native winit) drives it via:

§Quick start

use std::time::Duration;
use decode::mock::MockVideoStream;
use playback::Player;
use pollster::block_on;
use wisp::application::{AppConfig, Application};

let app = block_on(Application::new(AppConfig::default())).unwrap();
let stream = MockVideoStream::scrolling_gradient(640, 360, 90);
let mut player = Player::new(&app, Box::new(stream));
player.play();
player.tick(&app, Duration::from_millis(33));   // ~one source frame

Re-exports§

pub use editor_player::EditorPlayer;

Modules§

editor_player
EditorPlayer — the editor’s frame-indexed, variable-rate playback clock (ED.4 / M-EDIT).

Structs§

Player
Player state machine. Owns the upstream stream and the GPU texture holding the current frame.

Enums§

PlayState
Transport state.