Lazarus

Programming => Operating Systems => Android => Topic started by: juank1971 on September 19, 2020, 11:54:52 pm

Title: Crash app camera demo in android 9
Post by: juank1971 on September 19, 2020, 11:54:52 pm
AppCameraDemo2 crash in android 9 and do no see error
Any coment .

Soorry again for for asking so many questions ;)
Title: Re: Crash app camera demo in android 9
Post by: jmpessoa on September 20, 2020, 02:42:23 am
Are you using "Ant" build system?

some info here:  [need Gradle]

https://forum.lazarus.freepascal.org/index.php/topic,51361.0.html

EDITED:

Can you put some log?
(Lazarus menu "Tools" ---> "LAMW..." --> "ADB Logcat")

What about "AppCameraDemo1"?  it work?
Title: Re: Crash app camera demo in android 9
Post by: juank1971 on September 21, 2020, 03:33:34 pm
no AppCameraDemo1
no AppCameraDemo2 work in android 9

i will try gradle now

Title: Re: Crash app camera demo in android 9
Post by: juank1971 on September 21, 2020, 05:44:56 pm
Could you summarize for me please what really needs to be done
to get the camerademos on android 9.

 because I'm a bit confused with the ideas of the user Guser979 and your contributions, suport I do not get it

Thanks for your time
Title: Re: Crash app camera demo in android 9
Post by: juank1971 on September 21, 2020, 07:41:47 pm
there are correct???????

In Controls.java add
android.os.StrictMode;

and ...

this 2 lines

    StrictMode.VmPolicy.Builder builder = new StrictMode.VmPolicy.Builder();
    StrictMode.setVmPolicy(builder.build());

in public String jCamera_takePhoto .

Change to Gradle.

its all or
or i nedd more changes in the project
Title: Re: Crash app camera demo in android 9
Post by: jmpessoa on September 21, 2020, 09:00:50 pm

First try  only changing to "Gradle" ...

[if it work I wiil try find "Ant" bug.....]
Title: Re: Crash app camera demo in android 9
Post by: juank1971 on September 21, 2020, 10:11:56 pm
only changing to "Gradle"  camerademo  yess  worked

camerademo2 no work crass app

tested android 9 lazarus 2.1 fpc 3.2.0 and lamw
Title: Re: Crash app camera demo in android 9
Post by: jmpessoa on September 22, 2020, 01:15:33 am

Quote
camerademo2 no work crass app...

Can you put some log for the error?

(Lazarus menu "Tools" ---> "LAMW..." --> "ADB Logcat")
TinyPortal © 2005-2018