obs-studio/obs/volume-control.hpp
jp9000 52746c2523 Add (temporary terrible) volume controls
- Add volume control

   These volume controls are basically nothing more than sliders.  They
   look terrible and hopefully will be as temporary as they are
   terrible.

 - Allow saving of specific non-user sources via obs_load_source and
   obs_save_source functions.

 - Save data of desktop/mic audio sources (sync data, volume data, etc),
   and load the data on startup.

 - Make it so that a scene is created by default if first time using the
   application.  On certain operating systems where supported, a default
   capture will be created.  Desktop capture on mac, particularly.  Not
   sure what to do about windows because monitor capture on windows 7 is
   completely terrible and is bad to start users off with.
2014-05-03 22:54:38 -07:00

33 lines
567 B
C++

#pragma once
#include <obs.hpp>
#include <QWidget>
/* TODO: Make a real volume control that isn't terrible */
class QLabel;
class QSlider;
class VolControl : public QWidget {
Q_OBJECT
private:
OBSSource source;
QLabel *nameLabel;
QLabel *volLabel;
QSlider *slider;
bool signalChanged;
static void OBSVolumeChanged(void *param, calldata_t calldata);
private slots:
void VolumeChanged(int vol);
void SliderChanged(int vol);
public:
VolControl(OBSSource source);
~VolControl();
inline obs_source_t GetSource() const {return source;}
};