Getting Started Example
When you read this document, we assume that you already have basic experience in front-end application development and can understand the relevant fundamental concepts.
Environment Preparation
You need an iOS development environment with Xcode version 12.0 or higher, as well as an iPhone or iPad that can connect to the Internet.
Create a Demo Project and Import the SDK
Step 1: Create a project using Xcode, as shown below:
Then click "Next" to complete the creation.
Step 2: Import into your project: TKRoomSDK.framework
Then click "Finish" to complete the import.
Similarly, import the TKMediaEngine.framework
Project Settings
After importing the SDK, you need to configure the project to ensure that it can run quickly.
Build Settings:
Build Settings -> Linking -> Other Linker Flags -> -all_load
Build Settings -> Build Options -> Enable Bitcode -> NO
Build Phases:
Build Phases->Copy FIles->Destination->The choice is for Frameworks Build Phases->CopyFiles->name->Add TKRoomSDK.framework
Info.plist:
info.plist -> Privacy - Camera Usage Description -> "The host needs your consent to access the camera.";info.plist -> Privacy - Microphone Usage Description -> "The host needs your consent to use the microphone.";info.plist -> Privacy - Photo Library Usage Description -> "The host needs your consent to access the photo library.";info.plist -> Privacy - Bluetooth Peripheral Usage Description -> "The host needs your consent to use Bluetooth."
Set Up App Background Modes
If needed, you can set the following:
Capabilities -> Background Modes -> Set to ON -> Check Audio, AirPlay, and Picture in Picture
Supported CPU Architectures
The SDK currently supports arm64
Using the Sample Program
The talkSDKDemo includes basic SDK invocation methods (such as joining a room, publishing audio and video, and leaving a room). Open the sample program with Xcode and directly compile and run it on a real device to experience it.