• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Question about aliasing (analog clock hands)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question about aliasing (analog clock hands)


  • Subject: Re: Question about aliasing (analog clock hands)
  • From: "Eric E. Dolecki" <email@hidden>
  • Date: Mon, 7 Dec 2009 14:44:19 -0500

That's cool - when I used PNGs and rotated them, they looked all aliased on
the iPhone so I went with CAShapeLayers instead. Thanks for that link
though.

On Sun, Dec 6, 2009 at 12:21 AM, Scott Anguish <email@hidden> wrote:

> not sure if this is helpful, but on http://www.abandoninplace.com/ in
> SampleCode, there is an example of using a dial created with Core Animation.
>
> On Dec 3, 2009, at 3:34 PM, Eric E. Dolecki wrote:
>
> > Will do. One question - when I am rotating around z - it's using the top
> > left of the shapeLayer as the anchor point. Trying to set it differently
> > isn't changing the anchor point...
> >
> > CABasicAnimation *rotationAnimation;
> >
> > rotationAnimation =[CABasicAnimation animationWithKeyPath:@
> > "transform.rotation.z"];
> >
> > [rotationAnimation setFromValue:DegreesToNumber(0)];
> >
> > [rotationAnimation setToValue:DegreesToNumber(360)];
> >
> > [rotationAnimation setDuration:2.0f];
> >
> > [rotationAnimation setRepeatCount:10000];
> >
> > [shapeLayer setAnchorPoint:CGPointMake(240, 160)];
> >
> > [shapeLayer addAnimation:rotationAnimation forKey:@"rotate"];
> >
> > It just rotates around the top left corner (meaning it comes into and out
> of
> > view)... I am looking to simply spin the shape where it sits from it's
> > center.
> >
> >
> >
> > On Thu, Dec 3, 2009 at 3:17 PM, Kyle Sluder <email@hidden>
> wrote:
> >
> >> On Thu, Dec 3, 2009 at 12:07 PM, Eric E. Dolecki <email@hidden>
> >> wrote:
> >>> If I use CAShapeLayer, can I use CGAffineTransform on it? I need to
> pour
> >>> through the docs now I guess.
> >>
> >> Yes, please brush up on Core Animation.  You can apply arbitrary
> >> transformations to a layer, or you can use the rotation/position
> >> properties of the layer itself and let CA take care of all the nested
> >> coordinate systems for you.  Since the iPhone uses layers for pretty
> >> much all drawing, you're going to need to get a handle on Core
> >> Animation sooner rather than later.
> >>
> >> --Kyle Sluder
> >>
> >
> >
> >
> > --
> > http://ericd.net
> > Interactive design and development
> > _______________________________________________
> >
> > Cocoa-dev mailing list (email@hidden)
> >
> > Please do not post admin requests or moderator comments to the list.
> > Contact the moderators at cocoa-dev-admins(at)lists.apple.com
> >
> > Help/Unsubscribe/Update your Subscription:
> >
> > This email sent to email@hidden
>
>


--
http://ericd.net
Interactive design and development
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Question about aliasing (analog clock hands) (From: "Eric E. Dolecki" <email@hidden>)
 >Re: Question about aliasing (analog clock hands) (From: Kyle Sluder <email@hidden>)
 >Re: Question about aliasing (analog clock hands) (From: "Eric E. Dolecki" <email@hidden>)
 >Re: Question about aliasing (analog clock hands) (From: Kyle Sluder <email@hidden>)
 >Re: Question about aliasing (analog clock hands) (From: "Eric E. Dolecki" <email@hidden>)
 >Re: Question about aliasing (analog clock hands) (From: Scott Anguish <email@hidden>)

  • Prev by Date: Re: CAShapeLayer & CGAffineTransformMakeForRotation?
  • Next by Date: Re: Draw rounded NSImage
  • Previous by thread: Re: Question about aliasing (analog clock hands)
  • Next by thread: Making NSFetchedResultsController register changes to the entity's relationship, not just attributes
  • Index(es):
    • Date
    • Thread