Media item. More...
#include <VLCQtCore/Media.h>
Signals | |
void | metaChanged (const Vlc::Meta &meta) |
Signal sent on meta change. More... | |
void | subitemAdded (libvlc_media_t *subitem) |
Signal sent on subitem added. More... | |
void | durationChanged (int duration) |
Signal sent on duration change. More... | |
Q_DECL_DEPRECATED void | parsedChanged (int status) |
Signal sent on parsed change. More... | |
void | parsedChanged (bool status) |
Signal sent on parsed change. More... | |
void | freed (libvlc_media_t *media) |
Signal sent on freed. More... | |
void | stateChanged (const Vlc::State &state) |
Signal sent on state change. More... | |
Public Member Functions | |
VlcMedia (const QString &location, bool localFile, VlcInstance *instance) | |
VlcMedia constructor. More... | |
VlcMedia (const QString &location, VlcInstance *instance) | |
VlcMedia constructor. More... | |
VlcMedia (libvlc_media_t *media) | |
VlcMedia constructor. More... | |
~VlcMedia () | |
VlcMedia destructor. | |
libvlc_media_t * | core () |
libvlc media item More... | |
bool | parsed () const |
Get parsed status. More... | |
void | parse () |
Parse media information. More... | |
QString | currentLocation () const |
Current media location. More... | |
VlcStats * | getStats () |
Get media stats. More... | |
Vlc::State | state () const |
Get media state. More... | |
qint64 | duration () const |
Get media duration. More... | |
QString | duplicate (const QString &name, const QString &path, const Vlc::Mux &mux) |
Duplicate (provided for convenience) More... | |
QString | duplicate (const QString &name, const QString &path, const Vlc::Mux &mux, const Vlc::AudioCodec &audioCodec, const Vlc::VideoCodec &videoCodec) |
Duplicate (provided for convenience) More... | |
QString | duplicate (const QString &name, const QString &path, const Vlc::Mux &mux, const Vlc::AudioCodec &audioCodec, const Vlc::VideoCodec &videoCodec, int bitrate, int fps, int scale) |
Duplicate (provided for convenience) More... | |
QString | merge (const QString &name, const QString &path, const Vlc::Mux &mux) |
Merge. More... | |
QString | record (const QString &name, const QString &path, const Vlc::Mux &mux, bool duplicate=false) |
Record. More... | |
QString | record (const QString &name, const QString &path, const Vlc::Mux &mux, const Vlc::AudioCodec &audioCodec, const Vlc::VideoCodec &videoCodec, bool duplicate=false) |
Record. More... | |
QString | record (const QString &name, const QString &path, const Vlc::Mux &mux, const Vlc::AudioCodec &audioCodec, const Vlc::VideoCodec &videoCodec, int bitrate, int fps, int scale, bool duplicate=false) |
Record. More... | |
void | setProgram (int program) |
Set program. More... | |
void | setOption (const QString &option) |
Set media option. More... | |
void | setOptions (const QStringList &options) |
Set media options. More... | |
Media item.
An abstract representation of a playable media. It consists of a media location and various optional meta data.
|
explicit |
VlcMedia constructor.
This constructor creates a new media instance from a media location.
location | location of the media (QString) |
localFile | true, if media is local file (bool) |
instance | main libvlc instance (VlcInstance *) |
|
explicit |
VlcMedia constructor.
This constructor creates a new media instance from a remote media location. Provided for convenience.
location | remote location of the media (QString) |
instance | main libvlc instance (VlcInstance *) |
VlcMedia::VlcMedia | ( | libvlc_media_t * | media | ) |
VlcMedia constructor.
This constructor creates a new media instance from an existing one.
media | libvlc media item (libvlc_media_t *) |
libvlc_media_t * VlcMedia::core | ( | ) |
libvlc media item
QString VlcMedia::currentLocation | ( | ) | const |
Current media location.
QString VlcMedia::duplicate | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux | ||
) |
QString VlcMedia::duplicate | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux, | ||
const Vlc::AudioCodec & | audioCodec, | ||
const Vlc::VideoCodec & | videoCodec | ||
) |
Duplicate (provided for convenience)
Apply duplicate options with desired mux and transcoding (experimental).
name | output file name (QString) |
path | output path (QString) |
mux | output mux (Vlc::Mux) |
audioCodec | audio codec (Vlc::AudioCodec) |
videoCodec | video codec (Vlc::VideoCodec) |
QString VlcMedia::duplicate | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux, | ||
const Vlc::AudioCodec & | audioCodec, | ||
const Vlc::VideoCodec & | videoCodec, | ||
int | bitrate, | ||
int | fps, | ||
int | scale | ||
) |
Duplicate (provided for convenience)
Apply duplicate options with desired mux, transcoding and some other options (experimental).
name | output file name (QString) |
path | output path (QString) |
mux | output mux (Vlc::Mux) |
audioCodec | audio codec (Vlc::AudioCodec) |
videoCodec | video codec (Vlc::VideoCodec) |
bitrate | video bitrate (int) |
fps | frames per second (int) |
scale | video scale (int) |
qint64 VlcMedia::duration | ( | ) | const |
Get media duration.
|
signal |
Signal sent on duration change.
duration | new duration |
|
signal |
Signal sent on freed.
media | freed libvlc_media_t object |
QString VlcMedia::merge | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux | ||
) |
Merge.
Apply merge options with desired mux but without transcoding.
name | output file name (QString) |
path | output path (QString) |
mux | output mux (Vlc::Mux) |
|
signal |
Signal sent on meta change.
meta | new meta |
void VlcMedia::parse | ( | ) |
Parse media information.
Parse media information: metadata and track information. This call is async.
bool VlcMedia::parsed | ( | ) | const |
Get parsed status.
Know when it is OK to read metadata and track information
|
signal |
Signal sent on parsed change.
status | new parsed status |
|
signal |
Signal sent on parsed change.
status | new parsed status |
QString VlcMedia::record | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux, | ||
bool | duplicate = false |
||
) |
Record.
Apply recording options with desired mux but without transcoding.
name | output file name (QString) |
path | output path (QString) |
mux | output mux (Vlc::Mux) |
duplicate | also duplicate on screen (bool) |
QString VlcMedia::record | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux, | ||
const Vlc::AudioCodec & | audioCodec, | ||
const Vlc::VideoCodec & | videoCodec, | ||
bool | duplicate = false |
||
) |
Record.
Apply recording options with desired mux and transcoding (experimental).
name | output file name (QString) |
path | output path (QString) |
mux | output mux (Vlc::Mux) |
audioCodec | audio codec (Vlc::AudioCodec) |
videoCodec | video codec (Vlc::VideoCodec) |
duplicate | also duplicate on screen (bool) |
QString VlcMedia::record | ( | const QString & | name, |
const QString & | path, | ||
const Vlc::Mux & | mux, | ||
const Vlc::AudioCodec & | audioCodec, | ||
const Vlc::VideoCodec & | videoCodec, | ||
int | bitrate, | ||
int | fps, | ||
int | scale, | ||
bool | duplicate = false |
||
) |
Record.
Apply recording options with desired mux, transcoding and some other options (experimental).
name | output file name (QString) |
path | output path (QString) |
mux | output mux (Vlc::Mux) |
audioCodec | audio codec (Vlc::AudioCodec) |
videoCodec | video codec (Vlc::VideoCodec) |
bitrate | video bitrate (int) |
fps | frames per second (int) |
scale | video scale (int) |
duplicate | also duplicate on screen (bool) |
void VlcMedia::setOption | ( | const QString & | option | ) |
Set media option.
option | media option (QString) |
void VlcMedia::setOptions | ( | const QStringList & | options | ) |
Set media options.
options | media options (QStringList) |
void VlcMedia::setProgram | ( | int | program | ) |
Set program.
program | program PID (int) |
Vlc::State VlcMedia::state | ( | ) | const |
Get media state.
|
signal |
Signal sent on state change.
state | new state |
|
signal |
Signal sent on subitem added.
subitem | subitem that was added |