Commit bdfc2a3b authored by Thomas Guillem's avatar Thomas Guillem Committed by Jean-Baptiste Kempf
Browse files

qt: add "mix-mode" menu

parent ec53b544
......@@ -453,6 +453,7 @@ QMenu *VLCMenuBar::AudioMenu( intf_thread_t *p_intf, QMenu * current )
});
current->addMenu( new CheckableListMenu(qtr( "&Stereo Mode" ), THEMIM->getAudioStereoMode(), CheckableListMenu::GROUPED, current) );
current->addMenu( new CheckableListMenu(qtr( "&Mix Mode" ), THEMIM->getAudioMixMode(), CheckableListMenu::GROUPED, current) );
current->addSeparator();
current->addMenu( new CheckableListMenu(qtr( "&Visualizations" ), THEMIM->getAudioVisualizations(), CheckableListMenu::GROUPED, current) );
......
......@@ -296,6 +296,7 @@ static void on_player_state_changed(vlc_player_t *, enum vlc_player_state state,
msg_Dbg( that->p_intf, "on_player_state_changed VLC_PLAYER_STATE_PLAYING");
PlayerController::AoutPtr aout = q->getAout();
that->m_audioStereoMode.resetObject( aout.get() );
that->m_audioMixMode.resetObject( aout.get() );
that->m_audioVisualization.resetObject( aout.get() );
break;
}
......@@ -310,6 +311,7 @@ static void on_player_state_changed(vlc_player_t *, enum vlc_player_state state,
msg_Dbg( that->p_intf, "on_player_state_changed VLC_PLAYER_STATE_STOPPED");
that->m_audioStereoMode.resetObject((audio_output_t*)nullptr);
that->m_audioMixMode.resetObject((audio_output_t*)nullptr);
that->m_audioVisualization.resetObject((audio_output_t*)nullptr);
/* reset the state on stop */
......@@ -1019,6 +1021,7 @@ PlayerControllerPrivate::PlayerControllerPrivate(PlayerController *playercontrol
, m_deinterlaceMode((vout_thread_t*)nullptr, "deinterlace-mode")
, m_autoscale((vout_thread_t*)nullptr, "autoscale")
, m_audioStereoMode((audio_output_t*)nullptr, "stereo-mode")
, m_audioMixMode((audio_output_t*)nullptr, "mix-mode")
, m_audioDeviceList(m_player)
, m_audioVisualization((audio_output_t*)nullptr, "visual")
{
......@@ -1826,6 +1829,7 @@ QABSTRACTLIST_GETTER( VLCVarChoiceModel, getCrop, m_crop)
QABSTRACTLIST_GETTER( VLCVarChoiceModel, getDeinterlace, m_deinterlace)
QABSTRACTLIST_GETTER( VLCVarChoiceModel, getDeinterlaceMode, m_deinterlaceMode)
QABSTRACTLIST_GETTER( VLCVarChoiceModel, getAudioStereoMode, m_audioStereoMode)
QABSTRACTLIST_GETTER( VLCVarChoiceModel, getAudioMixMode, m_audioMixMode)
QABSTRACTLIST_GETTER( VLCVarChoiceModel, getAudioVisualizations, m_audioVisualization)
......
......@@ -176,6 +176,7 @@ public:
Q_PROPERTY(bool muted READ isMuted WRITE setMuted NOTIFY soundMuteChanged)
Q_PROPERTY(AudioDeviceModel* audioDevices READ getAudioDevices CONSTANT)
Q_PROPERTY(VLCVarChoiceModel* audioStereoMode READ getAudioStereoMode CONSTANT)
Q_PROPERTY(VLCVarChoiceModel* audioMixMode READ getAudioMixMode CONSTANT)
Q_PROPERTY(VLCVarChoiceModel* audioVisualization READ getAudioVisualizations CONSTANT)
Q_PROPERTY(bool hasAudioVisualization READ hasAudioVisualization NOTIFY hasAudioVisualizationChanged)
......@@ -347,6 +348,7 @@ public slots:
void setMuted( bool muted );
AudioDeviceModel* getAudioDevices();
VLCVarChoiceModel* getAudioStereoMode();
VLCVarChoiceModel* getAudioMixMode();
VLCVarChoiceModel* getAudioVisualizations();
bool hasAudioVisualization() const;
......
......@@ -142,6 +142,7 @@ public:
//aout properties
VLCVarChoiceModel m_audioStereoMode;
VLCVarChoiceModel m_audioMixMode;
float m_volume = 0.f;
bool m_muted = false;
AudioDeviceModel m_audioDeviceList;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment