Plugin not installed but build log says it is, and Android 12 splashscreen issues

Ok great, I’ll look forward to hearing the outcome.

I have two Android app updates queued ready to publish once we know what we need to do regarding the splash screens.

Do you have your own splashscreens, or are you using AppStudio’s auto generate feature?

I’m using the autogenerate feature.

Cool! Then add this line to your config.xml: (In Project Properties - VoltBuilder):

<preference name="AndroidWindowSplashScreenAnimatedIcon" value="resources/splashTemplate.png" />

If you want a black background, add this one too:

<preference name="AndroidWindowSplashScreenBackground" value="#000000" />

Ok great, I’ll give it a go.

Thank you.

That worked,

Correction, I had run it on the wrong app, its still using the cordova splash screens…

The “AndroidWindowSplashScreenAnimatedIcon” value does not exist. Cordova’s default will be used.
Wrote out Android application SplashScreen Color to /platforms/android/app/src/main/res/values/colors.xml
The “AndroidWindowSplashScreenBrandingImage” is undefined. Cordova’s default will be used.

1 Like

I’ll revert back to Android 11 for the time being.

EDIT: I cant revert back to Android 11 because the firebase plugin requires 12.

I looked at the log. This project does not use the autogenerate feature. There is no “resources/splashTemplate.png”.

If you set one up, it should work.

Ah, sorry I miss-understood.

I assumed as I only have one splash screen in project properties and VoltBuilder adjusts that splash screen for all the sizes I assumed that’s what you meant by autogenerate.

Here’s what your resources folder looks like:

Screen Shot 2022-08-25 at 4.23.26 PM

I don’t think I have that before an actual build, I’m using AppStudio

I’m still getting this error:

The “AndroidWindowSplashScreenAnimatedIcon” value does not exist. Cordova’s default will be used.

I have added a new folder “resources” in my project folder and inside the “resources” folder “splashTemplate.png”

In my config I have:

 <preference name="AndroidXEnabled" value="true" /> 
 <preference name="android-installLocation" value="auto" />
 <preference name="android-minSdkVersion" value="21" />
 <preference name="android-targetSdkVersion" value="31" />
 <preference name="AndroidWindowSplashScreenAnimatedIcon" value="resources/splashTemplate.png" />
 <resource-file src="www/google-services.json" target="app/google-services.json" />
</platform>

I see it’s inside the platform tag.

Try moving it to the top level, with the other preferences.

Yes I have tried that previously, do we need another line something like this
<resource-file src="splashTemplate.png" target="resources/splashTemplate.png" />

I managed to quickly open the voltbuilder file that gets auto-generated when “Build with voltBuilder” and it only has these related folders > resources > android > icon > splash.

Do I need another line of code or setting to use the splashTemplate.png

Almost there:
Replace:

<preference name="AndroidWindowSplashScreenAnimatedIcon" value="resources/splashTemplate.png" />

With:

<preference name="AndroidWindowSplashScreenAnimatedIcon" value="resources/android/icon/drawable-xxxhdpi-icon.png" />

And the icon is used as the splash screen, although a round edge had been added some how.

Finally, using this

<preference name="AndroidWindowSplashScreenAnimatedIcon" value="resources/android/splash/drawable-port-xxxhdpi-screen.png" />

works but the actual image is squashed and very small.

First, can you zip your AppStudio project files and send them directly to me? I’d like to see what is going on under the covers.

The image you are currently pointing it probably isn’t in the optimal format. Google has documented how the splash screen image should be laid out here.

Sure, I have just emailed it.

Thank you.

Android 12 splash screen SOLVED: It seems we need an additional image for the Android 12 splash screen.

My app has images in it which I put inside a folder “images” so I put the extra splash screen in there and referenced to it in the config file:

<preference name="AndroidWindowSplashScreenAnimatedIcon" value="www/images/android12Splash.png" />

Dont forget to add “images” in Project Properties extraFiles so the folder “images” (and its contents) is added during the android build process under the file path “www/” hence including the “www/” in the config file shown above.

The important part is the spec of the image used. I tested it with the default android asset, see image below.

Note gifs are not supported so I used a .png. image I tested with size is 432x432 px, you need to allow for cropping so leave plenty of space around the icon image like below. Personally I will just replace the icon in the image below to my own icon.

test

Alliteratively to use your existing default splash screen just reference to it in your config: (Not forgetting to add the folder in which your splash screen resides to “Project Properties > extraFiles”

 <preference name="AndroidWindowSplashScreenAnimatedIcon" value="www/XXXX/splash.png" />

XXXX = the folder where your splash screen is in your Project folder.