-
Notifications
You must be signed in to change notification settings - Fork 2
FCE-2591: Apply default audio filters #459
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
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR implements default audio filters for mobile clients by introducing Google-specific audio processing constraints. These defaults can be overridden by users through custom audio constraints.
Changes:
- Added new
constraints.tsmodule with default mobile audio constraints and merge logic - Modified
FishjamProviderto automatically apply default audio constraints - Exported
DEFAULT_MOBILE_AUDIO_CONSTRAINTSfor user reference
Reviewed changes
Copilot reviewed 2 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| packages/mobile-client/src/constraints.ts | New file defining default Google audio processing constraints and merge function |
| packages/mobile-client/src/index.ts | Updated to import and apply default audio constraints in FishjamProvider |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
packages/mobile-client/src/index.ts
Outdated
| const mergedConstraints = React.useMemo(() => { | ||
| return { | ||
| ...props.constraints, | ||
| audio: mergeMobileAudioConstraints(props.constraints?.audio), | ||
| }; | ||
| }, [props.constraints]); |
Copilot
AI
Jan 22, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The useMemo dependency array uses the entire props.constraints object. Since objects are compared by reference, this will cause the memo to recalculate on every render even if the constraints haven't actually changed. Consider using a more granular dependency or accepting that this is intentional behavior.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…ud/web-client-sdk into FCE-2591/apply-audio-filters
Description
Apply default audio filters that can be overwritten by the user.
Documentation impact
Types of changes
not work as expected)