Author Topic: Android - V10 release candidate  (Read 86916 times)

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10713
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Android - Beta SDK
« Reply #150 on: 2011-May-11 »
oh. Can you fix it?

It must work with spaces in the path, mind.

Offline 404 Not Found

  • Mc. Print
  • *
  • Posts: 4
    • View Profile
Re: Android - Beta SDK
« Reply #151 on: 2011-May-11 »
Thanks for getting the keyboard working! However, there are still some minor flaws:
- Space isn't detected yet
- Pressing X exits the app
- For landscape apps the D-Pad directions are rotated by 90° by default because portrait orientation is hard-coded into the manifest. You have to change it manually, but it would be nice if it's set automatically depending on project settings.
- Sliding the keyboard out exits the app. To prevent this, you need to add android:configChanges="keyboardHidden|orientation" to the <activity> tag in the manifest file. This should also be included in the template project.

Concerning the crash/segfault on closing - here is the debug log from a device (Motorola Milestone, Android 2.2.1/Cyanogen 6.1):
Code: GLBasic [Select]
I/SDL     ( 4497): [STUB] GL_UnloadLibrary
D/dalvikvm( 4497): threadid=9: thread exiting, not yet detached (count=0)
D/dalvikvm( 4497): threadid=9: thread exiting, not yet detached (count=1)
E/dalvikvm( 4497): threadid=9: native thread exited without detaching
E/dalvikvm( 4497): VM aborting
I/DEBUG   ( 4448): *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
I/DEBUG   ( 4448): Build fingerprint: 'MOTO_RTEU/umts_sholes/umts_sholes/sholes:2.2.1/SHOLS_U2_05.26.3/296482885:user/release-keys'
I/DEBUG   ( 4448): pid: 4497, tid: 4505  >>> com.yourcompany.test <<<
I/DEBUG   ( 4448): signal 11 (SIGSEGV), fault addr deadd00d

For further explanation I'll just quote quote from here:
Quote
FWIW, fault address "deadd00d" indicates a deliberate VM abort. Before aborting the VM writes an explanation to the log file; you should see it up above what you pasted here.
So there's a thread exiting without being detached from the VM, therefore the VM exits too. This seems to happen right after GL_UnloadLibrary is called, so that's the place where to look for it.

Another thing is that I found many exit()s in the code. You really should avoid using that since Android is designed to care of exiting applications itself. You should just close your activity instead (Activity.finish() from Java; read this if you want to call it from a different thread).

MrTAToad

  • Guest
Re: Android - Beta SDK
« Reply #152 on: 2011-May-11 »
I had to get rid of the extra quotes to get the palm program to run - its possible that it may work on XP machines though... :zzz:

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10713
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Android - Beta SDK
« Reply #153 on: 2011-May-13 »
Hotpatch 2 released. The 3D examples work all properly now.

MrTAToad

  • Guest
Re: Android - Beta SDK
« Reply #154 on: 2011-May-13 »
Will be downloading it later and giving it a good poke...

Offline ampos

  • Prof. Inline
  • *****
  • Posts: 1594
    • View Profile
    • AMpostata Website
Re: Android - Beta SDK
« Reply #155 on: 2011-May-13 »
Hotpatch 2 released. The 3D examples work all properly now.

Is the jpeg thing fixed for WebOS? (just for testing...)
check my web and/or my blog :D
http://diniplay.blogspot.com (devblog)
http://www.ampostata.org
http://ampostata.blogspot.com
I own PC-Win, MacBook 13", iPhone 3G/3GS/4G and iPAC-WinCE

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10713
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Android - Beta SDK
« Reply #156 on: 2011-May-13 »
It's compiled wit -O0, yes. I hope it's fixed.

MrTAToad

  • Guest
Re: Android - Beta SDK
« Reply #157 on: 2011-May-13 »
Unfortunately it crashes out.. :(

Offline ampos

  • Prof. Inline
  • *****
  • Posts: 1594
    • View Profile
    • AMpostata Website
Re: Android - Beta SDK
« Reply #158 on: 2011-May-13 »
The jpeg library also saves?

Code: GLBasic [Select]
SAVEBMP "image.jpg"
check my web and/or my blog :D
http://diniplay.blogspot.com (devblog)
http://www.ampostata.org
http://ampostata.blogspot.com
I own PC-Win, MacBook 13", iPhone 3G/3GS/4G and iPAC-WinCE

Offline Kitty Hello

  • code monkey
  • Administrator
  • Prof. Inline
  • *******
  • Posts: 10713
  • here on my island the sea says 'hello'
    • View Profile
    • http://www.glbasic.com
Re: Android - Beta SDK
« Reply #159 on: 2011-May-13 »
Yes. If the first character of the file extension is a "j".

MrTAToad

  • Guest
Re: Android - Beta SDK
« Reply #160 on: 2011-May-13 »
Android crashes with JPEG too

There are no textures with webOS 3D

With the hot hot fix, it's getting a bit further on the Pre (the first jpeg is displayed), but it seems to crash on the LOADSPRITE "",1 part...

Android displays the first two pictures and then crashes


[attachment deleted by admin]
« Last Edit: 2011-May-13 by MrTAToad »

MrTAToad

  • Guest
Re: Android - Beta SDK
« Reply #161 on: 2011-May-14 »
Everything (everything I can test that is :) ) apart from the Windows CE Emulator version is working - that just hangs after displaying a picture.  No idea if the same thing happens on a real machine though...

Only thing left to do for this update is sorting the %% in the json file...

Offline freedomdown

  • Mc. Print
  • *
  • Posts: 13
    • View Profile
Re: Android - Beta SDK
« Reply #162 on: 2011-May-14 »
Is it possible to support the hardkeys on the phone like search, back and menu?

As that would solve the porblem of no multitouch on some phones for me.
Here's a link I found on the subject:
http://android-developers.blogspot.com/2009/12/back-and-other-hard-keys-three-stories.html
Code: GLBasic [Select]
@Override
public boolean onKeyDown(int keyCode, KeyEvent event)  {
    if (keyCode == KeyEvent.KEYCODE_BACK && event.getRepeatCount() == 0) {
        // do something on back.
        return true;
    }

    return super.onKeyDown(keyCode, event);
}

Offline spacefractal

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 3678
    • View Profile
    • Space Fractal
Re: Android - Beta SDK
« Reply #163 on: 2011-May-14 »
Multitouch on Android also fuzzy too, I found there is axisflips issues on many devices as well. So even its support it, you might been aware of that issue, something like this:
http://www.youtube.com/watch?v=qzhUzq6bTPg&feature=player_embedded

Also its is possible to checkout the screen destiny too (using platform info)?

Also is Android 2.2.x still required (even I would want to see a alternative 2.1.x too, since around 24% still use it and still release phones with that version). I'm not interesed on 1.X

PS. I have not read all pages, where is the minimum requirements really now (I gonna to read most of them now)?
Greedy Mouse - Karma Miwa - Spot Race - CatchOut - Android Extras - is on a vacation trip, home before end of few days in jan.

Offline spacefractal

  • Community Developer
  • Prof. Inline
  • ******
  • Posts: 3678
    • View Profile
    • Space Fractal
Re: Android - Beta SDK
« Reply #164 on: 2011-May-14 »
Also its would been sweet to set a 0x0 as resolution in the option, who means the startup window would use the user desktop resolution, or eventuelly just start as a hidden window.

This should work wonderful on Android (as well all other systems), so you seamless can use that resolution, detected by GETDESKTOPSIZE, without showing a awfull white window first.

My (still early) project is a landscape only game, but dedicated to support rotation, even GETDESKTOPSIZE might return a portrait mode (then its would just rotate 90 degree).

Here CreateScreen is a awesome to use for auto rotation.

Greedy Mouse - Karma Miwa - Spot Race - CatchOut - Android Extras - is on a vacation trip, home before end of few days in jan.