This is a real-time screen sharing application for Android that uses WebRTC for peer-to-peer video streaming and Socket.IO for signaling.
- Screen capture using MediaProjection API
- Real-time peer-to-peer video streaming using WebRTC
- Signaling server using Node.js and Socket.IO
- Material Design UI
- Room-based sharing system
- Android Studio
- Node.js and npm
- Android device running Android 5.0 (API level 21) or higher
-
Navigate to the server directory:
cd server -
Install dependencies:
npm install
-
Start the server:
npm start
The server will start on port 3000 by default. You can change the port by setting the PORT environment variable.
-
Open the project in Android Studio
-
Update the
SIGNALING_SERVER_URLinSignalingClient.javato point to your signaling server:private static final String SIGNALING_SERVER_URL = "http://your-server-url:3000";
-
Build and run the app on your Android device
- Open the app
- Enter a room ID
- Tap "Start Screen Share"
- Grant screen capture permission when prompted
- Share the room ID with the viewer
- Open the app
- Enter the room ID shared by the broadcaster
- Tap "Join Room"
- The shared screen will appear once connected
INTERNET: For network communicationRECORD_AUDIO: For audio capture (optional)FOREGROUND_SERVICE: For screen capture serviceSYSTEM_ALERT_WINDOW: For overlay windows- Media projection permission (requested at runtime)
MainActivity: Handles screen sharing and room creationViewerActivity: Displays the shared screenScreenCaptureService: Manages screen capture using MediaProjectionWebRTCClient: Handles WebRTC peer connections and media streamingSignalingClient: Manages Socket.IO communication with the signaling server
Feel free to submit issues and enhancement requests.
This project is licensed under the MIT License - see the LICENSE file for details.