Versions in this module Expand all Collapse all v0 v0.0.1 Feb 27, 2020 Changes in this version + const MediaListPlayerNextItemSet + const MediaListPlayerPlayed + const MediaListPlayerStopped + const MediaListViewItemAdded + const MediaListViewItemDeleted + const MediaListViewWillAddItem + const MediaListViewWillDeleteItem + var ErrAudioOutputListMissing = errors.New("could not get audio output list") + var ErrInvalidEventCallback = errors.New("invalid event callback") + var ErrInvalidMediaStats = errors.New("invalid media statistics") + var ErrListPlayerCreate = errors.New("could not create list player") + var ErrListPlayerNotInitialized = errors.New("list player not initialized") + var ErrMediaCreate = errors.New("could not create media") + var ErrMediaListCreate = errors.New("could not create media list") + var ErrMediaListNotInitialized = errors.New("media list not initialized") + var ErrMediaMetaSave = errors.New("could not save media metadata") + var ErrMediaNotInitialized = errors.New("media not initialized") + var ErrMissingEventManager = errors.New("could not get event manager instance") + var ErrMissingMediaLocation = errors.New("could not get media location") + var ErrMissingMediaStats = errors.New("could not get media statistics") + var ErrModuleInitialize = errors.New("could not initialize module") + var ErrModuleNotInitialized = errors.New("module not initialized") + var ErrPlayerCreate = errors.New("could not create player") + var ErrPlayerNotInitialized = errors.New("player not initialized") + func Init(args ...string) error + func Release() error + type AudioOutput struct + Description string + Name string + func AudioOutputList() ([]*AudioOutput, error) + type Event int + const MediaDiscovererEnded + const MediaDiscovererStarted + const MediaDurationChanged + const MediaFreed + const MediaListEndReached + const MediaListItemAdded + const MediaListItemDeleted + const MediaListWillAddItem + const MediaListWillDeleteItem + const MediaMetaChanged + const MediaParsedChanged + const MediaPlayerAudioDevice + const MediaPlayerAudioVolume + const MediaPlayerBackward + const MediaPlayerBuffering + const MediaPlayerChapterChanged + const MediaPlayerCorked + const MediaPlayerESAdded + const MediaPlayerESDeleted + const MediaPlayerESSelected + const MediaPlayerEncounteredError + const MediaPlayerEndReached + const MediaPlayerForward + const MediaPlayerLengthChanged + const MediaPlayerMediaChanged + const MediaPlayerMuted + const MediaPlayerNothingSpecial + const MediaPlayerOpening + const MediaPlayerPausableChanged + const MediaPlayerPaused + const MediaPlayerPlaying + const MediaPlayerPositionChanged + const MediaPlayerScrambledChanged + const MediaPlayerSeekableChanged + const MediaPlayerSnapshotTaken + const MediaPlayerStopped + const MediaPlayerTimeChanged + const MediaPlayerTitleChanged + const MediaPlayerUncorked + const MediaPlayerUnmuted + const MediaPlayerVout + const MediaStateChanged + const MediaSubItemAdded + const MediaSubItemTreeAdded + const MediaThumbnailGenerated + const RendererDiscovererItemAdded + const RendererDiscovererItemDeleted + const VlmMediaAdded + const VlmMediaChanged + const VlmMediaInstanceStarted + const VlmMediaInstanceStatusEnd + const VlmMediaInstanceStatusError + const VlmMediaInstanceStatusInit + const VlmMediaInstanceStatusOpening + const VlmMediaInstanceStatusPause + const VlmMediaInstanceStatusPlaying + const VlmMediaInstanceStopped + const VlmMediaRemoved + type EventCallback func(Event, interface{}) + type EventID uint64 + type EventManager struct + func (em *EventManager) Attach(event Event, callback EventCallback, userData interface{}) (EventID, error) + func (em *EventManager) Detach(eventID EventID) + type ListPlayer struct + func NewListPlayer() (*ListPlayer, error) + func (lp *ListPlayer) EventManager() (*EventManager, error) + func (lp *ListPlayer) IsPlaying() bool + func (lp *ListPlayer) MediaList() *MediaList + func (lp *ListPlayer) MediaState() (MediaState, error) + func (lp *ListPlayer) Play() error + func (lp *ListPlayer) PlayAtIndex(index uint) error + func (lp *ListPlayer) PlayNext() error + func (lp *ListPlayer) PlayPrevious() error + func (lp *ListPlayer) Player() (*Player, error) + func (lp *ListPlayer) Release() error + func (lp *ListPlayer) SetMediaList(ml *MediaList) error + func (lp *ListPlayer) SetPlaybackMode(mode PlaybackMode) error + func (lp *ListPlayer) SetPlayer(player *Player) error + func (lp *ListPlayer) Stop() error + func (lp *ListPlayer) TogglePause() error + type Media struct + func NewMediaFromPath(path string) (*Media, error) + func NewMediaFromURL(url string) (*Media, error) + func (m *Media) AddOptions(options ...string) error + func (m *Media) EventManager() (*EventManager, error) + func (m *Media) IsParsed() (bool, error) + func (m *Media) Location() (string, error) + func (m *Media) Meta(key MediaMetaKey) (string, error) + func (m *Media) Parse() error + func (m *Media) ParseAsync() error + func (m *Media) Release() error + func (m *Media) SaveMeta() error + func (m *Media) SetMeta(key MediaMetaKey, val string) error + func (m *Media) Stats() (*MediaStats, error) + type MediaList struct + func NewMediaList() (*MediaList, error) + func (ml *MediaList) AddMedia(m *Media) error + func (ml *MediaList) AddMediaFromPath(path string) error + func (ml *MediaList) AddMediaFromURL(url string) error + func (ml *MediaList) Count() (int, error) + func (ml *MediaList) EventManager() (*EventManager, error) + func (ml *MediaList) InsertMedia(m *Media, index uint) error + func (ml *MediaList) InsertMediaFromPath(path string, index uint) error + func (ml *MediaList) InsertMediaFromURL(url string, index uint) error + func (ml *MediaList) IsReadOnly() (bool, error) + func (ml *MediaList) Lock() error + func (ml *MediaList) MediaAtIndex(index uint) (*Media, error) + func (ml *MediaList) Release() error + func (ml *MediaList) RemoveMediaAtIndex(index uint) error + func (ml *MediaList) Unlock() error + type MediaMetaKey uint + const MediaActors + const MediaAlbum + const MediaAlbumArtist + const MediaArtist + const MediaArtworkURL + const MediaCopyright + const MediaDate + const MediaDescription + const MediaDirector + const MediaDiscNumber + const MediaDiscTotal + const MediaEncodedBy + const MediaEpisode + const MediaGenre + const MediaLanguage + const MediaNowPlaying + const MediaPublisher + const MediaRating + const MediaSeason + const MediaSetting + const MediaShowName + const MediaTitle + const MediaTrackID + const MediaTrackNumber + const MediaTrackTotal + const MediaURL + func (mt MediaMetaKey) Validate() error + type MediaState uint + const MediaBuffering + const MediaEnded + const MediaError + const MediaNothingSpecial + const MediaOpening + const MediaPaused + const MediaPlaying + const MediaStopped + type MediaStats struct + DecodedAudio int + DecodedVideo int + DemuxBitRate float64 + DemuxCorrupted int + DemuxDiscontinuity int + DemuxReadBytes int + DisplayedPictures int + InputBitRate float64 + LostAudioBuffers int + LostPictures int + PlayedAudioBuffers int + ReadBytes int + type PlaybackMode uint + const Default + const Loop + const Repeat + type Player struct + func NewPlayer() (*Player, error) + func (p *Player) EventManager() (*EventManager, error) + func (p *Player) IsFullScreen() (bool, error) + func (p *Player) IsPlaying() bool + func (p *Player) LoadMediaFromPath(path string) (*Media, error) + func (p *Player) LoadMediaFromURL(url string) (*Media, error) + func (p *Player) Media() (*Media, error) + func (p *Player) MediaLength() (int, error) + func (p *Player) MediaPosition() (float32, error) + func (p *Player) MediaState() (MediaState, error) + func (p *Player) MediaTime() (int, error) + func (p *Player) Play() error + func (p *Player) Release() error + func (p *Player) SetAudioOutput(output string) error + func (p *Player) SetFullScreen(fullscreen bool) error + func (p *Player) SetMedia(m *Media) error + func (p *Player) SetMediaPosition(pos float32) error + func (p *Player) SetMediaTime(t int) error + func (p *Player) SetPause(pause bool) error + func (p *Player) SetVolume(volume int) error + func (p *Player) SetXWindow(windowID uint32) error + func (p *Player) Stop() error + func (p *Player) ToggleFullScreen() error + func (p *Player) TogglePause() error + func (p *Player) Volume() (int, error) + func (p *Player) WillPlay() bool + type VersionInfo struct + Major uint + Minor uint + Patch uint + func Version() VersionInfo + func (v VersionInfo) String() string Other modules containing this package github.com/adrg/libvlc-go/v2 github.com/adrg/libvlc-go/v3