Repository navigation
Fix APIUI sensor queries after remapping or disabling - #1397
Open
Ramji-Purwar wants to merge 1 commit into
Open
Ramji-Purwar wants to merge 1 commit into
Ramji-Purwar wants to merge 1 commit into
Conversation
Exclude inactive sensor mappings from converter and parameter-type queries while retaining them for reuse by setters. Expose the selected CurveZoneControl activation state through its existing virtual getter. Cover both sensor types, all four curves, remapping, disabling, reactivation, and propagation with a standalone regression test.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
After an APIUI parameter is remapped from accelerometer X to Y,
getAccConverter()still reports the old X axis, curve, and bounds. Disabling the mapping with axis-1also leavesgetParamType()reporting an accelerometer. Gyroscope mappings behave the same way, and a disabled accelerometer can hide an active gyroscope in type queries.Keep inactive mappings available for reuse by setters, but filter them from converter and type queries. Implement
CurveZoneControl::getActive()using the selected curve's state so those queries agree with the mappings that actually receive sensor updates.Validation with GCC 16.2.1 on Linux x86_64:
make -C tests/apiui-tests checkpasses all 80 checks. It covers both sensor kinds, metadata initialization, axis changes, disabling, reactivation across all four curves, and sensor propagation.FAUSTFLOAT=doubleand with libstdc++ debug containers.make -C tests/mapui-tests checkpasses for all seven controls.Compatibility was also checked by applying the change to current
master-dev(f06f2697): all 80 checks pass in float and double precision, and the seven-control MapUI regression passes.AddressSanitizer/UndefinedBehaviorSanitizer validation could not run because the installed compiler's sanitizer runtime libraries are missing. No Faust compiler source or generated DSP code is changed.