Phonon

The MediaObject class

Media Data Producing Class

There is the class that produces the media data (often called a source in media frameworks).

Required Functions

Optional Functions

Signals

Member Function Documentation

See also
void totalTimeChanged(qint64 totalTime)

qint32 prefinishMark()

Returns the time in milliseconds the prefinishMarkReached signal is emitted before the playback if finished and finished is emitted.

void setPrefinishMark(qint32 msec)

Sets the time in milliseconds the prefinishMarkReached signal is emitted before the playback if finished and finished is emitted.

Parameters
msecThe time in milliseconds. If the value is less than or equal to 0 the prefinishMarkReached signal is disabled.

qint64 remainingTime()

Get the remaining time (in milliseconds) of the file currently being played. If the method is not implemented in the backend the frontend will use the difference between MediaObjectInterface::totalTime() and MediaObjectInterface::currentTime() .

Signals Documentation

void prefinishMarkReached(qint32 msec)

Emitted when the file has finished playing on its own. I.e. it is not emitted if you call stop(), pause() or load(), but only on end-of-file or a critical error. void finished()

Parameters
msecThe remaining time until the playback finishes

void totalTimeChanged(qint64 totalTime)

This signal is emitted as soon as the length of the media file is known or has changed. For most non-local media data the length of the media can only be known after some time. At that time the totalTime function can not return useful information. You have to wait for this signal to know the real length.

Parameters
totalTimeChangedThe total time of the media file in milliseconds.
See also
MediaObjectInterface::totalTime()

void finished()

This signal is emitted when the playback of the media finished (on its own). It is not emitted if stop() or pause() are called - only on end-of-file or a critical error (for example the media data stream is corrupted and playback of the media has to be finished).

See also
void prefinishMarkReached(qint32 msec)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:18:23 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.