m_configShuttle.shuttledisabled->hide();
// Store the button pointers into an array for easier handling them in the other functions.
+ // TODO: impl enumerator or live with cut and paste :-)))
m_shuttle_buttons.push_back(m_configShuttle.shuttle1);
m_shuttle_buttons.push_back(m_configShuttle.shuttle2);
m_shuttle_buttons.push_back(m_configShuttle.shuttle3);
m_shuttle_buttons.push_back(m_configShuttle.shuttle4);
m_shuttle_buttons.push_back(m_configShuttle.shuttle5);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle6);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle7);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle8);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle9);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle10);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle11);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle12);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle13);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle14);
+ m_shuttle_buttons.push_back(m_configShuttle.shuttle15);
// populate the buttons with the current configuration. The items are sorted
// according to the user-selected language, so they do not appear in random order.
QWidget *p6 = new QWidget;
m_configSdl.setupUi(p6);
+ m_configSdl.reload_blackmagic->setIcon(KIcon("view-refresh"));
+ connect(m_configSdl.reload_blackmagic, SIGNAL(clicked(bool)), this, SLOT(slotReloadBlackMagic()));
#ifndef USE_OPENGL
m_configSdl.kcfg_openglmonitors->setHidden(true);
m_configSdl.kcfg_video_driver->addItem(i18n("Ascii art library"), "aalib");
#endif
- // Fill the list of audio playback devices
+ // Fill the list of audio playback / recording devices
m_configSdl.kcfg_audio_device->addItem(i18n("Default"), QString());
m_configCapture.kcfg_rmd_alsa_device->addItem(i18n("Default"), QString());
+ m_configCapture.kcfg_v4l_alsadevice->addItem(i18n("Default"), "default");
if (!KStandardDirs::findExe("aplay").isEmpty()) {
m_readProcess.setOutputChannelMode(KProcess::OnlyStdoutChannel);
m_readProcess.setProgram("aplay", QStringList() << "-l");
} else {
// If aplay is not installed on the system, parse the /proc/asound/pcm file
QFile file("/proc/asound/pcm");
- if (file.open(QIODevice::ReadOnly)) {
+ if (file.open(QIODevice::ReadOnly | QIODevice::Text)) {
QTextStream stream(&file);
- QString line;
+ QString line = stream.readLine();
QString deviceId;
- while (!stream.atEnd()) {
- line = stream.readLine();
+ while (!line.isNull()) {
if (line.contains("playback")) {
deviceId = line.section(':', 0, 0);
m_configSdl.kcfg_audio_device->addItem(line.section(':', 1, 1), "plughw:" + QString::number(deviceId.section('-', 0, 0).toInt()) + ',' + QString::number(deviceId.section('-', 1, 1).toInt()));
m_configCapture.kcfg_rmd_alsa_device->addItem(line.section(':', 1, 1).simplified(), "plughw:" + QString::number(deviceId.section('-', 0, 0).toInt()) + ',' + QString::number(deviceId.section('-', 1, 1).toInt()));
m_configCapture.kcfg_v4l_alsadevice->addItem(line.section(':', 1, 1).simplified(), "hw:" + QString::number(deviceId.section('-', 0, 0).toInt()) + ',' + QString::number(deviceId.section('-', 1, 1).toInt()));
}
+ line = stream.readLine();
}
file.close();
- }
+ } else kDebug()<<" / / / /CANNOT READ PCM";
}
// Add pulseaudio capture option
int fd;
for (int i = 0; i < 30; i++) {
QString filename = baseName + QString::number(i);
- kDebug() << "/// CHECKING OFR: " << filename;
+ kDebug() << "/// CHECKING device: " << filename;
char name[256] = "unknown";
fd = KDE_open((char *) filename.toUtf8().data(), O_RDONLY);
delete w;
}
-
+void KdenliveSettingsDialog::slotReloadBlackMagic()
+{
+ Render::getBlackMagicDeviceList(m_configCapture.kcfg_decklink_capturedevice, true);
+ if (!Render::getBlackMagicOutputDeviceList(m_configSdl.kcfg_blackmagic_output_device), true) {
+ // No blackmagic card found
+ m_configSdl.kcfg_external_display->setEnabled(false);
+ }
+ m_configSdl.kcfg_external_display->setEnabled(KdenliveSettings::decklink_device_found());
+}
#include "kdenlivesettingsdialog.moc"