{"id":31228212,"url":"https://github.com/banghuazhao/piano","last_synced_at":"2026-04-13T21:32:35.497Z","repository":{"id":314090994,"uuid":"1052077391","full_name":"banghuazhao/Piano","owner":"banghuazhao","description":"A simple iOS piano keyboard built with SwiftUI and AVAudioEngine","archived":false,"fork":false,"pushed_at":"2025-09-17T10:48:09.000Z","size":10439,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-07T09:27:54.320Z","etag":null,"topics":["audio","ios","iosgames","midi","music","mvvm","piano","piano-keyboard","sf2","swift","swiftui"],"latest_commit_sha":null,"homepage":"https://apps.apple.com/us/app/pianoflow-keyboard/id6752531110","language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/banghuazhao.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-07T11:05:25.000Z","updated_at":"2025-09-23T18:37:29.000Z","dependencies_parsed_at":"2025-09-10T15:52:27.620Z","dependency_job_id":"a6a7cd0c-f759-41ee-961e-618af0aea2fc","html_url":"https://github.com/banghuazhao/Piano","commit_stats":null,"previous_names":["banghuazhao/piano"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/banghuazhao/Piano","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banghuazhao%2FPiano","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banghuazhao%2FPiano/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banghuazhao%2FPiano/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banghuazhao%2FPiano/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/banghuazhao","download_url":"https://codeload.github.com/banghuazhao/Piano/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/banghuazhao%2FPiano/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31771832,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-13T20:17:16.280Z","status":"ssl_error","status_checked_at":"2026-04-13T20:17:08.216Z","response_time":93,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["audio","ios","iosgames","midi","music","mvvm","piano","piano-keyboard","sf2","swift","swiftui"],"created_at":"2025-09-22T05:58:18.614Z","updated_at":"2026-04-13T21:32:35.460Z","avatar_url":"https://github.com/banghuazhao.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"## 🎹 PianoFlow\n\nA modern, responsive iOS piano keyboard built with SwiftUI and AVAudioEngine. Features a scrollable 7-octave keyboard with customizable settings, haptic feedback, and realistic piano sound using SoundFont technology.\n\n\u003cimg src=\"screenshots/1.png\" alt=\"Piano screenshot\" width=\"480\" /\u003e\n\n### 📲 Download on the App Store\n\n- iOS: [PianoFlow on the App Store](https://apps.apple.com/us/app/pianoflow-keyboard/id6752531110)\n\n### ✨ Features\n- **🎹 7-Octave Keyboard**: Full piano range from C1 to B7 with smooth horizontal scrolling\n- **🧭 Interactive Navigation**: Octave buttons and scroll slider for quick navigation\n- **⚙️ Customizable Settings**: Adjustable key width, key name display options, and haptic feedback\n- **🎵 Realistic Audio**: SoundFont-backed piano sound with low-latency playback\n- **📱 Modern UI**: SwiftUI interface with responsive keys and smooth animations\n- **🏗️ MVVM Architecture**: Clean separation with `@Observable` view models and Swift concurrency\n\n### 🏗️ Architecture\n- **📋 Pattern**: MVVM with Swift concurrency\n- **🎛️ ViewModel**: `@Observable` and `@MainActor`-scoped for UI-safe state management\n- **🔊 Audio**: `AVAudioEngine` + `AVAudioUnitSampler` for SoundFont playback\n- **💾 State Management**: User preferences stored with `@AppStorage`\n\n**🔄 Data Flow**:\n- 📱 `PianoView` renders the scrollable keyboard and handles user interactions\n- 🎚️ `PianoViewModel` manages key state, scroll position, and audio playback\n- 🔊 `AudioEngine` service handles audio session and SoundFont loading\n- ⚙️ `SettingsView` provides customization options with persistent storage\n\n### 🛠️ Requirements\n- 💻 Xcode 15 or later\n- 📱 iOS 17 or later (SwiftUI `@Observable` macro)\n- 🖥️ macOS Sonoma or later for development\n\n### 🚀 Getting Started\n1. 📥 Clone the repository\n```bash\ngit clone https://github.com/banghuazhao/PianoFlow.git\ncd PianoFlow\n```\n2. 🔧 Open the project in Xcode\n```bash\nopen Piano.xcodeproj\n```\n3. ▶️ Select the `Piano` scheme and a simulator or device, then Run.\n\n**📝 Note**: If you replace the SoundFont, put your `.sf2` file in `Piano/Sound/` and update the load call if needed.\n\n### 📁 Project Structure\n```text\nPiano/\n  App/                 # 🚀 App entry point (`PianoApp.swift`)\n  Sound/               # 🎵 SoundFont file (`Piano.sf2`)\n  Assets.xcassets/     # 🎨 App icons and colors\n  Config/              # ⚙️ Build configurations\n  Model/               # 📋 `PianoKey`, `PianoNote`, `OctaveColor`\n  Service/             # 🔊 `AudioEngine` for audio playback\n  View/                # 📱 `PianoView`, `PianoKeyView`, `SettingsView`\n  ViewModel/           # 🎛️ `PianoViewModel` with @Observable\n```\n\n### 🎼 Usage\n- **🎹 Playing Notes**: Tap any key to play piano notes with realistic sound\n- **🧭 Navigation**: \n  - Use octave buttons (C1-C7) to jump to specific octaves\n  - Drag the scroll slider to navigate smoothly across the keyboard\n  - Swipe horizontally on the keyboard for fine control\n- **⚙️ Settings**: Tap the gear icon to access:\n  - Key width adjustment (30-80 points)\n  - Show/hide key names on keys\n  - Toggle haptic feedback\n  - Octave-specific key name display options\n- **🎨 Customization**: Replace `Piano.sf2` with your own SoundFont file to change the piano sound\n\n### 🗺️ Roadmap\n- **👆 Multi-touch Support**: Enhanced chord playing with multiple simultaneous notes\n- **🎛️ Sustain Pedal**: Virtual sustain pedal functionality\n- **🎹 MIDI Support**: MIDI input/output for external controllers\n- **🎙️ Recording**: Basic recording and playback capabilities\n- **✨ Visual Feedback**: Enhanced visual indicators for active notes\n- **🎚️ Custom Key Ranges**: Configurable octave ranges and key layouts\n\n### 🤝 Contributing\n- 📝 Open an issue or pull request on GitHub\n- 🏗️ Follow MVVM architecture with `@Observable` view models and Swift concurrency\n- 🔧 Prefer small, well-scoped changes\n- 📚 Maintain consistent code style and documentation\n\n### 📄 License\nNo license file is included yet. If you intend to use this project beyond personal use, please add a license.\n\n### 🙏 Acknowledgements\n- 🛠️ Built with SwiftUI and AVFoundation\n- 🎵 Uses a bundled SoundFont file (`Piano.sf2`). Replace with your own if licensing requires.\n- ©️ Copyright Apps Bay Limited. All rights reserved.\n\n### 🔗 Links\n- 📦 Repository: `https://github.com/banghuazhao/PianoFlow`\n- 🛍️ App Store: `https://apps.apple.com/us/app/pianoflow-keyboard/id6752531110`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbanghuazhao%2Fpiano","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbanghuazhao%2Fpiano","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbanghuazhao%2Fpiano/lists"}