video

package
v0.0.13 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 7, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package video plays video inside your screen, from a URL, with the system's own player.

nimbus native plugin add video

video.Player{URL: "https://example.com/tour.mp4", Style: ui.Style{Height: ui.Pt(220)}}

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Player

type Player struct {
	URL      string // where the video is
	Paused   bool   // setting it pauses and resumes from Go
	Loop     bool   // starts again at the end
	Muted    bool   // plays with no sound
	Controls bool   // the system's controls

	OnReady func(seconds float64) // it can play, and how long it is
	OnEnd   func()                // called when it finishes
	Style   ui.Style              // the player's size and place on the screen
}

Player is a video.

func (Player) Render

func (v Player) Render(c *ui.Ctx) ui.Component

Render shows the player.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL