mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-03 14:08:56 +00:00
parent
5dbeabcb76
commit
d0bc110836
2 changed files with 10 additions and 0 deletions
|
@ -359,6 +359,15 @@ Player::Player(QObject *parent, VideoRenderer *renderer)
|
|||
gst_player_set_subtitle_track_enabled(player_, false);
|
||||
}
|
||||
|
||||
Player::~Player()
|
||||
{
|
||||
if (player_) {
|
||||
g_signal_handlers_disconnect_by_data(player_, this);
|
||||
gst_player_stop(player_);
|
||||
g_object_unref(player_);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
Player::onStateChanged(Player * player, GstPlayerState state)
|
||||
{
|
||||
|
|
|
@ -62,6 +62,7 @@ class Player : public QObject
|
|||
|
||||
public:
|
||||
explicit Player(QObject *parent = 0, VideoRenderer *renderer = 0);
|
||||
virtual ~Player();
|
||||
|
||||
typedef GstPlayerError Error;
|
||||
enum State {
|
||||
|
|
Loading…
Reference in a new issue