Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice
  4. Dismiss Notice

Android Oreo Icon is incorrect on Unity 5.5.0p4

Discussion in 'Android' started by hba_infinity, Sep 1, 2017.

  1. hba_infinity

    hba_infinity

    Joined:
    May 30, 2016
    Posts:
    49
    We have had a few users of our game on Android Oreo report that the icon for our game is small on the new Android Oreo release. I've attached an image below of how the icon displays, which is smaller than the other icons.

    Are there any known ways to fix this?

    We are currently using Unity 5.5.0p4 (and would prefer not to upgrade our existing project to a later version due to the size of the game and time it would take to upgrade and test our entire project).

    OreoIconBug.jpg
     
  2. Evaldas_Unity

    Evaldas_Unity

    Unity Technologies

    Joined:
    Jun 23, 2016
    Posts:
    69
    Hey, thanks for the heads up about this.
    I am going to try to investigate this myself, but I would appreciate a bug report just in case.
    A new empty one should do just fine. Include the icon you used (or any other that reproduces this) and copy over the 'Project Settings' over from the original project, as I have a feeling they might have something to do with this. If you use a custom manifest, add that too.

    Oh, and devices that have this issue helps too.

    Oh and, post the Case ID here : )
     
    Last edited: Sep 1, 2017
  3. hba_infinity

    hba_infinity

    Joined:
    May 30, 2016
    Posts:
    49
    Hey Evaldas,

    I have uploaded a bug report of this issue, it can be found using Case ID 947966. This build contains only our Icon, Project Settings and our Android Manifest.

    The report was submitted on a Google Pixel, running Android 8. Unfortunately we currently do not have a device to test on, or a list of any other devices that have this issue.

    Thanks.
     
  4. Evaldas_Unity

    Evaldas_Unity

    Unity Technologies

    Joined:
    Jun 23, 2016
    Posts:
    69
  5. Stephane-Imbert

    Stephane-Imbert

    Joined:
    Dec 30, 2014
    Posts:
    14
    We are seeing the same issue with our game on a Pixel with Oreo.
    This is with the latest Unity patch for 5.6.3 (p4)
    Is there any update on a resolution or a workaround?
     
  6. acproctor

    acproctor

    Joined:
    Oct 28, 2015
    Posts:
    3
  7. _Paulius

    _Paulius

    Mobile Developer Unity Technologies

    Joined:
    Jul 8, 2014
    Posts:
    173
    We're working on adding support for Adaptive Icons. I can't say yet when exactly it will be available, but it will not be back ported to 5.x releases as it's tied to a new API for setting icons which supports images with multiple layers.
     
  8. dsurka

    dsurka

    Joined:
    Sep 30, 2012
    Posts:
    7
    @hba_infinity did you find workaround to fix that? I've tried some ways using the manifest but couldn't find any.
     
  9. dustinbahr

    dustinbahr

    Joined:
    Sep 10, 2012
    Posts:
    57
    Is there a workaround to define these adaptive icons manually until the ability is provided by Unity?
     
  10. _Paulius

    _Paulius

    Mobile Developer Unity Technologies

    Joined:
    Jul 8, 2014
    Posts:
    173
    Yury-Habets likes this.
  11. Stephane-Imbert

    Stephane-Imbert

    Joined:
    Dec 30, 2014
    Posts:
    14
    We have two projects, one with the issue and the other one without.
    This is using the exact same settings for the icon in both projects and the exact same image.
    Is there a similar workaround to tell Unity to NOT try to use adaptive icons?
     
  12. JuliusM

    JuliusM

    Unity Technologies

    Joined:
    Apr 17, 2013
    Posts:
    824
    As a workaround, starting with Unity 5.6 in player settings select "Target API Level" lower than 26. If you were using "Automatic" option before, I'd suggest to go with API level 25.
    If you are using Unity 5.5, go to your Android SDK manager and make sure that the latest installed Android API level is lower than 26 (remove API 26 or 27 if you have them installed).
     
    Last edited: Oct 26, 2017
  13. klicktock

    klicktock

    Joined:
    Jun 9, 2011
    Posts:
    7
    Waiting for this feature :)
     
  14. andrew-rc

    andrew-rc

    Joined:
    Jun 20, 2013
    Posts:
    10
    Hi. Is it possible to do this without Android Studio? Can I just edit Plugins/Android/AndroidManifest.xml and supply the additional .xml?

    We're not using Gradle or Android Studio, and I just want to edit the icon without adding new tools etc. Possible?
     
    Qbit86 and vivalavida like this.
  15. vivalavida

    vivalavida

    Joined:
    Feb 26, 2014
    Posts:
    85
    We're using Unity 5.4.4 and the installed sdk version is 24, we still are seeing a small square icon on Google Pixel.
     
  16. JuliusM

    JuliusM

    Unity Technologies

    Joined:
    Apr 17, 2013
    Posts:
    824
    sdk has at least 4 components which may have different versions. There is "build-tools", "platform-tools", "platforms" and "tools". When you say you have sdk version 24, I suspect you are talking about the tools version. Check what you have in <SDK_ROOT>/platforms. There should be directories named android-<version>. Make sure the highest version you have is not higher than android-25.
     
    Qbit86 and vivalavida like this.
  17. Baraphor

    Baraphor

    Joined:
    Nov 16, 2016
    Posts:
    32
    Is there an update on which Unity version will support this?
     
  18. _Paulius

    _Paulius

    Mobile Developer Unity Technologies

    Joined:
    Jul 8, 2014
    Posts:
    173
    Adaptive icons (for Oreo) and Round icons (for 7.1+) will be available in Unity 2018.1.
     
    Vilmantasj, Skjalg and andrew-rc like this.
  19. andrew-rc

    andrew-rc

    Joined:
    Jun 20, 2013
    Posts:
    10
    Thanks!
     
  20. Finjitzu

    Finjitzu

    Joined:
    Sep 8, 2011
    Posts:
    160
    Anyone try this?
     
  21. vivalavida

    vivalavida

    Joined:
    Feb 26, 2014
    Posts:
    85
    Hey, yes it worked.
     
  22. Kabu4ceGreen

    Kabu4ceGreen

    Joined:
    Oct 9, 2017
    Posts:
    2
    If someone is still confused, we worked it out with the last two comments here:
    https://forum.unity.com/threads/and...in-a-white-circle-but-not-all-of-them.501592/

    Basically:
    Create files:
    - ic_background.png and ic_foreground.png (names not necessary to be these) into Android/res/drawable -folder
    - app_icon.xml into Android/res/drawable-anydpi-v26 -folder

    The content of the xml (this is all you should need for this):
    <?xml version="1.0" encoding="utf-8"?>
    <adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
    <background android:drawable="@drawable/ic_background"/>
    <foreground android:drawable="@drawable/ic_foreground"/>
    </adaptive-icon>


    So the folder structure is:
    Plugins/Android/res/drawable/ic_background.png
    Plugins/Android/res/drawable/ic_foreground.png
    Plugins/Android/res/drawable-anydpi-v26/app_icon.xml

    Note:
    The foreground should be smaller (about half) of the background to be shown correctly (only tested on Pixel).
     
  23. tealm

    tealm

    Joined:
    Feb 4, 2014
    Posts:
    108
    A warning for users building Android apps on Unity 2018.1+, if you only provide a app icon in the default icon slot - users with adaptive/round-icons will see the unity logo as app icon.

    I've reported this to Unity, the provided default icon should also be used for the adaptive/round icons if possible - and if not they need to give proper warnings to developers that the default unity icon will be used.

    If you just want to avoid providing round/adaptive icons you can set the Target API level to 24 in PlayerSettings for Android.
     
    Last edited: Jun 20, 2018
  24. Yury-Habets

    Yury-Habets

    Unity Technologies

    Joined:
    Nov 18, 2013
    Posts:
    1,165
    @am_ can you please share the case number?
     
  25. tealm

    tealm

    Joined:
    Feb 4, 2014
    Posts:
    108
  26. alokright

    alokright

    Joined:
    Jul 12, 2018
    Posts:
    1
  27. Yury-Habets

    Yury-Habets

    Unity Technologies

    Joined:
    Nov 18, 2013
    Posts:
    1,165
    The support for round/adaptive icons is in Unity for quite some time at the moment.
     
  28. andrew-fray

    andrew-fray

    Joined:
    Jul 19, 2012
    Posts:
    149
    To avoid upgrading to 2018.1 just for adaptive icons, is there any way we can use 2017.4's gradle build system to do the below? I'm completely ignorant about its capabilities except "it's a build system".

     
  29. Yury-Habets

    Yury-Habets

    Unity Technologies

    Joined:
    Nov 18, 2013
    Posts:
    1,165
    I think integrating adaptive icons should be doable. @_Paulius knows more. :)
     
  30. _Paulius

    _Paulius

    Mobile Developer Unity Technologies

    Joined:
    Jul 8, 2014
    Posts:
    173
    @andrew_fray you don't need 2018.1 for that to work. If you are using 2017.4 and follow those steps Adaptive icons should work fine. We've just added Adaptive icons slots to Player Settings UI in 2018.1.
     
    andrew-fray likes this.
  31. iMobCoding

    iMobCoding

    Joined:
    Feb 13, 2017
    Posts:
    160
    Well, I didn't know about adaptive icons until my client pointed about it. During development, I've updated to Unity 2018.1 and then 2018.2, everything seemed to work fine, until client told me that on his device he sees the Unity icon instead of the custom one. On my testing device I had normal icons and couldn't see the problem, but he has a circular icons and newer android. So I ended up with adding adaptive icons in the player slot.

    But my question is, why Unity doesn't put default icon in the foreground slots of Adaptive Icons by itself? Why you decided to put unity icon there without any warning/info in the console? Can that be fixed?

    Best
     
  32. _Paulius

    _Paulius

    Mobile Developer Unity Technologies

    Joined:
    Jul 8, 2014
    Posts:
    173
  33. iMobCoding

    iMobCoding

    Joined:
    Feb 13, 2017
    Posts:
    160
    @_Paulius Thanks for clarifying. I just noticed that 2018.2.1 is out but according to release notes, that bug is still not fixed. I'll do a live test once I download, but I suspect it didn't manage to get into this release?
     
    GiorgioTurro likes this.
  34. _Paulius

    _Paulius

    Mobile Developer Unity Technologies

    Joined:
    Jul 8, 2014
    Posts:
    173
    No it's not in 2018.2.1, I can't give a specific version yet.
     
  35. iMobCoding

    iMobCoding

    Joined:
    Feb 13, 2017
    Posts:
    160
  36. -Aymeric-

    -Aymeric-

    Joined:
    Oct 21, 2014
    Posts:
    110
    The bug is still present in 2018.2.3f1 :(
     
    ina, demid, nekolyst and 1 other person like this.
  37. MetaDOS

    MetaDOS

    Joined:
    Nov 10, 2013
    Posts:
    141
    Is there any way to use square icon in Android 8?
     
  38. -Aymeric-

    -Aymeric-

    Joined:
    Oct 21, 2014
    Posts:
    110
    The bug is finally gone in 2018.2.4f1 :)
     
    Yury-Habets likes this.