LibreOffice: XPlayer Interface Reference

LibreOffice LibreOffice 26.8 SDK API Reference

Loading...
Searching...
No Matches
XPlayer Interface Reference

is the multimedia stream handling interface. More...

`import "XPlayer.idl";`

## Public Member Functions
void | start ()
| starts reading the stream from the current position.
void | stop ()
| stops reading the stream and leave the cursor at its current position.
boolean | isPlaying ()
| indicates whether the stream is played or not.
double | getDuration ()
| gets the stream length
void | setMediaTime ([in] double fTime)
| sets the new cursor position in the media stream.
double | getMediaTime ()
| gets the current position of the cursor in the stream
void | setPlaybackLoop ([in] boolean bSet)
| sets whether the stream reading should restart at the stream start after the end of the stream.
boolean | isPlaybackLoop ()
| indicates whether the stream reading will restart after the end of the stream.
void | setVolumeDB ([in] short nDB)
| sets the audio volume in decibel.
short | getVolumeDB ()
| gets the current audio volume in decibel
void | setMute ([in] boolean bSet)
| sets the volume to `0` or to its previous value.
boolean | isMute ()
| gets whether the volume is temporarily down to `0` or not.
::com::sun::star::awt::Size | getPreferredPlayerWindowSize ()
| gets the preferred window size
XPlayerWindow | createPlayerWindow ([in] sequence< any > aArguments)
| gets a new player window for this stream control
XFrameGrabber | createFrameGrabber ()
| gets a frame grabber for this stream.

## Detailed Description

is the multimedia stream handling interface.

This allows to perform every basic operation on videos and sounds.

## Member Function Documentation

## ◆ createFrameGrabber()

XFrameGrabber createFrameGrabber | ( |  | ) |

gets a frame grabber for this stream.

## ◆ createPlayerWindow()

XPlayerWindow createPlayerWindow | ( | [in] sequence< any > | aArguments | ) |

gets a new player window for this stream control

Parameters

  aArguments | arguments passed to the window during its creation.

## ◆ getDuration()

double getDuration | ( |  | ) |

gets the stream length

Returns
  the stream length in second

## ◆ getMediaTime()

double getMediaTime | ( |  | ) |

gets the current position of the cursor in the stream

Returns
  the cursor position in seconds

## ◆ getPreferredPlayerWindowSize()

::com::sun::star::awt::Size getPreferredPlayerWindowSize | ( |  | ) |

gets the preferred window size

Returns
  the com::sun::star::awt::Size

## ◆ getVolumeDB()

short getVolumeDB | ( |  | ) |

gets the current audio volume in decibel

Returns
  the volume in decibel

## ◆ isMute()

boolean isMute | ( |  | ) |

gets whether the volume is temporarily down to `0` or not.

Returns
  TRUE if the volume is temporarily set to `0`, FALSE otherwise.

## ◆ isPlaybackLoop()

boolean isPlaybackLoop | ( |  | ) |

indicates whether the stream reading will restart after the end of the stream.

Returns
  TRUE if the stream will loop, FALSE otherwise.

## ◆ isPlaying()

boolean isPlaying | ( |  | ) |

indicates whether the stream is played or not.

Returns
  TRUE if the stream is played, FALSE otherwise

## ◆ setMediaTime()

void setMediaTime | ( | [in] double | fTime | ) |

sets the new cursor position in the media stream.

After using this method the stream is stopped.

Parameters

  fTime | the new position to set in seconds

## ◆ setMute()

void setMute | ( | [in] boolean | bSet | ) |

sets the volume to `0` or to its previous value.

Parameters

  bSet | sets the volume to `0` if TRUE, and switch to the previous non-null value if FALSE

## ◆ setPlaybackLoop()

void setPlaybackLoop | ( | [in] boolean | bSet | ) |

sets whether the stream reading should restart at the stream start after the end of the stream.

Parameters

  bSet | loops if set to TRUE, otherwise stops at the end of the stream.

## ◆ setVolumeDB()

void setVolumeDB | ( | [in] short | nDB | ) |

sets the audio volume in decibel.

Parameters

  nDB | the new volume in Decibel

## ◆ start()

void start | ( |  | ) |

starts reading the stream from the current position.

## ◆ stop()

void stop | ( |  | ) |

stops reading the stream and leave the cursor at its current position.

The documentation for this interface was generated from the following file:

- com/sun/star/media/XPlayer.idl