mirror of
https://github.com/lostjared/Acid.Cam.v2.Qt.git
synced 2025-12-05 14:30:03 +01:00
update
This commit is contained in:
@@ -13,6 +13,8 @@
|
||||
#include <opencv2/core/ocl.hpp>
|
||||
|
||||
std::unordered_map<std::string, FilterValue> filter_map;
|
||||
std::unordered_map<std::string, int> filter_map_main;
|
||||
std::vector<std::string> solo_filter;
|
||||
void custom_filter(cv::Mat &);
|
||||
|
||||
const char *filter_names[] = { "AC Self AlphaBlend", "Reverse Self AlphaBlend",
|
||||
@@ -72,6 +74,9 @@ void generate_map() {
|
||||
std::string name = "plugin " + plugins.plugin_list[j]->name();
|
||||
filter_map[name] = FilterValue(2, j, -1);
|
||||
}
|
||||
|
||||
filter_map_main = ac::filter_map;
|
||||
solo_filter = ac::solo_filter;
|
||||
}
|
||||
|
||||
|
||||
@@ -1866,9 +1871,9 @@ void AC_MainWindow::save_CustomFile() {
|
||||
void AC_MainWindow::setRandomFilterValue() {
|
||||
menu_cat->setCurrentIndex(0);
|
||||
resetMenu();
|
||||
int index = rand()%ac::solo_filter.size();
|
||||
std::string filter_name = ac::solo_filter[index];
|
||||
int filter_index = ac::filter_map[filter_name];
|
||||
int index = rand()%solo_filter.size();
|
||||
std::string filter_name = solo_filter[index];
|
||||
int filter_index = filter_map_main[filter_name];
|
||||
filters->setCurrentIndex(filter_index);
|
||||
}
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ void OptionsWindow::setValues() {
|
||||
if(delay_value > 0)
|
||||
playback->setCustomCycleDelay(delay_value);
|
||||
|
||||
ac::setMaxAllocated(max_frames);
|
||||
playback->setMaxAlloc(max_frames);
|
||||
QString text;
|
||||
|
||||
int level_ = atoi(level->text().toStdString().c_str());
|
||||
@@ -75,8 +75,8 @@ void OptionsWindow::setValues() {
|
||||
QMessageBox::information(this, tr("Error requires valid level/wait"), tr("Requires Level/Intensity greater than zero value"));
|
||||
return;
|
||||
}
|
||||
ac::setVariableWait(wait_);
|
||||
ac::setColorLevel(level_);
|
||||
|
||||
playback->setWaitColorLevel(wait_, level_);
|
||||
QTextStream stream(&text);
|
||||
stream << tr("Thread Count set to: ") << thread_count << tr(" and Intensity set to: ") << intensity << tr("\nMaximum Stored Frames: ") << max_frames << tr("\n") << tr("Delay: ") << delay_value << "\n" << tr("Wait: ") << wait_ << "\n" << tr("Level: ") << level_ << "\n";
|
||||
QMessageBox::information(this, tr("Pref Value Set"), text);
|
||||
|
||||
@@ -159,6 +159,13 @@ unsigned long Playback::allocatedFrames() {
|
||||
|
||||
}
|
||||
|
||||
void Playback::setWaitColorLevel(int w, int l) {
|
||||
mutex.lock();
|
||||
ac::setVariableWait(w);
|
||||
ac::setColorLevel(l);
|
||||
mutex.unlock();
|
||||
}
|
||||
|
||||
void Playback::setSubFilter_(int s) {
|
||||
mutex.lock();
|
||||
ac::setSubFilter(s);
|
||||
|
||||
@@ -66,6 +66,7 @@ public:
|
||||
void setMaxAlloc(int a);
|
||||
unsigned int getObjectSize();
|
||||
unsigned long allocatedFrames();
|
||||
void setWaitColorLevel(int c, int l);
|
||||
void setColorMap(int c);
|
||||
void setPngPath(std::string path);
|
||||
void Play();
|
||||
|
||||
Reference in New Issue
Block a user