in wallpaper service in oncreateEngine
texturesCreated = false;
...
if (!texturesCreated){
redCell = new Texture(BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.red_cell)), 64, 64));
blueCell = new Texture(BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.blue_cell)), 64, 64));
aNuc = new Texture(BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.nuc_a)), 64, 64));
tNuc = new Texture(BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.nuc_t)), 64, 64));
gNuc = new Texture(BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.nuc_g)), 64, 64));
cNuc = new Texture(BitmapHelper.rescale(BitmapHelper.convert(getResources().getDrawable(R.drawable.nuc_c)), 64, 64));
TextureManager.getInstance().addTexture("redCell", redCell);
TextureManager.getInstance().addTexture("blueCell", blueCell);
TextureManager.getInstance().addTexture("aNuc", aNuc);
TextureManager.getInstance().addTexture("tNuc", tNuc);
TextureManager.getInstance().addTexture("gNuc", gNuc);
TextureManager.getInstance().addTexture("cNuc", cNuc);
texturesCreated = true;
}
ERROR: Tried to set an undefined texture as default! - and because that i recreating rextures in onSurfaceCreated