I need to create frame by frame, but I have some problems I have 30 png images that make up my animation, I load my AnimationDrawable with this code:
mCurrentAnimation = new AnimationDrawable();
mCurrentAnimation.setOneShot(true);
int resId;
for (int j = 1; j < 31; j++)
{
resId = getResources().getIdentifier("resName", "drawable", "com.mindcolorstest.main");
mCurrentAnimation.addFrame(getResources().getDrawable(resId), 1);
}
And logically "mCurrentAnimation.start ()" to run On the mdpi device, the animation works fine, but I have some problems with the duration of each frame, on the hdpi emulator or device, I have some lag, and if I reduce the duration of the frames (like on mdpi device, and on hdpi), the animation will not go faster, for example, there is a minimum duration for each frame. Some tips and tricks? I don’t know what should I do Q_Q Thanks anyway