Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Installing QTSpeech

Installing QTSpeech

Scheduled Pinned Locked Moved Unsolved General and Desktop
27 Posts 4 Posters 8.8k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • quentinthorntonQ Offline
    quentinthorntonQ Offline
    quentinthornton
    wrote on last edited by
    #1

    Could someone please point me to instructions on how to install the QtSpeech library? I've been searching for some info on installing it for the past 2 hours, but have only scraped up a little bit of stuff here and there. I've tried using the INSTALL.txt file from https://github.com/srazi/qtspeech. It says:

    Introduction

    QtSpeech uses qmake to build itself as static library.
    qmake is part of a Qt distribution. For Unix Festival
    is required as TTS engine.

    Building QtSpeech

    A) Unix

    sh get-festival.sh
    qmake QtSpeech.pro
    make

    B) Win32/MSVC (this is the one I did)

    Install Speech SDK (Windows XP - Speech SDK 5.1).
    Unfortunately fixes in header files are required.
    Maybe due to outdated version of SDK for Windows XP.

    sphelper.h:
    line 769:
    -const ulLenVendorPreferred = wcslen(pszVendorPreferred);
    +const ULONG ulLenVendorPreferred = wcslen(pszVendorPreferred);
    line 1418:
    -static CoMemCopyWFEX(const WAVEFORMATEX * pSrc, WAVEFORMATEX ** ppCoMemWFEX)
    +static int CoMemCopyWFEX(const WAVEFORMATEX * pSrc, WAVEFORMATEX ** ppCoMemWFEX)
    line 2372:
    -for (const WCHAR * psz = (const WCHAR *)lParam; *psz; psz++) {}
    +const WCHAR * psz; for (psz = (const WCHAR *)lParam; *psz; psz++) {}

    As alternative to avoid building process you can use already built
    QtSpeech.vs2005.lib, but still you will need sapi.lib on linking stage.

    B) Mac OS X

    qmake QtSpeech.pro
    make

    But I don't really know what to do after I finish what it says to do. BTW, I am running a windows 10 64 bit laptop, so I just did what it said to do on the win32/msvc. Anybody know of where to find some instructions or know what to do after that? Thanks.

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      I'd recommend taking a look at the Qt project QtSpeech module. You can find it here. To install it, it's the usual combo: qmake, nmake, nmake install on windows. You can also open the .pro file in Qt Creator and build it there.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • quentinthorntonQ Offline
        quentinthorntonQ Offline
        quentinthornton
        wrote on last edited by
        #3

        Thanks for replying! I was looking at the link you had there, how would I download it? All three of the Clone links near the bottom left of the page don't work when I click on them. Also, how would I use qmake, nmake, and nmake install? I can't seem to find much, all I was able to do was make some makefiles, and then I couldn't figure out what to do from there. Thanks in advance.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Use git to clone the repository.

          What compiler are you using ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • quentinthorntonQ Offline
            quentinthorntonQ Offline
            quentinthornton
            wrote on last edited by
            #5

            Okay, I don't really know what my compiler is. I'm just using qt, and when I tried to do qmake and nmake, it was in the qt console thing. It looked just like cmd. It says Qt 5.4 64 bit for desktop when I hover over the qt cmd thing. Thanks

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Then which Qt package did you install ?

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              0
              • quentinthorntonQ Offline
                quentinthorntonQ Offline
                quentinthornton
                wrote on last edited by
                #7

                I don't know that either. But I looked under the help tab and clicked 'about qt creater' and this is what it said there.

                Qt Creator 3.6.0
                Based on Qt 5.5.1 (MSVC 2013, 32 bit)

                Built on Dec 15 2015 01:01:38

                From revision b52c2f91f5

                Copyright 2008-2015 The Qt Company Ltd. All rights reserved.

                The program is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.

                Ohhhhhhh, I think I get it. Do I need to install the mingw compiler for that to work?

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  What was used to build Qt Creator has nor influence on the Qt version you are using.

                  Since I don't know which version of Qt you installed, I can't command on that. What do you have in the Qt Version section of the Build And Run panel of Qt Creator's preferences ?

                  Interested in AI ? www.idiap.ch
                  Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  0
                  • quentinthorntonQ Offline
                    quentinthorntonQ Offline
                    quentinthornton
                    wrote on last edited by
                    #9

                    It says: Qt 5.4.2 MSVC2013 64bit

                    1 Reply Last reply
                    0
                    • SGaistS Offline
                      SGaistS Offline
                      SGaist
                      Lifetime Qt Champion
                      wrote on last edited by
                      #10

                      Good

                      One simpler alternative to build and install that module is to open the project with Qt Creator and build it with your Qt version (like any standard project).

                      To install it, go in the Projects panel and click on "Add build step", select make and in "Make arguments" write install. That should call make install each time you build the module.

                      Interested in AI ? www.idiap.ch
                      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                      1 Reply Last reply
                      0
                      • quentinthorntonQ Offline
                        quentinthorntonQ Offline
                        quentinthornton
                        wrote on last edited by
                        #11

                        Okay, so I got that done, but I had to do it with a different qtspeech thing I got from here, because the other one had some errors when I tried it. But anyways, I tried to make a project and use qtspeech but it didn't work. I even put the full path to the header file in the qtspeech folder in the #include. After putting the full path, it doesn't give an error on the include anymore, but when I try to make a qtspeech object

                        QtSpeech voice;//it says right here: QtSpeech undeclared identifier.
                        voice.say("hello world");
                        

                        Do I need to do something else after those last steps you told me? Thanks for your time.

                        1 Reply Last reply
                        0
                        • jsulmJ Offline
                          jsulmJ Offline
                          jsulm
                          Lifetime Qt Champion
                          wrote on last edited by
                          #12

                          Is QtSpeech in a namespace?

                          https://forum.qt.io/topic/113070/qt-code-of-conduct

                          1 Reply Last reply
                          0
                          • quentinthorntonQ Offline
                            quentinthorntonQ Offline
                            quentinthornton
                            wrote on last edited by quentinthornton
                            #13

                            No, at least I don't think so. Do I just have to do something in the project file (the .pro file)? I tried add the qtspeech.h as a header. Like this..

                            HEADERS += "C:/Users/Quentin/Downloads/qtspeech-master/QtSpeech.h"
                            SOURCES += "C:/Users/Quentin/Downloads/qtspeech-master/QtSpeech_win.cpp" // and added the .cpp file like this.
                            

                            But nothing I tried worked. How would I go about adding it into a namespace? Thanks.

                            1 Reply Last reply
                            0
                            • quentinthorntonQ Offline
                              quentinthorntonQ Offline
                              quentinthornton
                              wrote on last edited by
                              #14

                              I can't seem to find anything online, they all are showing how to install libraries it they have a .lib file. QtSpeech doesn't seem to have one. Any Idea how I should add it to my project? Thanks.

                              1 Reply Last reply
                              0
                              • SGaistS Offline
                                SGaistS Offline
                                SGaist
                                Lifetime Qt Champion
                                wrote on last edited by
                                #15

                                One thing you can do is to add

                                include(C:/Users/Quentin/Downloads/qtspeech-master/qtspeech.pri)
                                

                                to your .pro file so it will build everything with your project.

                                Interested in AI ? www.idiap.ch
                                Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                1 Reply Last reply
                                0
                                • quentinthorntonQ Offline
                                  quentinthorntonQ Offline
                                  quentinthornton
                                  wrote on last edited by
                                  #16

                                  Since I can't seem to figure out how to get the one working, could you please tell me how to install the one you suggested to me? Seeing now, they both were getting errors likely because I didn't install them properly. Thanks.

                                  1 Reply Last reply
                                  0
                                  • SGaistS Offline
                                    SGaistS Offline
                                    SGaist
                                    Lifetime Qt Champion
                                    wrote on last edited by
                                    #17

                                    What errors are you getting ?

                                    Interested in AI ? www.idiap.ch
                                    Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                    1 Reply Last reply
                                    0
                                    • quentinthorntonQ Offline
                                      quentinthorntonQ Offline
                                      quentinthornton
                                      wrote on last edited by
                                      #18

                                      The one you sent me:
                                      :-1: error: Failed to run: perl -w C:\Qt\5.4\msvc2013_64\bin\syncqt.pl -module QtTextToSpeech -version 5.8.0 -outdir C:/Qt/5.4/msvc2013_64 C:/Users/Caiden/qtspeech

                                      This happens when I open up the qtspeech.pro file and click run.

                                      And then I get an error when I try to make a project an use the qtspeech library I got from here saying it doesn't recognize the library.
                                      Basically, I can't figure out how to properly add the library to a project.

                                      1 Reply Last reply
                                      0
                                      • SGaistS Offline
                                        SGaistS Offline
                                        SGaist
                                        Lifetime Qt Champion
                                        wrote on last edited by
                                        #19

                                        Did you clone the repository or download an archive ?

                                        Interested in AI ? www.idiap.ch
                                        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

                                        1 Reply Last reply
                                        0
                                        • quentinthorntonQ Offline
                                          quentinthorntonQ Offline
                                          quentinthornton
                                          wrote on last edited by
                                          #20

                                          I cloned it.

                                          1 Reply Last reply
                                          0

                                          • Login

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • Users
                                          • Groups
                                          • Search
                                          • Get Qt Extensions
                                          • Unsolved