Skip to content

Commit

Permalink
add new nosimd property
Browse files Browse the repository at this point in the history
  • Loading branch information
dromer committed Dec 13, 2024
1 parent 7292103 commit c01d4bd
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Source/Heavy/DPFExporter.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class DPFExporter : public ExporterBase {
Value exportTypeValue = Value(var(1));
Value pluginTypeValue = Value(var(1));

Value disableSIMD = Value(var(0));

PropertiesPanelProperty* midiinProperty;
PropertiesPanelProperty* midioutProperty;

Expand Down Expand Up @@ -50,6 +52,10 @@ class DPFExporter : public ExporterBase {
pluginFormats.add(new PropertiesPanel::BoolComponent("JACK", jackEnableValue, { "No", "Yes" }));
jackEnableValue.addListener(this);

PropertiesArray pro_properties;

pro_properties.add(new PropertiesPanel::BoolComponent("Disable SIMD", disableSIMD, { "No", "Yes" }));

for (auto* property : properties) {
property->setPreferredHeight(28);
}
Expand All @@ -63,6 +69,7 @@ class DPFExporter : public ExporterBase {

panel.addSection("DPF", properties);
panel.addSection("Plugin formats", pluginFormats);
panel.addSection("Advanced", pro_properties);
}

ValueTree getState() override
Expand All @@ -82,6 +89,7 @@ class DPFExporter : public ExporterBase {
stateTree.setProperty("jackEnableValue", getValue<int>(jackEnableValue), nullptr);
stateTree.setProperty("exportTypeValue", getValue<int>(exportTypeValue), nullptr);
stateTree.setProperty("pluginTypeValue", getValue<int>(pluginTypeValue), nullptr);
stateTree.setProperty("disableSIMD", getValue<int>(disableSIMD), nullptr);

return stateTree;
}
Expand All @@ -103,6 +111,7 @@ class DPFExporter : public ExporterBase {
jackEnableValue = tree.getProperty("jackEnableValue");
exportTypeValue = tree.getProperty("exportTypeValue");
pluginTypeValue = tree.getProperty("pluginTypeValue");
disableSIMD = tree.getProperty("disableSIMD");
}

void valueChanged(Value& v) override
Expand Down Expand Up @@ -149,6 +158,8 @@ class DPFExporter : public ExporterBase {
bool clap = getValue<int>(clapEnableValue);
bool jack = getValue<int>(jackEnableValue);

bool nosimd = getValue<int>(disableSIMD);

StringArray formats;

if (lv2) {
Expand Down Expand Up @@ -191,6 +202,7 @@ class DPFExporter : public ExporterBase {
}

metaJson->setProperty("dpf", metaDPF);
metaJson->setProperty("nosimd", nosimd);

args.add("-m" + createMetaJson(metaJson));

Expand Down

0 comments on commit c01d4bd

Please sign in to comment.