Skip to content

Commit

Permalink
removed language selection from readText()
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonGaudert committed Feb 18, 2018
1 parent bde5619 commit a3305e3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions naturalSpeech.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from gtts import gTTS
import pygame

def readText(outputText,language):
tts = gTTS(text=outputText, lang=language)
def readText(outputText):
tts = gTTS(text=outputText, lang='en')
tts.save("./audioOutput.mp3")

pygame.mixer.init()
Expand Down
4 changes: 2 additions & 2 deletions testAPI.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
import cv2
import base64
from getImage import capture
from textToSpeech import speak
from naturalSpeech import readText

def sendWebRequest(image_url):
url = 'https://vision.googleapis.com/v1p1beta1/images:annotate?key=AIzaSyC5FQW1UL-jZ9xq7ibfh1ZcfCP_6G0XpUA'
Expand Down Expand Up @@ -56,4 +56,4 @@ def sendWebRequest(image_url):
for i in v_aReadings:
print (i['description'])

speak("You are looking at "+ v_aReadings[0][e'description'])
readText(("You are looking at "+ v_aReadings[0][e'description']),'en')

0 comments on commit a3305e3

Please sign in to comment.