Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clamp flex EG levels #1037

Merged
merged 1 commit into from
Nov 20, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/sfizz/Defaults.cpp
Original file line number Diff line number Diff line change
@@ -157,8 +157,8 @@ BoolSpec flexEGDynamic { 0, {0, 1}, kEnforceBounds };
Int32Spec flexEGSustain { 0, {0, 100}, kEnforceLowerBound|kPermissiveUpperBound };
FloatSpec flexEGPointTime { 0.0f, {0.0f, 100.0f}, kPermissiveBounds };
FloatSpec flexEGPointTimeMod { 0.0f, {-100.0f, 100.0f}, kPermissiveBounds };
FloatSpec flexEGPointLevel { 0.0f, {-1.0f, 1.0f}, kPermissiveBounds };
FloatSpec flexEGPointLevelMod { 0.0f, {-1.0f, 1.0f}, kPermissiveBounds };
FloatSpec flexEGPointLevel { 0.0f, {-1.0f, 1.0f}, kEnforceBounds };
FloatSpec flexEGPointLevelMod { 0.0f, {-1.0f, 1.0f}, kEnforceBounds };
FloatSpec flexEGPointShape { 0.0f, {-100.0f, 100.0f}, kPermissiveBounds };
Int32Spec sampleQuality { 2, {0, 10}, 0 };
Int32Spec oscillatorQuality { 1, {0, 3}, 0 };
2 changes: 1 addition & 1 deletion tests/RegionValuesT.cpp
Original file line number Diff line number Diff line change
@@ -3406,7 +3406,7 @@ TEST_CASE("[Values] Flex EGs")
"/region0/eg0/point0/time,f : { 0.1 }",
"/region0/eg0/point0/level,f : { 0.5 }",
"/region0/eg0/point1/time,f : { 0.4 }",
"/region0/eg0/point1/level,f : { 2 }",
"/region0/eg0/point1/level,f : { 1 }", // Level values in EGs are clamped in Sforzando
"/region0/eg1/point0/time,f : { 4 }",
"/region0/eg1/point0/level,f : { 0.1 }",
};