Broadcasting Overview

The social.plus Video SDK provides comprehensive broadcasting capabilities that enable you to create engaging live streaming experiences across all platforms.

What is Broadcasting?

Broadcasting allows users to share their live video content with viewers in real-time. The social.plus SDK handles the complex aspects of video encoding, streaming protocols, and delivery optimization.

Key Features

Real-time Streaming

  • Low-latency live video transmission
  • Adaptive bitrate streaming
  • Automatic quality adjustment based on network conditions

Multi-platform Support

  • Native iOS broadcasting
  • Native Android broadcasting
  • Web-based broadcasting
  • React Native integration
  • Flutter integration

Advanced Broadcasting Features

  • Camera Controls: Switch between front/rear cameras, adjust zoom, focus, and exposure
  • Audio Management: Microphone controls, noise suppression, and audio mixing
  • Screen Sharing: Share device screen alongside camera feed
  • Multi-streaming: Broadcast to multiple platforms simultaneously

Getting Started

Basic Broadcasting Setup

import { SocialPlusVideo } from '@social-plus/video-sdk';

const broadcaster = new SocialPlusVideo({
  apiKey: 'your-api-key',
  mode: 'broadcaster'
});

// Start broadcasting
await broadcaster.startBroadcast({
  title: 'My Live Stream',
  description: 'Broadcasting live from the event',
  privacy: 'public'
});

Broadcasting Flow

  1. Initialize SDK: Set up the broadcasting client
  2. Configure Stream: Set stream parameters (resolution, bitrate, etc.)
  3. Preview Setup: Show camera preview to broadcaster
  4. Start Broadcasting: Begin live transmission
  5. Monitor Stream: Track viewer count, quality metrics
  6. End Broadcasting: Gracefully stop the stream

Broadcasting States

The SDK manages several broadcasting states:
  • Idle: Ready to start broadcasting
  • Preparing: Setting up camera and audio
  • Preview: Showing camera preview
  • Broadcasting: Actively streaming
  • Paused: Temporarily paused
  • Stopped: Broadcast ended
  • Error: Something went wrong

Quality Management

Adaptive Streaming

The SDK automatically adjusts stream quality based on:
  • Network bandwidth
  • Device capabilities
  • Viewer feedback
  • Server load

Manual Quality Control

Broadcasters can also manually control:
  • Video resolution (480p, 720p, 1080p)
  • Frame rate (15fps, 30fps, 60fps)
  • Bitrate limits
  • Audio quality settings

Platform Considerations

iOS Broadcasting

  • Uses AVFoundation for camera access
  • Background broadcasting support
  • Picture-in-picture mode
  • Screen recording integration

Android Broadcasting

  • Camera2 API integration
  • Service-based background broadcasting
  • Multi-window support
  • Hardware encoder optimization

Web Broadcasting

  • WebRTC-based streaming
  • MediaDevices API for camera access
  • Screen sharing capabilities
  • Cross-browser compatibility

Next Steps