Skip to content

Commit

Permalink
Doc
Browse files Browse the repository at this point in the history
  • Loading branch information
Larpoux committed Feb 21, 2025
1 parent c9dc448 commit 8aed57e
Show file tree
Hide file tree
Showing 37 changed files with 107 additions and 107 deletions.
18 changes: 0 additions & 18 deletions tau/contribution.md

This file was deleted.

80 changes: 38 additions & 42 deletions tau/dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,54 +5,47 @@ summary: "We need you!"
nav_order: 6
---

# Contributions
# We really need your contributions

Flutter Sound is a free and Open Source project. Several contributors have already contributed to Flutter Sound. Specially :

- @hyochan who is the Flutter Sound father
- @salvatore373 who wrote the Track Player
- @bsutton who wrote the UI Widgets
- @larpoux who add several codec supports
Flutter Sound is a free and Open Source project. Several contributors have already contributed to Flutter Sound.

**We really need your contributions.**
We greatly appreciate any contributions to the project which can be as simple as providing feedback on the API or documentation.
Pull Requests are welcome and will be considered very carefully.

Or even better, you could be one of the main Flutter Sound developers.
We are hiring ;-)

{% include important.html content="
"%}
## Setup a development environment

### Clone the Flutter Sound project and the flutter_sound_core module
Clone the Flutter Sound project and the flutter_sound_core module

```sh
cd some_where
git clone --recursive https://github.com/canardoux/tau.git
git clone --recursive https://github.com/Canardoux/tau
```
Tau is a set of submodules. It will be easier for you to
develop if you get all of them

### setup a development environment
## setup a development environment

cd to the τ root dir and run the script `bin/reldev.sh DEV`

```sh
cd tau
bin/reldev.sh DEV
```
This script is convenient to set everything so that you can use a debugger.
This script uses `gsed` which is the GNU flavor of `sed`.
If using a macintosh, you probably want to get this shell command (Home brew!)

### iOS signing
## iOS signing

Open tau/flutter_sound/example/ios/Runner.xcworkspace in XCode, and set your `Team` in the `Signing & Capabilities` tab.

### Set your Flutter Sound flavor

```sh
cd tau

# If you want to work on the full flavor
bin/flavor.sh FULL

# if you want to work on the lite flavor
bin/flavor.sh LITE
```


### Clean your space
## Clean your space

Probably good to clean the space :

Expand All @@ -66,15 +59,15 @@ pod install
cd ..
```

### Debug the example
## Debug the example

If everything good, you are now ready to run the example in debug mode using either Visual Studio Code, Android Studio or XCode

- To debug/develop the Dart side, you open the project /tau/flutter_sound/example/ in Visual Studio Code or Android Studio.
- To debug/develop the iOS side you open tau/flutter_sound/example/ios/Runner.xcworkspace in XCode.
- To debug/develop the Android side, you open the project tau/flutter_sound/example/android in Android Studio
- To debug/develop the iOS side you open /tau/flutter_sound/example/ios/Runner.xcworkspace in XCode.
- To debug/develop the Android side, you open the project /tau/flutter_sound/example/android in Android Studio

### Debug your own App
## Debug your own App

You must change the dependencies in your pubspec.yaml file and do a `flutter pub get`:

Expand All @@ -94,41 +87,44 @@ You must change the dependencies in your pubspec.yaml file and do a `flutter pub
## Update the documentation

τ uses the Jekyll tool with a "Documentation Theme" to generate the documentation.
[Here](https://idratherbewriting.com/documentation-theme-jekyll/) is the Jekyll documentation.
[Here](https://just-the-docs.com/) is the `Just the Docs` documentation.
Please refer to this documentation to install ruby and jekyll on your dev machine.

All the τ documentation is in markdown files under tau/doc/pages.
All the τ documentation is in markdown files under /tau/fs-doc/tau.
You can see your modifications in live doing:

```sh
cd tau/doc
cd /tau/fs-doc
jekyll serve
```
or
```sh
cd /tau/fs-doc
bundle exec jekyll serve
```

## Publish the docs

Then, if you have the necessary credentials (but you certainly do not have them), you can do:

```sh
cd tau
bin/doc.sh
cd /tau/fs-doc
bin/pub.sh 1.2.3
```

## Build a new release

if you have the necessary credentials (but you certainly do not have them), you can do:

```sh
cd tau
newVersion.sh 8.2.0
cd /tau/flutter_sound
pub.sh 1.2.3
```

(In this example, 8.2.0 is the version number that you want to build).

When the script asks if OK to upload your new flutter_sound plugin,
it is a good idea to wait something like half an hour before answering.
This will give time to `npm` and `cocoaPod` to update their repositories (you do not want that someone will use your new build before that the repositories are updated.

------------------

When you have finished your contribution, you commit and push your files, and do a Pull Request in the Github τ Project.
When you have finished your contribution, you commit and push your files, and do a Pull Request in the [Github flutter_sound](https://github.com/canardoux/flutter_sound/) Project.

**THANK YOU FOR YOUR CONTRIBUTION**
# THANK YOU FOR YOUR CONTRIBUTION
Binary file modified tau/examples/.DS_Store
Binary file not shown.
Binary file added tau/examples/ScreenShots/.DS_Store
Binary file not shown.
Binary file added tau/examples/ScreenShots/Demo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/LogLevel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/MultiPlayback.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/Pan.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/PlaybackFromStream.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/PlayerOnProgress.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/RecordToStream.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/RecorderOnProgress.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/SeekPlayer.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/SimplePlayback.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/SimpleRecorder.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/SoundEffect.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/SpeedControl.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/Streams.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added tau/examples/ScreenShots/VolumeControl.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions tau/examples/ex_demo.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ parent: Examples
nav_order: 15
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/demo/demo.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/demo/demo.dart). You can have a live run of the examples [here](/live/index.html).

This is a demo of what it is possible to do with Flutter Sound. The code of this demo app is not so simple.

Expand All @@ -21,4 +21,4 @@ The biggest interest of this Demo is that it shows most of the features of Flutt
* Shows how to record to a Stream or playback from a stream
* ...

{% include image.html file="/fs/ExampleScreenShots/Demo.png" %}
{![screen shot](ScreenShots/Demo.png)
7 changes: 4 additions & 3 deletions tau/examples/ex_multi_playback.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,13 @@ parent: Examples
nav_order: 9
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/multi_playback/multi_playback.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/multi_playback/multi_playback.dart). You can have a live run of the examples [here](/live/index.html).
It create two [Player objects](/api/player/FlutterSoundPlayer-class.html) and use the verb [startPlayer()](/api/player/FlutterSoundPlayer/startPlayer.html) to play them.

This is a simple example doing several playbacks at the same time.

This example shows also :
- The Pause/Resume feature.
- The [Pause](/api/player/FlutterSoundPlayer/pausePlayer.html)/[Resume](/api/player/FlutterSoundPlayer/resumePlayer.html) feature.
- The Display of the elapsed time

{% include image.html file="/fs/ExampleScreenShots/MultiPlayback.png" %}
![screen shot](ScreenShots/MultiPlayback.png)
8 changes: 5 additions & 3 deletions tau/examples/ex_playback_from_stream_1.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,21 @@ summary: "Play from a dart stream, without flow control."
parent: Examples
nav_order: 5
---
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/livePlaybackWithoutBackPressure/live_playback_without_back_pressure.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/livePlaybackWithoutBackPressure/live_playback_without_back_pressure.dart). You can have a live run of the examples [here](/live/index.html).

An example showing how to play Live Data without back pressure. It feeds a live stream, without waiting that the futures are completed for each block. This is simpler than playing buffers synchronously because the App does not need to await that the playback for each block is completed before playing another one.

This example get the data from an asset file, which is completely stupid : if an App wants to play a long asset file he must use `startPlayer(fromBuffer:)`.
This example get the data from an asset file, which is completely stupid : if an App wants to play an asset file he must use [startPlayer(fromDataBuffer:)](/api/player/FlutterSoundPlayer/startPlayer.html).
Then it calls [startPlayerFromStream()](/api/player/FlutterSoundPlayer/startPlayerFromStream.html) to play the buffer

Feeding Flutter Sound without back pressure is very simple but you can have two problems :

* If your App is too fast feeding the audio channel, it can have problems with the Stream memory used.
* The App does not have any knowledge of when the block given to Flutter Sound is really played.
For example, if it does a `stopPlayer()` it will loose all the buffered data not yet played.

- [Streams](ex_streams)
- [Record To Stream](ex_record_to_stream)
- [Live Playback With Backpressure](fs-ex_playback_from_stream_2)

{% include image.html file="/fs/ExampleScreenShots/PlaybackWithoutBackPressure.png" %}
![screen shot](ScreenShots/PlaybackWithoutBackPressure.png)
8 changes: 5 additions & 3 deletions tau/examples/ex_playback_from_stream_2.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,18 @@ parent: Examples
nav_order: 6
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/livePlaybackWithBackPressure/live_playback_with_back_pressure.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/livePlaybackWithBackPressure/live_playback_with_back_pressure.dart). You can have a live run of the examples [here](/live/index.html).

An example showing how to play Live Data with back pressure. It feeds a live stream, waiting that the futures are completed for each block.

This example get the data from an asset file, which is completely stupid : if an App wants to play an asset file he must use `StartPlayer(fromBuffer:)`.
This example get the data from an asset file, which is completely stupid : if an App wants to play an asset file he must use [startPlayer(fromDataBuffer:)](/api/player/FlutterSoundPlayer/startPlayer.html).
Then it calls [startPlayerFromStream()](/api/player/FlutterSoundPlayer/startPlayerFromStream.html) to play the buffer

If you do not need any back pressure, you can see another simple example : [LivePlaybackWithoutBackPressure.dart](fs-ex_playback_from_stream_1.html).
This other example is a little bit simpler because the App does not need to await the playback for each block before playing another one.

- [Streams](ex_streams)
- [Record To Stream](ex_record_to_stream)
- [Live Playback Without Backpressure](fs-ex_playback_from_stream_1)

{% include image.html file="/fs/ExampleScreenShots/PlaybackWithBackPressure.png" %}
![screen shot](ScreenShots/PlaybackWithBackPressure.png)
6 changes: 3 additions & 3 deletions tau/examples/ex_player_onProgress.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ parent: Examples
nav_order: 7
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/player_onProgress/player_on_progress.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/player_onProgress/player_on_progress.dart). You can have a live run of the examples [here](/live/index.html).

This example shows how to use the verb `setSubscriptionDuration()` on a player for having an `onProgress()` callback.
This example shows how to use the verb [setSubscriptionDuration()](/api/player/FlutterSoundPlayer/setSubscriptionDuration.html) on a player for having an [onProgress](/api/player/FlutterSoundPlayer/onProgress.html) callback.
There is a slider to show how the playback frequency can be adjust.

This example is really basic.

{% include image.html file="/fs/ExampleScreenShots/PlayerOnProgress.png" %}
![screen shot](ScreenShots/PlayerOnProgress.png)
9 changes: 5 additions & 4 deletions tau/examples/ex_record_to_stream.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,15 @@ parent: Examples
nav_order: 4
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/recordToStream/record_to_stream_example.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/recordToStream/record_to_stream_example.dart). You can have a live run of the examples [here](/live/index.html).

This is an example showing how to record to a Dart Stream. It writes all the recorded data from a Stream to a File, which is completely stupid: if an App wants to record something to a File, it must not use streams.
This is an example showing how to record to a Dart Stream. It writes all the recorded data from a Stream to a File using It calls [startRecorder(toStream:)](/api/recorder/FlutterSoundRecorder/startRecorder.html) to fill a buffer from a stream, which is completely stupid: if an App wants to record something to a File, it must not use streams.
Then it can playback the file recorded.

The real interest of recording to a Stream is for example to feed a
Speech-to-Text engine, or for processing the Live data in Dart in real time.

You can also refer to the following example:
You can also refer to the following guide:
- [Dart Streams](fs-ex_streams.html):

{% include image.html file="/fs/ExampleScreenShots/RecordToStream.png" %}
![screen shot](ScreenShots/RecordToStream.png)
6 changes: 3 additions & 3 deletions tau/examples/ex_recorder_onProgress.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@ parent: Examples
nav_order: 8
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/recorder_onProgress/recorder_on_progress.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/recorder_onProgress/recorder_on_progress.dart). You can have a live run of the examples [here](/live/index.html).

This example shows how to use the verb `setSubscriptionDuration()` on a recorder for having an `onProgress()` callback.
This example shows how to use the verb [setSubscriptionDuration()](/api/recorder/FlutterSoundRecorder/setSubscriptionDuration.html) on a recorder for having an [onProgress](/api/recorder/FlutterSoundRecorder/onProgress.html) callback.
There is a slider to show are the playback frequency can be adjusted.

This example is really basic.

{% include image.html file="/fs/ExampleScreenShots/RecorderOnProgress.png" %}
![screen shot](ScreenShots/RecorderOnProgress.png)
6 changes: 3 additions & 3 deletions tau/examples/ex_seek.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ parent: Examples
nav_order: 12
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/seek/seek.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/seek/seek.dart). You can have a live run of the examples [here](/live/index.html).

This is a very simple basic example which allows the user to set the position into a playback.
This is a very simple basic example which allows the user to [set the position](/api/player/FlutterSoundPlayer/seekToPlayer.html) into a playback.

This example is really basic.

{% include image.html file="/fs/ExampleScreenShots/SeekPlayer.png" %}
![screen shot](ScreenShots/SeekPlayer.png)
6 changes: 3 additions & 3 deletions tau/examples/ex_setLogLevel.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ nav_order: 14

---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/loglevel/loglevel.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/loglevel/loglevel.dart). You can have a live run of the examples [here](/live/index.html).

This is a very simple basic example which allows the user to select the Log Level he/she is interested by.
This is a very simple basic example which allows the user to [select the Log Level](/api/player/FlutterSoundPlayer/setLogLevel.html) he/she is interested by.

{% include image.html file="/fs/ExampleScreenShots/LogLevel.png" %}
![screen shot](ScreenShots/LogLevel.png)
6 changes: 3 additions & 3 deletions tau/examples/ex_set_volume.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ summary: "Control of the sound volume"
parent: Examples
nav_order: 10
---
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/volume_control/volume_control.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/volume_control/volume_control.dart). You can have a live run of the examples [here](/live/index.html).

{% include image.html file="examples/set_volume.png" %}

This is a very simple basic example which allows the user to adjust the sound volume.
It launch two players which play each an asset. The User can adjust the volume of them independently.
It launchs two [Players](/api/player/FlutterSoundPlayer-class.html) which play each an asset. The User can [adjust the volume](/api/player/FlutterSoundPlayer/setVolume.html) of them independently.

This example is very basic.

{% include image.html file="/fs/ExampleScreenShots/VolumeControl.png" %}
![screen shot](ScreenShots/VolumeControl.png)
5 changes: 3 additions & 2 deletions tau/examples/ex_simple_playback.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@ parent: Examples
nav_order: 1
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/simple_playback/simple_playback.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/simple_playback/simple_playback.dart). You can have a live run of the examples [here](/live/index.html).

This is a very simple example for Flutter Sound beginners, that shows how to play a remote file.
It create a [Player object](/api/player/FlutterSoundPlayer-class.html) and use the verb [startPlayer()](/api/player/FlutterSoundPlayer/startPlayer.html).

This example is really basic.

{% include image.html file="/fs/ExampleScreenShots/SimplePlayback.png" %}
![screen shot](ScreenShots/SimplePlayback.png)
7 changes: 4 additions & 3 deletions tau/examples/ex_simple_recorder.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,11 @@ parent: Examples
nav_order: 2
---

The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/simple_recorder/simple_recorder.dart). You can have a live run of the examples [here](/tau/fs/live/index.html).
The example source [is there](https://github.com/canardoux/flutter_sound/blob/master/example/lib/simple_recorder/simple_recorder.dart). You can have a live run of the examples [here](/live/index.html).

This is a very simple example for Flutter Sound beginners, that shows how to record, and then playback a file.
This is a very simple example for Flutter Sound beginners, that shows how to record, and then playback a file. It create a [Recorder object](/api/recorder/FlutterSoundRecorder-class.html)
and use the verb [startRecorder()](/api/recorder/FlutterSoundRecorder/startRecorder.html).

This example is really basic.

{% include image.html file="/fs/ExampleScreenShots/SimpleRecorder.png" %}
![screen shot](ScreenShots/SimpleRecorder.png)
Loading

0 comments on commit 8aed57e

Please sign in to comment.