You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on May 18, 2022. It is now read-only.
Create a new method : startPlayerFromBuffer, to play from a buffer (Canardoux#170)
* Create a new method : startPlayerFromBuffer, to play from a memory buffer instead of a URL
* Add support for OPUS encoder on iOS.
* Actually on iOS, you can choose from two encoders :
- AAC (this is the default)
- CAF/OPUS
* Fix bug in example, when the user try to play from buffer but has not record anything with the recorder
* README : default path for Android
* Suppress superfluous spaces when calling a dart method
* Minor cosmetic fixes, after Hyo remarks
Recently, Apple added a support for encoding with the standard OPUS codec. Unfortunetly, Apple encapsulates its data in its own proprietary envelope : CAF. This is really stupid, this is Apple
104
+
105
+
On Android the OPUS codec is not yet supported by flutter_sound.
94
106
95
107
#### Stop recorder
96
108
```dart
@@ -118,7 +130,8 @@ void dispose() {
118
130
```
119
131
120
132
#### Start player
121
-
To start playback of a recording call startPlayer.
133
+
- To start playback of a record from a URL call startPlayer.
134
+
- To start playback of a record from a memory buffer call startPlayerFromBuffer
122
135
123
136
You must wait for the return value to complete before attempting to add any listeners
Copy file name to clipboardExpand all lines: android/src/main/java/com/dooboolab/fluttersound/AudioInterface.java
+14-1
Original file line number
Diff line number
Diff line change
@@ -2,8 +2,20 @@
2
2
3
3
importio.flutter.plugin.common.MethodChannel;
4
4
5
+
// this enum MUST be synchronized with lib/flutter_sound.dart and ios/Classes/FlutterSoundPlugin.h
6
+
enumt_CODEC
7
+
{
8
+
DEFAULT
9
+
, AAC
10
+
, OPUS
11
+
, CODEC_CAF_OPUS// Apple encapsulates its bits in its own special envelope : .caf instead of a regular ogg/opus (.opus). This is completely stupid, this is Apple.
finalpublicstaticStringDEFAULT_FILE_LOCATION = Environment.getDataDirectory().getPath() + "/default.aac";// SDK 29 : you may not write in getExternalStorageDirectory()
0 commit comments