C# Class MediaPortal.Player.IPlayer

This class holds the IPlayer interface which must be implemented by any interal player like - audio players - video players - tv timeshifting players
Inheritance: IDisposable
Exibir arquivo Open project: MediaPortal/MediaPortal-1 Class Usage Examples

Protected Properties

Property Type Description
_isVisible bool
_sourceRectangle System.Drawing.Rectangle
_videoRectangle System.Drawing.Rectangle

Public Methods

Method Description
AudioLanguage ( int iStream ) : string

Property to get the name for an audio stream

AudioType ( int iStream ) : string

Property to get the type of an audio stream

CanSeek ( ) : bool

Property which indicates if we can seek in the file

ContinueGraph ( ) : void
Dispose ( ) : void
EditionLanguage ( int iStream ) : string

Property to get the name for an edition stream

EditionType ( int iStream ) : string

Property to get the type of an edition stream

GetAudioDualMonoMode ( ) : eAudioDualMonoMode
GetHDC ( ) : int
GetResumeState ( byte &resumeData ) : bool

GetVideoFormat ( ) : VideoStreamFormat
IPlayer ( ) : System

Default ctor

OnAction ( MediaPortal.GUI.Library.Action action ) : bool

this method can be overriden if the player needs to respond to user actions like keypresses and mouse events

OnZapping ( int info ) : void
Pause ( ) : void

Method to pause or unpause

PauseGraph ( ) : void
Play ( string strFile ) : bool

This method is used to start playing a file

PlayStream ( string strFile, string streamName ) : bool

Nearly the same as Play(), but usefull for web streams to give the real name of the stream and not url

Process ( ) : void

This method will be called on a regular basis by MP it allows the external player to do some work

ReleaseHDC ( int HDC ) : void
SeekAbsolute ( double dTime ) : void

Method to seek to a specific point relative

SeekAsolutePercentage ( int iPercentage ) : void

Method to seek to a specific point

SeekRelative ( double dTime ) : void

Method to seek to a specific point relative from the current position

SeekRelativePercentage ( int iPercentage ) : void

Method to seek to a specific point relative to the current position

SetAudioDualMonoMode ( eAudioDualMonoMode mode ) : bool
SetResumeState ( byte resumeData ) : bool

SetVideoWindow ( ) : void

Method which is called by MP if the player needs to update its video window because the coordinates have been changed

SetVideoWindowMadVR ( ) : void

Method which is called by MP if the player needs to update its madVR video window because the coordinates have been changed

Stop ( ) : void

Method to stop playing

Stop ( bool keepExclusiveModeOn ) : void

Method to stop playing

StopAndKeepTimeShifting ( ) : void

Method to stop playing but at the same time keep timeshifting on server

SubtitleLanguage ( int iStream ) : string

Property to get/set the language name for a subtitle stream

SubtitleName ( int iStream ) : string

Property to get the name for a subtitle stream

VideoName ( int iStream ) : string

Property to get the name for an Video stream

VideoType ( int iStream ) : string

Property to get the type of an Video stream

WndProc ( Message &m ) : void

Method to handle any windows message MP will route any window message to the players so they can react on it by overriding this mehtod

Method Details

AudioLanguage() public method

Property to get the name for an audio stream
public AudioLanguage ( int iStream ) : string
iStream int
return string

AudioType() public method

Property to get the type of an audio stream
public AudioType ( int iStream ) : string
iStream int
return string

CanSeek() public method

Property which indicates if we can seek in the file
public CanSeek ( ) : bool
return bool

ContinueGraph() public method

public ContinueGraph ( ) : void
return void

Dispose() public abstract method

public abstract Dispose ( ) : void
return void

EditionLanguage() public method

Property to get the name for an edition stream
public EditionLanguage ( int iStream ) : string
iStream int
return string

EditionType() public method

Property to get the type of an edition stream
public EditionType ( int iStream ) : string
iStream int
return string

GetAudioDualMonoMode() public method

public GetAudioDualMonoMode ( ) : eAudioDualMonoMode
return eAudioDualMonoMode

GetHDC() public method

public GetHDC ( ) : int
return int

GetResumeState() public method

public GetResumeState ( byte &resumeData ) : bool
resumeData byte resumeData
return bool

GetVideoFormat() public method

public GetVideoFormat ( ) : VideoStreamFormat
return VideoStreamFormat

IPlayer() public method

Default ctor
public IPlayer ( ) : System
return System

OnAction() public method

this method can be overriden if the player needs to respond to user actions like keypresses and mouse events
public OnAction ( MediaPortal.GUI.Library.Action action ) : bool
action MediaPortal.GUI.Library.Action
return bool

OnZapping() public method

public OnZapping ( int info ) : void
info int
return void

Pause() public method

Method to pause or unpause
public Pause ( ) : void
return void

PauseGraph() public method

public PauseGraph ( ) : void
return void

Play() public method

This method is used to start playing a file
public Play ( string strFile ) : bool
strFile string file to play
return bool

PlayStream() public method

Nearly the same as Play(), but usefull for web streams to give the real name of the stream and not url
public PlayStream ( string strFile, string streamName ) : bool
strFile string file to play
streamName string real name of the stream
return bool

Process() public method

This method will be called on a regular basis by MP it allows the external player to do some work
public Process ( ) : void
return void

ReleaseHDC() public method

public ReleaseHDC ( int HDC ) : void
HDC int
return void

SeekAbsolute() public method

Method to seek to a specific point relative
public SeekAbsolute ( double dTime ) : void
dTime double absolute time in secs
return void

SeekAsolutePercentage() public method

Method to seek to a specific point
public SeekAsolutePercentage ( int iPercentage ) : void
iPercentage int percentage (0 to +100%)
return void

SeekRelative() public method

Method to seek to a specific point relative from the current position
public SeekRelative ( double dTime ) : void
dTime double relative time in secs
return void

SeekRelativePercentage() public method

Method to seek to a specific point relative to the current position
public SeekRelativePercentage ( int iPercentage ) : void
iPercentage int percentage (-100% to +100%) relative to the current position
return void

SetAudioDualMonoMode() public method

public SetAudioDualMonoMode ( eAudioDualMonoMode mode ) : bool
mode eAudioDualMonoMode
return bool

SetResumeState() public method

public SetResumeState ( byte resumeData ) : bool
resumeData byte resumeData
return bool

SetVideoWindow() public method

Method which is called by MP if the player needs to update its video window because the coordinates have been changed
public SetVideoWindow ( ) : void
return void

SetVideoWindowMadVR() public method

Method which is called by MP if the player needs to update its madVR video window because the coordinates have been changed
public SetVideoWindowMadVR ( ) : void
return void

Stop() public method

Method to stop playing
public Stop ( ) : void
return void

Stop() public method

Method to stop playing
public Stop ( bool keepExclusiveModeOn ) : void
keepExclusiveModeOn bool
return void

StopAndKeepTimeShifting() public method

Method to stop playing but at the same time keep timeshifting on server
public StopAndKeepTimeShifting ( ) : void
return void

SubtitleLanguage() public method

Property to get/set the language name for a subtitle stream
public SubtitleLanguage ( int iStream ) : string
iStream int
return string

SubtitleName() public method

Property to get the name for a subtitle stream
public SubtitleName ( int iStream ) : string
iStream int
return string

VideoName() public method

Property to get the name for an Video stream
public VideoName ( int iStream ) : string
iStream int
return string

VideoType() public method

Property to get the type of an Video stream
public VideoType ( int iStream ) : string
iStream int
return string

WndProc() public method

Method to handle any windows message MP will route any window message to the players so they can react on it by overriding this mehtod
public WndProc ( Message &m ) : void
m System.Windows.Forms.Message Message
return void

Property Details

_isVisible protected_oe property

protected bool _isVisible
return bool

_sourceRectangle protected_oe property

protected Rectangle,System.Drawing _sourceRectangle
return System.Drawing.Rectangle

_videoRectangle protected_oe property

protected Rectangle,System.Drawing _videoRectangle
return System.Drawing.Rectangle