Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Is the media plugin support target 26 now? — Gideros Forum

Is the media plugin support target 26 now?

target 26 is required by the google play, it's unable to update to target 26 if the project using media plugin, how to resolve it?

Likes: antix

+1 -1 (+1 / -0 )Share on Facebook

Comments

  • XmanXman Member
    I remember I had asked why the media plugin can not work when set the target SDK to larger than 22 years ago, it seems the answer was the project can only support 22 by then.
    If the project is not using any plugin, I can set it to target 28 directly and it works fine, however, when the media plugin is used, set it to above 22 will not work.

    Likes: antix

    +1 -1 (+1 / -0 )Share on Facebook
  • I've not tested on 28, just 26 - but not tested media at all. I used to use media but I only used it for a couple of things that are now taken care of by other methods - saving png, etc...

    Likes: totebo

    Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!).
    https://deluxepixel.com
    +1 -1 (+1 / -0 )Share on Facebook
  • I've also stopped using the Media plugin in favour of native Gideros functions. What are you planning to do with Media @Xman?
    My Gideros games: www.totebo.com
  • XmanXman Member
    @totebo, I am using the media plugin to take photo and select picture from album.
  • XmanXman Member
    I don't plan to do anything new with the media, I just want to update my old project to target sdk to 26, but the media plugin will not work, I do not know why this happen.
  • What is the error displayed?
    Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!).
    https://deluxepixel.com
  • XmanXman Member
    it shows Error while reading image file
  • hgy29hgy29 Maintainer
    This would certainly be a permission issue. I notice that media plugin needs EXTERNAL_STORAGE permissions, which are now classified as dangerous (since API 23) and require special handling.

    Which API calls are you using ?
  • XmanXman Member
    when set target to 22,only READ_EXTERNAL_STORAGE is needed.
    I use the takePicture and getPicture.
  • hgy29hgy29 Maintainer
    Can you change line 201 in GMedia.java to use cache dir instead of external dir ? That may fix it:

    String storageDir = sActivity.get().getCacheDir(null).toString();
  • XmanXman Member
    Still the same error.
  • XmanXman Member
    when select image from the album,an alert popup says:
    Warning: /data/user/0/com.test.game/cache/20180806_162037_gideros.jpg:Error while reading image file.
  • Look in the folder (somehow) - copy out the file and see if it's a valid jpg.

    That way you know if it's image writing or image reading that's the problem.
    Coder, video game industry veteran (since the '80s, ❤'s assembler), arrested - never convicted hacker (in the '90s), dad of five, he/him (if that even matters!).
    https://deluxepixel.com
  • XmanXman Member
    Is that caused by runtime permission is not support by the export project template?
Sign In or Register to comment.