Hi Erica, This question is a bit off topic, but I was hoping you could answer a question I have about you Recipie for Playing Audio with Celestial in chapter 7 of your book.
You mention that officially, the Celestial media framework is off limits, but unofficially it is great. Does that mean that the Celestial framework can only be used for apps intended to run on Jailbroken iPhones, or might a Celestial based program still make it through Apple’s review process. Is it apparent from looking at the binaries that Celestial has been used, or does it end up compiling in a manner that is similar to Audio Queue code?
I am really enjoying your book. Very nice job. I have 5 apps on the store, but your book is teaching me a lot.
This is useless for me…
I was so close to completing my project and then it won’t compile: “unrecognozed selector:initWithFrame:numberOfCovers:numberOfPlaceholders: to instance… ”
Sometimes it’s working and then not… I’ll use official APIs, as this is totally useless and you only get frustrated!
Comment by Erica Sadun | November 25, 2008 | 9:45 am
Forsword: Make sure both the Simulator and XCode are set to 2.2
I would like to use coverflow in this manner - start app - app is in portrait mode - when rotated to landscape mode - show coverflow - when rotated to portrait mode - coverflow view is removed
I tried using your code - it works the first time I turn to landscape mode - on the 2nd turn to landscape mode - it always fail on the line [self.cfView.cfLayer transitionIn:1.0f];
Stack Trace:
#0 0×931752d4 in CFRetain
#1 0×31dcfb9f in -[CALayer setContents:]
#2 0×30b41b4b in -[UICoverFlowLayer _setNewSelectedIndex:]
#3 0×30b45c7c in -[UICoverFlowLayer _updateTick]
#4 0×30b423e1 in -[UICoverFlowLayer transition:withCoverFrame:]
#5 0×30b42a5e in -[UICoverFlowLayer transitionIn:]
Erica, can you answer what is possibly a silly question: I had thought this would only work on a jailbroken device, but my 2.2 iPod touch is not, and it works fine.
I want desperately to use coverflow in an app I am writing but need to know if I use this code if it will be accepted in the app store?
Oddly enough, now this no longer works for me. I keep getting a ‘bad access’ error when trying to run on my iphone. In the simulator it runs, but only if I turn on ‘enable guard malloc’…I just don’t have enough objc experience to know where to look!
Comment by robertanton | December 9, 2008 | 12:22 pm
We built Yoga Trainer PRO on iTunes with implementation of Coverflow.
When we resubmitted with updates for 2.2 - the application was rejected.
See email from Apple - thought you might find this interesting.
Hello NexStudios Japan,
Upon further review of your applications, Yoga Trainer PRO and Yoga Trainer LITE cannot be posted to the App Store due to their usage of unpublished API. Usage of such non-public API, as outlined in the iPhone SDK Agreement section 3.3.1, is prohibited:
“3.3.1 Applications may only use Published APIs in the manner prescribed by Apple and must not use or call any unpublished or private APIs. ”
The non-public API that is included in your application comes from the CoverFlow API set.
[…] unreasonable. Bookbag was not the only iPhone app that was caught in this framework change. Here’s a comment on Erica Sadun’s weblog from a developer who used Sadun’s Cover Flow code for an application named Yoga Trainer Pro. The […]
I am having the same problem as “Comment by slingkid | December 2, 2008 | 3:40 pm”
I can run the original sample code smoothly, however it became quite unstable after I embedded the codes into my own project. Would you kindly help? Thanks
I also crashed in [UICoverFlowLayer _setNewSelectedIndex]. I had modified Erica’s 2.2 sample project (which runs ok) to use some jpegs instead of the rendered color circles. I tried scaling them to 200×200, and ran under NSZombie but didn’t see anything. Anyway, after seeing robertanton’s rejection notice, I’ll have to wait for Apple to publish this anyway.
It’s still a great book!
Comment by Erica Sadun | April 10, 2009 | 10:54 am
12 Comments »
Comment by gotmike | November 25, 2008 | 12:06 am
Hi Erica, This question is a bit off topic, but I was hoping you could answer a question I have about you Recipie for Playing Audio with Celestial in chapter 7 of your book.
You mention that officially, the Celestial media framework is off limits, but unofficially it is great. Does that mean that the Celestial framework can only be used for apps intended to run on Jailbroken iPhones, or might a Celestial based program still make it through Apple’s review process. Is it apparent from looking at the binaries that Celestial has been used, or does it end up compiling in a manner that is similar to Audio Queue code?
I am really enjoying your book. Very nice job. I have 5 apps on the store, but your book is teaching me a lot.
–Mike
Comment by Forsworn | November 25, 2008 | 9:33 am
This is useless for me…
I was so close to completing my project and then it won’t compile: “unrecognozed selector:initWithFrame:numberOfCovers:numberOfPlaceholders: to instance… ”
Sometimes it’s working and then not… I’ll use official APIs, as this is totally useless and you only get frustrated!
Comment by Erica Sadun | November 25, 2008 | 9:45 am
Forsword: Make sure both the Simulator and XCode are set to 2.2
Comment by slingkid | December 2, 2008 | 3:40 pm
I would like to use coverflow in this manner - start app - app is in portrait mode - when rotated to landscape mode - show coverflow - when rotated to portrait mode - coverflow view is removed
I tried using your code - it works the first time I turn to landscape mode - on the 2nd turn to landscape mode - it always fail on the line [self.cfView.cfLayer transitionIn:1.0f];
Stack Trace:
#0 0×931752d4 in CFRetain
#1 0×31dcfb9f in -[CALayer setContents:]
#2 0×30b41b4b in -[UICoverFlowLayer _setNewSelectedIndex:]
#3 0×30b45c7c in -[UICoverFlowLayer _updateTick]
#4 0×30b423e1 in -[UICoverFlowLayer transition:withCoverFrame:]
#5 0×30b42a5e in -[UICoverFlowLayer transitionIn:]
Comment by slingkid | December 2, 2008 | 3:42 pm
Also is there a way to dynamically change the number of items in the coverflow after the coverflow layer is constructed?
Comment by russhill | December 3, 2008 | 11:25 am
Erica, can you answer what is possibly a silly question: I had thought this would only work on a jailbroken device, but my 2.2 iPod touch is not, and it works fine.
I want desperately to use coverflow in an app I am writing but need to know if I use this code if it will be accepted in the app store?
Comment by alan | December 8, 2008 | 5:30 pm
Oddly enough, now this no longer works for me. I keep getting a ‘bad access’ error when trying to run on my iphone. In the simulator it runs, but only if I turn on ‘enable guard malloc’…I just don’t have enough objc experience to know where to look!
Comment by robertanton | December 9, 2008 | 12:22 pm
We built Yoga Trainer PRO on iTunes with implementation of Coverflow.
When we resubmitted with updates for 2.2 - the application was rejected.
See email from Apple - thought you might find this interesting.
Hello NexStudios Japan,
Upon further review of your applications, Yoga Trainer PRO and Yoga Trainer LITE cannot be posted to the App Store due to their usage of unpublished API. Usage of such non-public API, as outlined in the iPhone SDK Agreement section 3.3.1, is prohibited:
“3.3.1 Applications may only use Published APIs in the manner prescribed by Apple and must not use or call any unpublished or private APIs. ”
The non-public API that is included in your application comes from the CoverFlow API set.
Very frustrating.
Pingback by StringFoo :: Web Development Resources» Blog Archive » ? Private | January 31, 2009 | 10:02 am
[…] unreasonable. Bookbag was not the only iPhone app that was caught in this framework change. Here’s a comment on Erica Sadun’s weblog from a developer who used Sadun’s Cover Flow code for an application named Yoga Trainer Pro. The […]
Comment by ngheungyu | February 7, 2009 | 7:45 am
I am having the same problem as “Comment by slingkid | December 2, 2008 | 3:40 pm”
I can run the original sample code smoothly, however it became quite unstable after I embedded the codes into my own project. Would you kindly help? Thanks
Comment by gracion | February 26, 2009 | 3:59 pm
I also crashed in [UICoverFlowLayer _setNewSelectedIndex]. I had modified Erica’s 2.2 sample project (which runs ok) to use some jpegs instead of the rendered color circles. I tried scaling them to 200×200, and ran under NSZombie but didn’t see anything. Anyway, after seeing robertanton’s rejection notice, I’ll have to wait for Apple to publish this anyway.
It’s still a great book!
Comment by Erica Sadun | April 10, 2009 | 10:54 am
- (CoverFlowView *) initWithFrame: (CGRect) aRect andCount: (int) count
{
self = [super initWithFrame:aRect];
cfLayer = [[UICoverFlowLayer alloc] initWithFrame:[[UIScreen mainScreen] bounds] numberOfCovers:count numberOfPlaceholders:1];
[[self layer] addSublayer: (CALayer *) cfLayer];
// Add the placeholder (image stand-in) layer
CGRect phrect = CGRectMake(0.0f, 0.0f, 200.0f, 200.0f);
UIImageView *phimg = [[UIImageView alloc] initWithFrame:phrect];
[cfLayer setPlaceholderImage: [phimg layer] atPlaceholderIndex:0];
unsigned int *pharray = malloc(count * sizeof(int));
for (int i = 0; i < count; i++) pharray[i] = 0;;
[cfLayer setPlaceholderIndicesForCovers:pharray];
// Add its info (label) layer
label = [[UILabel alloc] init];
[label setTextAlignment:UITextAlignmentCenter];
[label setFont:[UIFont boldSystemFontOfSize:20.0f]];
[label setBackgroundColor:[UIColor colorWithRed:0.0f green:0.0f blue:0.0f alpha:0.0f]];
[label setTextColor:[UIColor colorWithRed:1.0f green:1.0f blue:1.0f alpha:0.75f]];
[label setNumberOfLines:2];
[label setLineBreakMode:UILineBreakModeWordWrap];
[cfLayer setInfoLayer:[label layer]];
return self;
}
– Erica
Comments RSS.
Leave a comment
You must be logged in to post a comment.