Note that there are some explanatory texts on larger screens.

plurals
  1. POAnimation logo type in android
    primarykey
    data
    text
    <p>I have an android app. When user clicks in my launcher icon, I want to open an Activity that contains my logo(with animation) like Skype for seconds. First, I copy my .png files(consider 5 images) in <code>res/drawable</code>.(every my <code>.png</code> file size is 100kb). Next in res/anim/animation I write:</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;animation-list xmlns:android="http://schemas.android.com/apk/res/android"&gt; &lt;item android:drawable="@drawable/a" android:duration="30"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/b" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/c" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/d" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/e" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/f" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/g" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/h" android:duration="2000"&gt;&lt;/item&gt; &lt;item android:drawable="@drawable/i" android:duration="2000"&gt;&lt;/item&gt; &lt;/animation-list&gt; </code></pre> <p>and in MainActivity.java:</p> <pre><code>public class MainActivity extends Activity { protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); ImageView matn=(ImageView) findViewById(R.id.imageView2); matn.setBackgroundResource(R.anim.animation); AnimationDrawable anim2=(AnimationDrawable) matn.getBackground(); anim2.start(); } } </code></pre> <p>I use Frame-by-Frame and this way doesn't work (my logo with animation). (if I use low size png files, it runs on emulator but in big size it doesn't work.) It's important for me it runs without any click.(runs automatically). My emulator RAM is 768MB, and VM heap is 512MB.</p> <p>Would you please help me?! Or show me another way with lower size (because this <code>.png</code> files size is move than 500kb!!!!! it's too much). Thanks a lot.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload