Kodi Development  20.0
for Binary and Script based Add-Ons
Callback functions from Kodi to Add-On

Detailed Description

Callback functions.

Functions to handle control callbacks from Kodi to Add-On.


Go back to normal functions from player

Function Documentation

◆ onPlayBackStarted()

onPlayBackStarted ( )

Function: onPlayBackStarted()


onPlayBackStarted method.

Will be called when Kodi player starts. Video or audio might not be available at this point.


v18 Python API changes:
Use onAVStarted() instead if you need to detect if Kodi is actually playing a media file (i.e, if a stream is available)

◆ onAVStarted()

onAVStarted ( )

Function: onAVStarted()


onAVStarted method.

Will be called when Kodi has a video or audiostream.


v18 Python API changes:
New function added.

◆ onAVChange()

onAVChange ( )

Function: onAVChange()


onAVChange method.

Will be called when Kodi has a video, audio or subtitle stream. Also happens when the stream changes.


v18 Python API changes:
New function added.

◆ onPlayBackEnded()

onPlayBackEnded ( )

Function: onPlayBackEnded()


onPlayBackEnded method.

Will be called when Kodi stops playing a file.

◆ onPlayBackStopped()

onPlayBackStopped ( )

Function: onPlayBackStopped()


onPlayBackStopped method.

Will be called when user stops Kodi playing a file.

◆ onPlayBackError()

onPlayBackError ( )

Function: onPlayBackError()


onPlayBackError method.

Will be called when playback stops due to an error.

◆ onPlayBackPaused()

onPlayBackPaused ( )

Function: onPlayBackPaused()


onPlayBackPaused method.

Will be called when user pauses a playing file.

◆ onPlayBackResumed()

onPlayBackResumed ( )

Function: onPlayBackResumed()


onPlayBackResumed method.

Will be called when user resumes a paused file.

◆ onQueueNextItem()

onQueueNextItem ( )

Function: onQueueNextItem()


onQueueNextItem method.

Will be called when user queues the next item.

◆ onPlayBackSpeedChanged()

onPlayBackSpeedChanged ( int  speed)

Function: onPlayBackSpeedChanged(speed)


onPlayBackSpeedChanged method.

Will be called when players speed changes (eg. user FF/RW).

Parameters
speed[integer] Current speed of player
Note
Negative speed means player is rewinding, 1 is normal playback speed.

◆ onPlayBackSeek()

onPlayBackSeek (   ...)

Function: onPlayBackSeek(time, seekOffset)


onPlayBackSeek method.

Will be called when user seeks to a time.

Parameters
time[integer] Time to seek to
seekOffset[integer] ?

◆ onPlayBackSeekChapter()

onPlayBackSeekChapter (   ...)

Function: onPlayBackSeekChapter(chapter)


onPlayBackSeekChapter method.

Will be called when user performs a chapter seek.

Parameters
chapter[integer] Chapter to seek to