All Projects → dlutton → Flutter_tts

dlutton / Flutter_tts

Licence: mit
Flutter Text to Speech package

Programming Languages

java
68154 projects - #9 most used programming language
swift
15916 projects
dart
5743 projects

Projects that are alternatives of or similar to Flutter tts

Mtrans
Multi-source Translation
Stars: ✭ 711 (+170.34%)
Mutual labels:  google, tts
Realtime object detection
Plug and Play Real-Time Object Detection App with Tensorflow and OpenCV. No Bugs No Worries. Enjoy!
Stars: ✭ 260 (-1.14%)
Mutual labels:  google
iap
Flutter plugin for interacting with iOS StoreKit and Android Billing Library
Stars: ✭ 18 (-93.16%)
Mutual labels:  flutter-plugin
http middleware
A middleware library for Dart's http library.
Stars: ✭ 38 (-85.55%)
Mutual labels:  flutter-plugin
esp32-flite
Speech synthesis running on ESP32 based on Flite engine.
Stars: ✭ 28 (-89.35%)
Mutual labels:  tts
Checkiptools
CheckIPTools 扫描谷歌IP以及实用IP转换小工具
Stars: ✭ 253 (-3.8%)
Mutual labels:  google
google-translate-tts
Node library for Google Translate TTS (Text-to-Speech) API
Stars: ✭ 23 (-91.25%)
Mutual labels:  tts
Google Profanity Words
Full List of Bad Words and Top Swear Words Banned by Google as they closed it
Stars: ✭ 262 (-0.38%)
Mutual labels:  google
Microservices Traffic Management Using Istio
Istio is an open platform that provides a uniform way to connect, manage, and secure microservices. In this code we show how we can enable your microservices with advanced traffic management, routing and tracing capabilities leveraging Istio
Stars: ✭ 257 (-2.28%)
Mutual labels:  google
Google-rank-tracker
SEO: Python script + shell script and cronjob to check ranks on a daily basis
Stars: ✭ 124 (-52.85%)
Mutual labels:  google
Comprehensive-Tacotron2
PyTorch Implementation of Google's Natural TTS Synthesis by Conditioning WaveNet on Mel Spectrogram Predictions. This implementation supports both single-, multi-speaker TTS and several techniques to enforce the robustness and efficiency of the model.
Stars: ✭ 22 (-91.63%)
Mutual labels:  tts
flutter qq ads
🔥🔥🔥 Flutter 广告插件 -- 优量汇 、广点通、腾讯广告(支持开屏、插屏、激励视频、Banner、信息流、视频贴片)
Stars: ✭ 51 (-80.61%)
Mutual labels:  flutter-plugin
Flutter i18n
This plugin create a binding between your translations from .arb files and your Flutter app.
Stars: ✭ 255 (-3.04%)
Mutual labels:  flutter-plugin
flutter tensorflow lite
A Flutter plugin to access TensorFlow Lite apis.
Stars: ✭ 75 (-71.48%)
Mutual labels:  flutter-plugin
Laravel Robots Middleware
Enable or disable the indexing of your app
Stars: ✭ 259 (-1.52%)
Mutual labels:  google
RequestifyTF2
Client side commands for mic spamming and more!
Stars: ✭ 13 (-95.06%)
Mutual labels:  tts
react-google-static
🌍 A React wrapper for Google Static Maps API.
Stars: ✭ 37 (-85.93%)
Mutual labels:  google
flutter simple dependency injection
A super simple dependency injection implementation for flutter that behaviours like any normal IOC container and does not rely on mirrors
Stars: ✭ 91 (-65.4%)
Mutual labels:  flutter-plugin
Gtrendsr
R functions to perform and display Google Trends queries
Stars: ✭ 263 (+0%)
Mutual labels:  google
Google Autocomplete
Google Autocomplete Vue Componet
Stars: ✭ 262 (-0.38%)
Mutual labels:  google

Text To Speech

pub package

A flutter text to speech plugin (Swift,Java)

Compatibility Status

Latest compatibility result for Stable channel

Latest compatibility result for Beta channel

Latest compatibility result for Dev channel

Features

  • [x] Android, iOS, Web, & macOS
    • [x] speak
    • [x] stop
    • [x] get languages
    • [x] set language
    • [x] set speech rate
    • [x] set speech volume
    • [x] set speech pitch
    • [x] is language available
  • [x] Android, iOS
    • [x] get voices
    • [x] set voice
    • [x] speech marks (requires iOS 7+ and Android 26+)
    • [x] synthesize to file (requires iOS 13+)
  • [x] iOS, Web
    • [x] pause
  • [x] Android
    • [x] set silence
    • [x] is lanaguage installed
    • [x] are languages installed
    • [x] get engines
    • [x] set queue mode
  • [x] iOS
    • [x] set shared instance
    • [x] set audio session category

Usage

macOS

OSX version: 10.15

Example App from the macOS_app branch

Web

Website from the example directory.

Android

Change the minimum Android sdk version to 21 (or higher) in your android/app/build.gradle file.

minSdkVersion 21

iOS

There's a known issue with integrating plugins that use Swift into a Flutter project created with the Objective-C template. Flutter#16049

Example

To use this plugin :

  dependencies:
    flutter:
      sdk: flutter
    flutter_tts:
  • instantiate FlutterTts
FlutterTts flutterTts = FlutterTts();

To set shared audio instance (iOS only):

await flutterTts.setSharedInstance(true);

To set audio category and options (iOS only):

await flutterTts
        .setIosAudioCategory(IosTextToSpeechAudioCategory.playAndRecord, [
      IosTextToSpeechAudioCategoryOptions.allowBluetooth,
      IosTextToSpeechAudioCategoryOptions.allowBluetoothA2DP,
      IosTextToSpeechAudioCategoryOptions.mixWithOthers
    ]);

To await speak completion.

await flutterTts.awaitSpeakCompletion(true);

speak, stop, getLanguages, setLanguage, setSpeechRate, setVoice, setVolume, setPitch, isLanguageAvailable, setSharedInstance

Future _speak() async{
    var result = await flutterTts.speak("Hello World");
    if (result == 1) setState(() => ttsState = TtsState.playing);
}

Future _stop() async{
    var result = await flutterTts.stop();
    if (result == 1) setState(() => ttsState = TtsState.stopped);
}

List<dynamic> languages = await flutterTts.getLanguages;

await flutterTts.setLanguage("en-US");

await flutterTts.setSpeechRate(1.0);

await flutterTts.setVolume(1.0);

await flutterTts.setPitch(1.0);

await flutterTts.isLanguageAvailable("en-US");

// iOS and Web only
await flutterTts.pause();

// iOS, macOS, and Android only
await flutterTts.synthesizeToFile("Hello World", Platform.isAndroid ? "tts.wav" : "tts.caf");

await flutterTts.setVoice({"name": "Karen", "locale": "en-AU"});

// iOS only
await flutterTts.setSharedInstance(true);

// Android only
await flutterTts.setSilence(2);

await flutterTts.getEngines();

await flutterTts.isLanguageInstalled("en-AU");

await flutterTts.areLanguagesInstalled(["en-AU", "en-US"]);

await flutterTts.setQueueMode(1);

Listening for platform calls

flutterTts.setStartHandler(() {
  setState(() {
    ttsState = TtsState.playing;
  });
});

flutterTts.setCompletionHandler(() {
  setState(() {
    ttsState = TtsState.stopped;
  });
});

flutterTts.setProgressHandler((String text, int startOffset, int endOffset, String word) {
  setState(() {
    _currentWord = word;
  });
});

flutterTts.setErrorHandler((msg) {
  setState(() {
    ttsState = TtsState.stopped;
  });
});

flutterTts.setCancelHandler((msg) {
  setState(() {
    ttsState = TtsState.stopped;
  });
});

// iOS and Web
flutterTts.setPauseHandler((msg) {
  setState(() {
    ttsState = TtsState.paused;
  });
});

flutterTts.setContinueHandler((msg) {
  setState(() {
    ttsState = TtsState.continued;
  });
});

Getting Started

For help getting started with Flutter, view our online documentation.

For help on editing plugin code, view the documentation.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].