objective c - Animating Background image /layer in iPhone -



objective c - Animating Background image /layer in iPhone -

i started working on sample application, have objects(images) animated on uiview. have background image should animate along these objects.two animations should happen @ same time. background image occupies screen space , on top of other images should animated. guide me accomplish this.

i tried next things mentioned in link below.

(int = 0; < image_count; i++) [_imagearray addobject:[uiimage imagenamed:[nsstring stringwithformat:@"d%d.png", i]]]; _animatedimages = [[uiimageview alloc] initwithframe:cgrectmake( (screen_width / 2) - (image_width / 2), (screen_height / 2) - (image_height / 2) + status_bar_height, image_width, image_height)]; _animatedimages.animationimages = [nsarray arraywitharray:_imagearray]; _animatedimages.animationduration = 1.0; _animatedimages.animationrepeatcount = -1;

the iphone game background video or animated image?

but 2 animations happening independently. animate objects on top of background image need animated.if not possible can utilize layers or other object accomplish this.please suggest.

it seems `uiimageview' provides no way command time animation begins. there such api, it's in lower level coreanimation framework (which uiimageview must utilize in implementation...)

you re-implement own uiimageview animation.

then, set different animations relative timing, see "how can chain core animations different layers 1 after other?" , how grouping 2 cabasicanimation animations , kick them off @ exact same time?.

as don't need offset between layers animations want them run @ same time, should create caanimationgroup, , set of them same begintime.

the camediatiming protocol (implemented caanimation) pretty baldy documented - part you're interested in : timing core animations - check this post api clarification

iphone objective-c animation ios6 uiimageview

Comments

Popular posts from this blog

web services - java.lang.NoClassDefFoundError: Could not initialize class net.sf.cglib.proxy.Enhancer -

Accessing MATLAB's unicode strings from C -

javascript - mongodb won't find my schema method in nested container -