Google said in the new android 12 splash screen documentation :
Starting in Android 12, the SplashScreen API enables a new app launch animation for all apps when running on a device with Android 12 or higher. This includes an into-app motion at launch, a splash screen showing your app icon, and a transition to your app itself.
This means you can create a splash screen for your app without any extra activity or layouts. Just select your background and logo and the splash screen will do it for you.
You can also load data on the splash screen and once it's done you can navigate to the new activity.
You can read more about that in the official documentation clicking this link.
The new splash screen works also on older devices just implement the following library :
implementation 'androidx.core:core-splashscreen:1.0.0-rc01'
Once done create the new android 12 splash screen style and set it from AndroidManifest.xml then install it from the java activity file.
You can follow the instructions from this video :
Finally here is the source code :
Download