whiteboard_sdk_flutter

Creator: coderz1093

Last updated:

0 purchases

whiteboard_sdk_flutter Image
whiteboard_sdk_flutter Images

Languages

Categories

Add to Cart

Description:

whiteboard sdk flutter

Agora Whiteboard SDK #
A Flutter Plugin of Agora Whiteboard SDK
Installation #
Add whiteboard_sdk_flutter to your pubspec:
dependencies:
whiteboard_sdk_flutter: ^0.5.4
copied to clipboard
Android #
Configure your app to use the INTERNET permission in the manifest file located
in:
<project root>/android/app/src/main/AndroidManifest.xml:
<uses-permission android:name="android.permission.INTERNET"/>
copied to clipboard
Sample Usage #
Live Room #

Init whiteboard using WhiteSdkOptions, WhiteSdk can be fetch on onSdkCreated
call WhiteSdk.joinRoom using RoomOptions to fetch a WhiteRoom
WhiteRoom is a controller to Live-Whiteboard

Widget build(BuildContext context) {
return new WhiteboardView(
options: WhiteOptions(
appIdentifier: APP_ID,
log: true,
),
onSdkCreated: (sdk) async {
// use sdk to join room
var room = await sdk.joinRoom(
options: RoomOptions(
uuid: ROOM_UUID,
roomToken: ROOM_TOKEN,
uid: UNIQUE_CLIENT_ID,
isWritable: true,
),
);

setState(() {
whiteSdk = sdk;
whiteRoom = room;
});
},
);
}
copied to clipboard
Replay #

Init whiteboard using WhiteSdkOptions, WhiteSdk can be fetch on onSdkCreated
call WhiteSdk.joinReplay using ReplayOptions to fetch WhiteReplay
WhiteReplay is a controller to Record-Whiteboard

Widget build(BuildContext context) {
return new WhiteboardView(
options: WhiteOptions(
appIdentifier: APP_ID,
log: true,
backgroundColor: Color(0xFFF9F4E7),
),
onSdkCreated: (whiteSdk) async {
// use sdk to join replay
var replay = await sdk.joinReplay(
options: ReplayOptions(room: ROOM_UUID, roomToken: ROOM_TOKEN),
onPlayerStateChanged: _onPlayerStateChanged,
onPlayerPhaseChanged: _onPlayerPhaseChanged,
onScheduleTimeChanged: _onScheduleTimeChanged,
);

setState(() {
whiteSdk = sdk;
whiteReplay = replay;
});
},
);
}
copied to clipboard
Example #
See the example/ folder for a working example app.
Common apis can be found in the examples/
Room
Replay
Contributor #
Thanks To liuhong1happy for the first version of flutter whiteboard.

License

For personal and professional use. You cannot resell or redistribute these repositories in their original state.

Files In This Product:

Customer Reviews

There are no reviews.