Skip to content
Open
Show file tree
Hide file tree
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
13 changes: 0 additions & 13 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,19 +39,6 @@ Thank you for your interest in contributing to this project! We welcome contribu

## Important Rules

### AI-Generated Code Policy

**AI-generated code is acceptable, but please make sure you have thoroughly reviewed and understand what it does.**

When using AI tools to generate code:
- Review every line of generated code carefully
- Understand the logic and potential implications
- Test the code thoroughly in your environment
- Ensure it follows project conventions and best practices
- Take responsibility for any issues that may arise from the generated code

***IMPORTANT: Don't trust AI generated tests. Test each modifications manually.***

### Code Review Process

- All contributions must go through code review
Expand Down
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,7 @@ app/.externalNativeBuild/
.cxx/

# agent files
AGENTS.md
AGENTS.md

# Claude Code configuration
.claude/
123 changes: 60 additions & 63 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,84 +1,81 @@
# Artemis Android
# Diana OSC Suite

Previously named Moonlight Noir
A fork of [Artemis](https://github.com/ClassicOldSong/moonlight-android) with comprehensive On-Screen Controller (OSC) enhancements and foldable device support.

An open source client for [Apollo](https://github.com/ClassicOldSong/Apollo)/[Sunshine](https://github.com/LizardByte/Sunshine).
## What Makes Diana Different?

Artemis Android will allow you to stream your collection of games from your Windows PC to your Android device,
whether in your own home or over the internet.
Diana extends Artemis with two major feature sets:

Artemis is currently the best fork of Moonlight with loads of optimizations for office usage.
### 1. Robust OSC Profile System
- **Per-Game Profiles**: Set default OSC layouts per game - automatically loads when you start each game
- **Unlimited Profiles**: Create, save, and switch between controller layouts on-the-fly
- **Paired Sizing**: Resize all buttons in a subset together (Face Buttons, Triggers, Shoulders, etc.)
- **Smart Snapping**: Buttons snap to edges, grid intervals, and other buttons for perfect alignment
- **Deposited Buttons**: Add keyboard keys (A-Z, 0-9), mouse buttons, and control keys to your layout
- **Profile Overlay**: Always know which profile you're using during configuration

A more seamless experience with virtual display will be Artemis paired with [Apollo](https://github.com/ClassicOldSong/Apollo).
### 2. Foldable Cover Screen Support
- **Dedicated Trigger Controller**: 4-button layout (ZL/LB/RB/ZR) optimized for cover screens
- **Analog Trigger Emulation**: Full 0-255 pressure sensitivity with slide buttons
- **Haptic + Audio Feedback**: Mechanical click sound and vibration at snap threshold
- **Visual Indicators**: Main-screen display showing cover button states and pressure levels

# Features
## Quick Start

If you switch back to the main stream version, you'll be missing the following awesome features which are very unlikely to be added there:
### OSC Profile Management

1. Custom virtual buttons with import and export support.
2. [Custom resolutions](https://github.com/moonlight-stream/moonlight-android/pull/1349).
3. Custom bitrates.
4. [Multiple mouse mode switching](https://github.com/moonlight-stream/moonlight-android/pull/1304) (normal mouse, [multi-touch](https://github.com/moonlight-stream/moonlight-android/pull/1364), touchpad, disabled, local cursor mode).
5. Optimized virtual gamepad skins and free joystick.
6. External monitor mode.
7. Joycon D-pad support.
8. Simplified performance information display.
9. [Game back menu](https://github.com/moonlight-stream/moonlight-android/pull/1171).
10. Custom shortcut commands.
11. Easy soft keyboard switching.
12. Portrait mode.
13. Display on top mode, useful for foldable phones.
14. [Virtual touchpad space and sensitivity adjustment](https://github.com/moonlight-stream/moonlight-android/issues/1348#issuecomment-2236344729) for playing right-click view games, such as Warcraft.
15. Force use device's own vibration motor (in case your gamepad's vibration is not effective).
16. Gamepad debugging page to view gamepad vibration and gyroscope information, as well as Android kernel version information.
17. Trackpad tap/scrolling support
18. Natural track pad mode with touch screen
19. Non-QWERTY keyboard layout support
20. Quick Meta key with physical BACK button
21. Frame rate lock fix for some devices
22. Video scale mode: Fit/Fill/Stretch
23. View pan/zoom support
24. Rotate screen in-game
25. Add option to quit app directly
26. Samsung DeX scrolling support
27. Proper click/scroll/right-click for trackpad on generic Android tablet when using local cursor
28. Virtual Display integration with [Apollo](https://github.com/ClassicOldSong/Apollo)
29. Server Command integration with [Apollo](https://github.com/ClassicOldSong/Apollo)
30. Clipboard sync (requires Apollo)
31. SBS 3D for external Displays (Using AI MiDaS v2 Lite)
**Set Per-Game Default Profiles**:
1. Long-press a game in your game list
2. Tap "OSC Profile"
3. Select a profile - it will auto-load when starting that game

# Disclaimer
**Create & Manage Profiles** (In-Game):
1. Open Quick Menu → "OSC Profiles"
2. Create new profiles with custom names
3. Configure buttons (move/resize/enable-disable)
4. Save changes manually (Under Manage Profiles)
5. Switch between profiles instantly

This is the `go away` version of Moonlight Android.
**Profile Features**:
- **Snapping** (Volume Down in Move mode): Align buttons to edges/grid/other buttons
- **Paired Sizing** (Volume Up in Resize mode): Resize button groups together
- **Deposit Buttons**: Add keyboard/mouse buttons via Quick Menu → OSC Settings → "Deposit Alternate Buttons"

I got kicked from Moonlight and Sunshine's Discord server literally for helping people out.
### Cover Screen Triggers (Foldables)

This is what I got for finding a bug, opened an issue, getting no response, troubleshoot myself, fixed the issue myself, shared it by PR to the main repo hoping my efforts can help someone else during the maintainance gap.
**Setup**:
1. Unfold device (FLAT mode)
2. Triggers activate automatically (ZL/LB on left, RB/ZR on right)

Yes, I'm going away. Fixes and improvements on this fork are not necessarily be merged to the main repo either. I have also started [a fork of Sunshine called Apollo](https://github.com/ClassicOldSong/Apollo) and will add useful features that will never get merged by the main repo shortly. [Apollo](https://github.com/ClassicOldSong/Apollo) and [Moonlight Noir](https://github.com/ClassicOldSong/moonlight-android) will no longer be compatible with OG Sunshine and OG Moonlight eventually, but they'll work even better with much more carefully designed features.

The main repo had stayed silent for 5 months, with nobody actually responding to issues, and people are getting totally no help besides the limited FAQ in their Discord server. I tried to answer issues and questions, solve problems within my ablilty but I got kicked out just for helping others.
**Analog Mode** (default):
- Slide outward toward edge to 'depress' trigger (ZR slides right, ZL slides left)
- Pressure increases as you slide further (0-254)
- Reaches 85%: Auto-snaps to max (255) with click + vibration
- Continuous vibration scales with pressure to emulate trigger spring vibration

**PRs for feature improvements are welcomed here unlike the main repo, your ideas are more likely to be appreciated and your efforts are actually being respected. We welcome people who can and willing to share their efforts, helping yourselves and other people in need.**
**Digital Mode**:
- Toggle via Game Menu → "Toggle Cover Triggers Mode"
- Simple tap on/off behavior

**Update**: They have contacted me and apologized for this incident, but the fact it **happened** still motivated me to start my own fork.
**Visual Feedback**:
- Main screen shows 4-color indicator (blue/purple/red/orange)
- Brightness reflects trigger pressure
- Configurable like other OSC elements

## Downloads
* [Download APK directly](https://github.com/ClassicOldSong/moonlight-android/releases)
* [Use Obtainium](https://apps.obtainium.imranr.dev/redirect?r=obtainium://app/%7B%22id%22%3A%22com.limelight.noir%22%2C%22url%22%3A%22https%3A%2F%2Fgithub.com%2FClassicOldSong%2Fmoonlight-android%22%2C%22author%22%3A%22ClassicOldSong%22%2C%22name%22%3A%22Artemis%22%2C%22additionalSettings%22%3A%22%7B%5C%22apkFilterRegEx%5C%22%3A%5C%22nonRoot%5C%22%2C%5C%22matchGroutToUse%5C%22%3A%5C%22%241%5C%22%2C%5C%22versionExtractionRegEx%5C%22%3A%5C%22v(.%2B)%5C%22%7D%22%7D) (recommended)

## Building
* Install Android Studio and the Android NDK
* Run ‘git submodule update --init --recursive’ from within moonlight-android/
* In moonlight-android/, create a file called ‘local.properties’. Add an ‘ndk.dir=’ property to the local.properties file and set it equal to your NDK directory.
* Build the APK using Android Studio or gradle
## Technical Notes

## Authors
- **Version**: 0.56-multitouch (Build 82)
- **Min SDK**: Android 5.0+ (Cover features require 7.0+)
- **Installation**: Same as Artemis - download APK and install
- **Compatibility**: All Artemis and Moonlight features preserved

* [Cameron Gutman](https://github.com/cgutman)
* [Diego Waxemberg](https://github.com/dwaxemberg)
* [Aaron Neyer](https://github.com/Aaronneyer)
* [Andrew Hennessy](https://github.com/yetanothername)
## Credits

Moonlight is the work of students at [Case Western](http://case.edu) and was
started as a project at [MHacks](http://mhacks.org).
- **Moonlight Android**: Cameron Gutman and contributors
- **Artemis**: ClassicOldSong

## License

Inherits license from Moonlight Android.
14 changes: 12 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'

android {
ndkVersion "27.0.12077973"
Expand All @@ -11,8 +12,8 @@ android {
minSdk 21
targetSdk 34

versionName "20.2.6"
versionCode = 57
versionName "1.36-coversession"
versionCode = 118

// Generate native debug symbols to allow Google Play to symbolicate our native crashes
ndk.debugSymbolLevel = 'FULL'
Expand Down Expand Up @@ -68,6 +69,10 @@ android {
targetCompatibility JavaVersion.VERSION_11
}

kotlinOptions {
jvmTarget = '11'
}

lint {
disable 'MissingTranslation'
lintConfig file('lint.xml')
Expand Down Expand Up @@ -183,6 +188,11 @@ dependencies {
implementation 'com.google.ai.edge.litert:litert-gpu:1.4.0'
implementation 'org.opencv:opencv:4.12.0'

// Cover screen support (AndroidX WindowManager for foldables)
implementation 'androidx.window:window:1.2.0'
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.3'
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.6.2'

// Unit test dependencies
testImplementation 'junit:junit:4.13.2'
testImplementation 'androidx.test:core:1.7.0'
Expand Down
3 changes: 3 additions & 0 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,9 @@
<meta-data android:name="WindowManagerPreference:FreeformWindowSize" android:value="system-default" />
<meta-data android:name="WindowManagerPreference:FreeformWindowOrientation" android:value="landscape" />

<!-- Foldable device support for cover screen virtual controller -->
<meta-data android:name="android.allow_multiple_resumed_activities" android:value="true" />

<!-- Special metadata for NVIDIA Shield devices to prevent input buffering
and most importantly, opt out of mouse acceleration while streaming -->
<meta-data
Expand Down
Loading