Search found 690 matches

by Lena
Wed Oct 21, 2020 10:47 pm
Forum: Technical
Topic: Duplicates not allowed
Replies: 8
Views: 139

Re: Duplicates not allowed

Thank you. TThread.ForceQueue in DoMeta() working. What do you think if I remove TThread.ForceQueue from DoMeta() and put in MetaSync? procedure MetaSync(handle: HSYNC; channel, data: DWORD; user: Pointer); stdcall; begin TThread.ForceQueue(nil, procedure begin DoMeta(); end) end; or is it better to...
by Lena
Wed Oct 21, 2020 4:35 am
Forum: Technical
Topic: Update Progressbar
Replies: 3
Views: 38

Re: Update Progressbar

HsiaLin wrote: Wed Oct 21, 2020 4:07 am try
ProgressBar1.Update();
Hi.
In FMX no method Update for ProgressBar.
by Lena
Wed Oct 21, 2020 3:31 am
Forum: Technical
Topic: Update Progressbar
Replies: 3
Views: 38

Update Progressbar

Hi. I try update value on FMX project but no effect. How is it correct? Thanks. progress := 0; repeat len := BASS_StreamGetFilePosition(str, BASS_FILEPOS_END); if (len = DW_Error) then break; //something's gone wrong! (eg. BASS_Free called) progress := BASS_StreamGetFilePosition(str, BASS_FILEPOS_BU...
by Lena
Tue Oct 20, 2020 2:42 am
Forum: Technical
Topic: [Android]BASS
Replies: 23
Views: 3372

Re: [Android]BASS

Thank you very much I will investigate! P.S. I also found this difficult code. But it does not compile for me. Delphi 10.3.3 Start Foreground service in Delphi 10.3 unit Unit1; interface uses System.SysUtils, System.Classes, System.Android.Service, AndroidApi.JNI.GraphicsContentViewText, Androidapi....
by Lena
Tue Oct 20, 2020 2:22 am
Forum: Technical
Topic: Duplicates not allowed
Replies: 8
Views: 139

Re: Duplicates not allowed

Thank you! Delphi 10.3.3 I also found what UTF8String shows Russian letters. I've tested my new code throughout the day and everything looks good. I hear songs from the audio stream and see their titles Russian and English. My new code with comments below: var Form1: TForm1; smp: HSAMPLE; str: HSTRE...
by Lena
Sun Oct 18, 2020 10:33 am
Forum: Technical
Topic: Duplicates not allowed
Replies: 8
Views: 139

Re: Duplicates not allowed

If the song contains Russian letters in the title, then I see unreadable characters.
Form1.Text1.Text := meta;
Please help fix it.
Delphi 10.3.3
by Lena
Sun Oct 18, 2020 10:29 am
Forum: Technical
Topic: Duplicates not allowed
Replies: 8
Views: 139

Re: Duplicates not allowed

It looks like it works: // uses System.Threading procedure DoMeta(); var meta: MarshaledAString; p: Integer; begin //Form1.Text1.Text := ''; meta := BASS_ChannelGetTags(str, BASS_TAG_META); if (meta <> nil) then begin p := Pos('StreamTitle=', meta); if (p = 0) then begin TTask.Run( procedure begin T...
by Lena
Sun Oct 18, 2020 7:04 am
Forum: Technical
Topic: Duplicates not allowed
Replies: 8
Views: 139

Re: Duplicates not allowed

If commment in DoMeta() lines
Form1.Text1.Text := '';
Form1.Text1.Text := meta;
No Duplicates not allowed on Android. :o
by Lena
Sat Oct 17, 2020 9:46 am
Forum: Technical
Topic: Duplicates not allowed
Replies: 8
Views: 139

Duplicates not allowed

Hi. I am trying to translate an example to the bass library from windows to android. An example is called netradio from delphi windows folder bass library. procedure DoMeta(); var meta: MarshaledAString; p: Integer; begin Form1.Text1.Text := ''; meta := BASS_ChannelGetTags(str, BASS_TAG_META); if (m...
by Lena
Sat Oct 17, 2020 5:35 am
Forum: Technical
Topic: Implicit string cast from 'AnsiChar' to 'string'
Replies: 1
Views: 65

Implicit string cast from 'AnsiChar' to 'string'

Hi. How to correctly remove warnings in an Android project? function CheckInet: boolean; var aResp: IHTTPResponse; aHTTP: THTTPClient; begin Result := false; aHTTP := THTTPClient.Create; try try aResp := aHTTP.Head('http://google.com'); //Result := aResp.StatusCode < 400; Result := true; except Resu...
by Lena
Fri Oct 09, 2020 4:22 am
Forum: Technical
Topic: [Android]BASS
Replies: 23
Views: 3372

Re: [Android]BASS

Thanks for the additional information! I think the error is also in RAD 10.3.3 1. I create new an Android service 64 bit. 2. I create new app 64 bit. 3. Not use bass. 4. Use this short video: https://www.youtube.com/watch?v=0mD3WLK8FYc function TDM.AndroidServiceStartCommand(const Sender: TObject; c...
by Lena
Tue Oct 06, 2020 2:36 am
Forum: Technical
Topic: [Android]BASS
Replies: 23
Views: 3372

Re: [Android]BASS

My host app: unit UnitMain; interface uses System.SysUtils, System.Types, System.UITypes, System.Classes, System.Variants, FMX.Types, FMX.Controls, FMX.Forms, FMX.Graphics, FMX.Dialogs, System.Android.Service, FMX.Controls.Presentation, FMX.StdCtrls; type TForm1 = class(TForm) ButtonPlay: TButton; B...
by Lena
Mon Oct 05, 2020 11:26 pm
Forum: Technical
Topic: [Android]BASS
Replies: 23
Views: 3372

Re: [Android]BASS

Thank you. Are my first steps in creating a service correct? unit UnitSrvice; interface uses System.SysUtils, System.Classes, System.Android.Service, AndroidApi.JNI.GraphicsContentViewText, Androidapi.JNI.Os, bass; type TDM = class(TAndroidService) function AndroidServiceStartCommand(const Sender: T...
by Lena
Mon Oct 05, 2020 12:36 pm
Forum: Technical
Topic: [Android]BASS
Replies: 23
Views: 3372

Re: [Android]BASS

Thank You! Is it my steps correctly? 1. I create a service in it code with the launch of audio. 2. And in the application, send broadcast messages about the start or stop of playback. I have never used broadcast. Do I need to use Indy to send broadcast message? Can you show me an example of how to s...
by Lena
Mon Oct 05, 2020 4:31 am
Forum: Technical
Topic: [Android]BASS
Replies: 23
Views: 3372

Re: [Android]BASS

If I minimize my application and lock the screen on the phone, then after a couple of minutes the player stops playing. How do I make the player work in the background?