Download PureBasic 4.00

Working on new editor enhancements?
MarcosPC
User
User
Posts: 17
Joined: Mon Mar 19, 2018 10:03 pm

Download PureBasic 4.00

Post by MarcosPC »

Hello!

I am visually impaired, and use purebasic among other programs to do my things.
I found an important library for me called "PureTTS".
I am informed that this library only works in purebasic version 4.00.
I wonder if there is this demo version available for download, and how to download it, if possible.
I want to apologize if I posted in the wrong place, or if I was not very understood, but my English is bad, and I had to use google translator.
I thanks in advance to anyone who can help me!

Original Brazilian portuguese:
Olá!

Sou deficiente visual, e uso purebasic entre outros programas para fazer minhas coisas.
Achei uma biblioteca importante para mim chamada "PureTTS".

Está informado que esta biblioteca só funciona na versão purebasic 4.00.

Gostaria de saber, se há disponível essa versão demo para download, e como fazer para baixar, se possível.

Quero pedir desculpas se postei no lugar errado, ou se não fui muito compreendido, mas meu inglês é ruím, e tive que usar o google tradutor.
Grato desde já à quem puder me ajudar!
Bitblazer
Enthusiast
Enthusiast
Posts: 730
Joined: Mon Apr 10, 2017 6:17 pm
Location: Germany
Contact:

Re: Download PureBasic 4.00

Post by Bitblazer »

Instead of finding old software versions from 2006, maybe finding a solution to use a more modern text-to-speech software and connect that to a recent Purebasic version? Linguatec might be an option. I have the personal version installed and interfacing it with PB should be possible even if its "clumsy" due to having to use a temporary text file because home versions dont allow direct API access. I will take a look.

Em vez de encontrar versões antigas de software a partir de 2006, talvez encontrando uma solução para usar um software de texto para fala mais moderno e conectá-lo a uma versão recente do Purebasic? Linguatec pode ser uma opção. Eu tenho a versão pessoal instalada e interfaceando com o PB deve ser possível mesmo que seja "desajeitado" devido a ter que usar um arquivo de texto temporário porque as versões domésticas não permitem o acesso direto da API. Eu vou dar uma olhada.
webpage - discord chat links -> purebasic GPT4All
Bitblazer
Enthusiast
Enthusiast
Posts: 730
Joined: Mon Apr 10, 2017 6:17 pm
Location: Germany
Contact:

Re: Download PureBasic 4.00

Post by Bitblazer »

Code: Select all

Structure FindWindowData
  hFW.l ; variable to store a handle
  sFW.s ; variable to store a Window name
  cFW.s ; variable to store a window class name
  px.l
  py.l
  height.l
  width.l
EndStructure

Global NewList FindWindow.FindWindowData()

Procedure.i EnumWindowsProc(hFind, lParam)
  Protected WindowName.s = Space(255)
  Protected WindowClass.s = Space(255)
  Protected WP.WINDOWPLACEMENT
  ClearStructure(@WP, WINDOWPLACEMENT)
  WP\length = SizeOf(WINDOWPLACEMENT)
  If GetWindowText_(hFind, WindowName, 255)
    Result = GetClassName_(hFind, WindowClass, 255)
    If GetWindowPlacement_(hFind, @WP)
      If WP\showCmd=1 And IsWindowVisible_(hFind) And WindowClass<>"Button" And WindowClass<>"Progman"
        AddElement(FindWindow())
        FindWindow()\hFW = hFind
        FindWindow()\sFW = WindowName
        FindWindow()\cFW = WindowClass
        FindWindow()\px    = WP\rcNormalPosition\left
        FindWindow()\py    = WP\rcNormalPosition\top
        FindWindow()\height =  WP\rcNormalPosition\bottom-WP\rcNormalPosition\top-2*GetSystemMetrics_(#SM_CYFRAME)-GetSystemMetrics_(#SM_CYCAPTION)
        FindWindow()\width = WP\rcNormalPosition\right-WP\rcNormalPosition\left-2*GetSystemMetrics_(#SM_CXFRAME)
      EndIf
    EndIf
  EndIf
  ProcedureReturn 1
EndProcedure

SetClipboardText("wer braucht schon API zugriff")

If EnumWindows_(@EnumWindowsProc(), 0)
  ForEach FindWindow()
    SPos.i = FindString(LCase(FindWindow()\sFW), "voice reader home")
    If (SPos <> 0)
      SetCursorPos_(FindWindow()\px + 12, FindWindow()\py + 32)
      
      mouse_event_(#MOUSEEVENTF_LEFTDOWN,0,0,0,0)
      mouse_event_(#MOUSEEVENTF_LEFTUP,0,0,0,0)      
    EndIf
  Next
EndIf
This is my clumsy solution to get you started. I inject a text into the clipboard and then simulate a keypress on the voice reader left button "read text from clipboard". This works only if the voice reader window is visible and uncovered. Maybe somebody can make it work with hidden windows too. Using the window handle directly and injecting an event into the windows event-queue should do that.

Esta é a minha solução desajeitada para você começar. Eu injetar um texto na área de transferência e, em seguida, simular um pressionamento de tecla no botão esquerdo do leitor de voz "ler texto da área de transferência". Isso funciona somente se a janela do leitor de voz estiver visível e descoberta. Talvez alguém possa fazê-lo funcionar com janelas ocultas também. Usar a janela diretamente e injetar na fila de eventos deve fazer isso.
webpage - discord chat links -> purebasic GPT4All
User avatar
RSBasic
Moderator
Moderator
Posts: 1218
Joined: Thu Dec 31, 2009 11:05 pm
Location: Gernsbach (Germany)
Contact:

Re: Download PureBasic 4.00

Post by RSBasic »

I recently published a DLL: PB.Ex Speech: http://www.purebasic.fr/english/viewtop ... 27&t=70342
Works with current PB version.
Image
Image
MarcosPC
User
User
Posts: 17
Joined: Mon Mar 19, 2018 10:03 pm

Re: Download PureBasic 4.00

Post by MarcosPC »

Sorry for the delay in responding, but I needed to reinstall my windows, and since I migrated from 7 to 10, I'm still getting used to it.
Firstly, I would like to thank you for the quick response from everyone, and the interest in my issue.
I tested the BitBlazer code, but returned an error:
Line 16: Structure not found: WINDOWPLACEMENT.

I tried to understand the code, but it seemed strange to me.
But if I understand correctly, should this code work with the app on the site?
I ask why I opened the site, copied a text to the clipboard, and returned the above error.
But from what I understand, I would have to run the program with the active window. I may have understood something wrong.
Well, I have installed here the scansoft synthesizer, in addition to what already resides in windows. All sapi5. I do not know if this information would help you in anything.
But, thank you in advance for your help.

I also tested the RSBasic code, along with its library.

The player works perfectly, but for some reason, I can not record to audio.

I was so excited to try using STT, that I installed windows10 on another HD.
However, I need to set up voice recognition correctly.
I'll be studying the commands better, but I have a question.
Instead of having to write the name of the voice to be used, can you put her number?
Or, a command to list the available voices by name, to save to a variable, and to be used more easily.
I think it would be more practical.
But independently, I've got, in part, what I need to get started.

Very grateful to all once again.

Original text:

Desculpem-me a demora para responder, mas precisei reinstalar meu windows, e como fiz migração do 7 para o 10, ainda estou me acostumando.
Em primeiro ponto, gostaria de agradecer pela resposta rápida de todos, e o interesse em minha questão.
Testei o código do BitBlazer, mas retornou um erro:
Line 16: Structure not found: WINDOWPLACEMENT.

Tentei entender o código, mas pareceu estranho para mim.
Mas, se eu tiver entendido direito, esse código deveria trabalhar com o app que está no site?
Pergunto porque abri o site, copiei um texto para o clipboard, e retornou o erro acima.
Mas pelo que entendi, teria que executar o programa com a janela ativa. Eu posso ter entendido algo errado.
Bom, eu tenho instalado aqui, o sintetizador da scansoft, além do que já vem residente no windows. Todos sapi5. Não sei se essa informação te ajudaria em alguma coisa.
Mas, desde já agradeço pela ajuda.

Testei também o código do RSBasic, junto com sua biblioteca.

O leitor funciona perfeitamente, mas por algum motivo, não consigo gravar para áudio.

Fiquei tão entusiasmado para tentar usar o STT, que instalei o windows10 em um outro HD.
Porém, preciso configurar o reconhecimento de voz corretamente.
Vou estar estudando os comandos melhor, mas tenho uma dúvida.
No lugar de ter que escrever o nome da voz para ser usada, tem como colocar o número dela?
Ou então, um comando para listar as vozes disponíveis por nome, para guardar em uma variável, e ser usada com mais facilidade.
Creio que seria mais prático.
Mas independente, já consegui, em parte, o que preciso para começar.

Muito grato à todos mais uma vez.
Bitblazer
Enthusiast
Enthusiast
Posts: 730
Joined: Mon Apr 10, 2017 6:17 pm
Location: Germany
Contact:

Re: Download PureBasic 4.00

Post by Bitblazer »

MarcosPC wrote:I tested the BitBlazer code, but returned an error:
Line 16: Structure not found: WINDOWPLACEMENT.
If you press ALT-S inside the PureBasic IDE you should get a window showing the structure viewer. There you should be able to find the WINDOWPLACEMENT structure

If you can't find it - just create it manually from the link above.
MarcosPC wrote:I tried to understand the code, but it seemed strange to me.
But if I understand correctly, should this code work with the app on the site?
It does work with my installed copy of the latest linguatec voice reader home 15 version.

What part was strange about it? It inserts a text into the clipboard and then find the voice readers window and simulate a keypress on the "play text from clipboard" button. Its really a rather clumsy but universally working method of adding automation to software which doesnt offer it in cheap versions. Software like AUTO-IT does the same as a business model. You might like their software for automating other tasks too (i just noticed that they made their software free now).
MarcosPC wrote:I ask why I opened the site, copied a text to the clipboard, and returned the above error.
But from what I understand, I would have to run the program with the active window. I may have understood something wrong.
It is a clumsy way as it requires the voice reader playback to be visible and uncovered on the desktop or the simulated mouseclick doesnt work. Using an API would work much better, but then you would need to pay 400 instead of 15 euro ;)

With a little bit work, you can do it by injecting the mouseclicks into the event queue of the voice reader and have it working much better without extra costs. (Hint: I still wait for somebody else who has a working project to do that and post code snippets here :)
MarcosPC wrote:The player works perfectly, but for some reason, I can not record to audio.
That might be due to the DMCA nonsense. Some years ago content companies did a lot lobbying to limit the ability of average PC hardware to record video and audio data. It's a bit of a joke and can rather easily undone, but that's not the topic of this thread and sadly you upgraded your windows to the latest in customer restriction technology from redmond ;)

If you are old enough like me, you remember a time where even the most simple audio drivers had an option to record the audio stream into a file.

Oh i just remembered that you wrote that you are visually impaired. When they lobbied to install all those customer restrictions by law for their DMCA crap, they had to make a concession so their content protection wouldnt harm or exclude disabled or impaired people. google knows it is your legal right to participate
webpage - discord chat links -> purebasic GPT4All
Post Reply