Slash Screen Android Studio disproportionate

1

I am trying to create a splash screen of a mobile application with Android Studio, the case is that I try to do it with a 2732x2732 image since with ionic cordova I simply do the resources and it generates all the versions, however, I try to do it with android studio and I see myself badly. Currently the function does it correctly, only that I do not know how to resize the image. I do not think it necessary to attach the entire APP, but I attach everything related to the splash screen.

Thank you!

SplashActivity.java

public class SplashActivity extends AppCompatActivity {
@Override
protected void onCreate(@Nullable Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    Intent intent = new Intent(this, MainActivity.class);
    startActivity(intent);
    finish();


   }
}

Android Manifest.xml

  <activity android:name=".SplashActivity" android:theme="@style/SplashTheme">
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />
            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

styles.xlm

<style name="SplashTheme" parent="Theme.AppCompat.NoActionBar">
    <item name="android:windowBackground">@drawable/splash</item>
</style>

slash_screen.xlm

 <item>
    <bitmap
        android:layout_height="wrap_content"
        android:layout_width="wrap_content"
        android:gravity="center"
        android:src="@drawable/splash" />

</item>
    
asked by Guillem 23.11.2018 в 13:15
source

0 answers