fix(audio): remove hardcoded input device from scsynth boot options#81
Merged
dropcontrol merged 1 commit intomainfrom Feb 26, 2026
Merged
fix(audio): remove hardcoded input device from scsynth boot options#81dropcontrol merged 1 commit intomainfrom
dropcontrol merged 1 commit intomainfrom
Conversation
osc-client.ts の boot() で入力デバイス 'MacBook Airの' がハードコードされていた問題を修正。 bootOptions.device に出力デバイス名のみを文字列で渡す形に変更。 OrbitScoreは出力のみ使用するため、入力デバイスの指定は不要。 scynthのデフォルト入力デバイスに委任する。 Closes #80 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
コードレビュー概要ハードコードされた入力デバイス名 'MacBook Airの' を削除し、出力デバイス名のみを渡すように変更した修正です。変更は最小限かつ的確で、問題の根本原因に直接対処しています。 良い点
検討事項・潜在的な問題1. 出力専用デバイスでの入力チャンネル問題bootOptions.device = outputDevice と文字列で渡した場合、SuperCollider(scsynth)はその単一デバイスを入出力の両方に使用しようとします。 外付けオーディオインターフェースによっては入力端子がない(または入力チャンネル数が異なる)場合があり、scsynth が起動時に警告を出したり、クラッシュしたりする可能性があります。 より堅牢な修正案として、入力バスチャンネル数を明示的に 0 に設定することを検討できます: if (outputDevice) {
bootOptions.device = outputDevice
bootOptions.numInputBusChannels = 0 // 入力不要であることを明示
this.currentOutputDevice = outputDevice
}ただし、supercolliderjs の BootOptions 型でこのオプションが定義されているかの確認が必要です。 2. 手動テストが未完了このPRが修正しようとしているまさにそのシナリオ(外付けオーディオインターフェース使用時)の手動確認がチェックされていません。可能であれば、マージ前に実機でテストしていただくことを推奨します。 3. scsynth パスのハードコード(既存問題・スコープ外)scsynth: '/Applications/SuperCollider.app/Contents/Resources/scsynth' がハードコードされており、macOS 以外の環境では動作しません。このPRのスコープ外ですが、別Issueでの対応を検討してください。 総評
修正の方向性は正しく、コード品質も良好です。外付けオーディオインターフェースでの手動テスト確認と、必要に応じた numInputBusChannels: 0 の追加を検討してから最終マージを判断してください。 Generated with Claude Code |
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.
Summary
osc-client.tsのboot()で入力デバイス'MacBook Airの'がハードコードされていた問題を修正bootOptions.deviceに出力デバイス名のみを文字列で渡す形に変更問題
外付けオーディオインターフェース使用時、存在しない入力デバイス名
'MacBook Airの'が渡されscynthがクラッシュしていた。変更内容
Test plan
npm test- 225 passed, 23 skippednpm run build- 成功Closes #80
🤖 Generated with Claude Code