Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
lord funk
Feb 16, 2004

Is it typical for the beta iOS releases to drain the battery like mad? My phone has been sucked dry over the last few days.

Adbot
ADBOT LOVES YOU

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.
I don't know about typical but it's certainly not uncommon.

ultramiraculous
Nov 12, 2003

"No..."
Grimey Drawer

lord funk posted:

Is it typical for the beta iOS releases to drain the battery like mad? My phone has been sucked dry over the last few days.

I've been wondering if it's just the network overload around WWDC and the terrible reception in Sausalido, or iOS6 is just hogging right now. Definitely experiencing quick battery drain.

ManicJason
Oct 27, 2003

He doesn't really stop the puck, but he scares the hell out of the other team.
Are both debuggers totally broken and useless for everyone else in 4.3.3, or are my company's machines just haunted? GDB randomly turns off breakpoints at its own convenience. LLDB still won't print anything but "id is ambiguous" in the console.

That and the total lack of retain/release statements in the allocations instrument is making me really hate Apple this week.

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.
Yeah they're both a bit weird in 4.3. It's not just you.

Also, whenever I see "ManicJason" I read it as "manic JSON" and try to imagine what that notation would look like.

ManicJason
Oct 27, 2003

He doesn't really stop the puck, but he scares the hell out of the other team.
Imagine working in a shop that uses JSON for absolutely everything and being named Jason. I pretend I work with a bunch of robots that talk about people right behind their backs.

"JAY SON MAKES THINGS MUCH EASIER"

lord funk
Feb 16, 2004

ultramiraculous posted:

I've been wondering if it's just the network overload around WWDC and the terrible reception in Sausalido, or iOS6 is just hogging right now. Definitely experiencing quick battery drain.

Yeah my fully charged phone didn't make it through the night. Guess I'll have to plug it in constantly for the next few months...

In code related news, I imagine the audio app community is going to explode over the new inter-application audio bus thing. If I have time I hope I can figure it out before the flood of emails starts pouring in. :)

rjmccall
Sep 7, 2007

no worries friend
Fun Shoe

ManicJason posted:

That and the total lack of retain/release statements in the allocations instrument is making me really hate Apple this week.

Allocations is specifically designed to capture the lifetimes of objects, not their entire history. If you want that history, you should be using the Leaks instrument, which AFAICT gives you exactly the same ability to browse allocations but also captures the retain/release history of the object.

dereekb
Nov 7, 2010

What do you mean "error"?
Alright, I've got a few minor questions:

Have any of you played with the new maps, and what are its messages like in relation to the current Maps? Is it difficult to switch maps if I'm using annotations? (Or actually, I guess this might be under the developer preview NDA so maybe I should just go see for myself.)


And for some reason, when the navigation controller pushes a new viewController that has a button on the right side, I guess this button gets animated or something but it does this while animating the animation:



I'm using a custom segue that is doing the "crossfade" animation. It pops there for like a split second and then is fine once the view is loaded, but I'm wondering if anyone else has run into that and managed to figure out what is causing it.

coaxmetal
Oct 21, 2010

I flamed me own dad
So, this has likely been mentioned in here before, but someone introduced me to http://www.rubymotion.com/ today. It's ios in ruby.


As someone with a passing familiarity with ruby, and a passing familiarity with ios development, and a dislike for obj-c, it looks pretty attractive. Anyone here used it? I guess it's $40 for an education license, can't publish but isn't really too much so I might give it a shot.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Ronald Raiden posted:

So, this has likely been mentioned in here before, but someone introduced me to http://www.rubymotion.com/ today. It's ios in ruby.


As someone with a passing familiarity with ruby, and a passing familiarity with ios development, and a dislike for obj-c, it looks pretty attractive. Anyone here used it? I guess it's $40 for an education license, can't publish but isn't really too much so I might give it a shot.

I've used it. You can even make your apps with IB in Xcode if you want. I love it so much.

duck monster
Dec 15, 2004

Our android guy at work had a funny comment about rubymotion: "IOS developers are insufferable enough. Mix in ruby hipsters into that mess just seems cruel."

Just-In-Timeberlake
Aug 18, 2003
Does anyone else have the issue that you can't import .ics events into the calendar in iOS 6 (from safari, haven't tried from Mail)? I'm trying to test something and the only options I have are Dropbox and Evernote.

If the functionality isn't there yet that's fine, just want to make sure I'm not missing something in settings.

klem_johansen
Jul 11, 2002

[be my e-friend]
[oh wait]

klem_johansen fucked around with this message at 21:01 on Jun 17, 2012

the talent deficit
Dec 20, 2003

self-deprecation is a very british trait, and problems can arise when the british attempt to do so with a foreign culture





How long did it take last year for WWDC2011 videos to go up on the developer site?

Carthag Tuek
Oct 15, 2005

Tider skal komme,
tider skal henrulle,
slægt skal følge slægters gang



They were up on the 23rd. Keynote was the 6th afaict from a quick Google.

duck monster
Dec 15, 2004

Is IOS 6 still penned in to not support the Ipad 1? One of my clients is talking about pulling out of an ipad deployment and waiting on the win8 pads because they are not confident apple will provide long term support if a 2 year old device is losing software updates :(

e: Tried to get some answers from an apple consultant and he had no idea what a "security update" is and kept ranting about something called "airwatch" which is a loving useless answer for me when I want to know if a retired model is going to get vunerability patches.

duck monster fucked around with this message at 05:07 on Jun 18, 2012

Built 4 Cuban Linux
Jul 15, 2007

i own america
I'm trying to make my app compatible with iOS 4.2 (may be a waste of time) and it seemed pretty easy, but then I had some runtime crashes because the compiler (for some reason) didn't point out that some method signatures didn't exist in 4.2 (even though I picked 4.2 as my build target).

For example:

[self dismissViewControllerAnimated:YES completion:^{TFLog(@"back to main menu");}];

Results in this error:

2012-06-17 22:37:50.761 MyApp [1993:f803] -[MyView dismissViewControllerAnimated:completion:]: unrecognized selector sent to instance 0x6b9fe30

But this works:

[self dismissModalViewControllerAnimated:YES];


Why isn't this caught while compiling? Thanks.

xgalaxy
Jan 27, 2004
i write code

Built 4 Cuban Linux posted:

I'm trying to make my app compatible with iOS 4.2 (may be a waste of time) and it seemed pretty easy, but then I had some runtime crashes because the compiler (for some reason) didn't point out that some method signatures didn't exist in 4.2 (even though I picked 4.2 as my build target).

For example:

[self dismissViewControllerAnimated:YES completion:^{TFLog(@"back to main menu");}];

Results in this error:

2012-06-17 22:37:50.761 MyApp [1993:f803] -[MyView dismissViewControllerAnimated:completion:]: unrecognized selector sent to instance 0x6b9fe30

But this works:

[self dismissModalViewControllerAnimated:YES];


Why isn't this caught while compiling? Thanks.

The short answer is that objective-c doesn't call a method, it does message passing. Message passing is handled / resolved at runtime, not compile time. That said, Xcode could do a much better job than it does now of letting you know what is available in which versions of the sdks.

Doc Block
Apr 15, 2003
Fun Shoe

duck monster posted:

Is IOS 6 still penned in to not support the Ipad 1? One of my clients is talking about pulling out of an ipad deployment and waiting on the win8 pads because they are not confident apple will provide long term support if a 2 year old device is losing software updates :(

Seems like they're only supporting devices they're still selling. And they aren't selling the iPad 1 anymore.

Also, tell them good luck with the Win 8 tablets :lol:

quote:

e: Tried to get some answers from an apple consultant and he had no idea what a "security update" is and kept ranting about something called "airwatch" which is a loving useless answer for me when I want to know if a retired model is going to get vunerability patches.

AFAIK Apple doesn't backport iOS security fixes. So no, if a device isn't supported by the latest iOS version then that's it, no more software updates at all.


Built 4 Cuban Linux posted:

I'm trying to make my app compatible with iOS 4.2 (may be a waste of time) and it seemed pretty easy, but then I had some runtime crashes because the compiler (for some reason) didn't point out that some method signatures didn't exist in 4.2 (even though I picked 4.2 as my build target).

For example:

[self dismissViewControllerAnimated:YES completion:^{TFLog(@"back to main menu");}];

Results in this error:

2012-06-17 22:37:50.761 MyApp [1993:f803] -[MyView dismissViewControllerAnimated:completion:]: unrecognized selector sent to instance 0x6b9fe30

But this works:

[self dismissModalViewControllerAnimated:YES];


Why isn't this caught while compiling? Thanks.

What is your deployment target set to?

And yeah, it seems like a waste of time supporting 4.2. Maybe support 4.3.

I'm dropping pre-5.0 support in my apps. Over 80% of device owners are on iOS 5, according to Apple. The number of iOS 4 users is dwindling by the day, and trying to keep feature parity across OS versions meant (for me) implementing a lot of stuff myself that iOS 5 has built-in (like UIAlertViews with text entry fields in them).

I don't want to be one of those developers that only supports the latest iOS version, but as a one-man operation with a limited device budget, I can't keep a crapload of devices with really old iOS versions on them for testing just to support a small minority of users with ever-increasing maintenance costs.

edit: also, check your warnings. The Objective-C compiler can't treat an unknown method as an error, because that method might be added at run-time (clang should throw a warning, though). And, as xgalaxy said, an Objective-C method call isn't a function call like C++, it uses message passing instead.

Doc Block fucked around with this message at 05:21 on Jun 18, 2012

Doc Block
Apr 15, 2003
Fun Shoe
edit: whoops

duck monster
Dec 15, 2004

Doc Block posted:

Seems like they're only supporting devices they're still selling. And they aren't selling the iPad 1 anymore.

Also, tell them good luck with the Win 8 tablets :lol:

Yeah yeah, I know. Try convincing some ridiculous consultant who believes microsoft literally poo poo rainbows of goodness, however. :(

quote:

AFAIK Apple doesn't backport iOS security fixes. So no, if a device isn't supported by the latest iOS version then that's it, no more software updates at all.

And *that* is a major problem for corporate rollouts who tend to think in terms of 5-10 years rather than 2 years when seeking software support. I guess theres a tax argument that if the effective life of an ipad is 2 years, then applying a super steep depreciation rate to the value of the device has tax benefits, but still, its not necessarily enough to convince them its a not a bad bet. gently caress.

Doc Block
Apr 15, 2003
Fun Shoe
It's not like every iPad 1 is going to stop working when iOS 6 comes out, though.

Maybe if enough people beg they'll have limited support for the iPad 1 in iOS 6.

duck monster
Dec 15, 2004

Doc Block posted:

It's not like every iPad 1 is going to stop working when iOS 6 comes out, though.

Maybe if enough people beg they'll have limited support for the iPad 1 in iOS 6.

Right, but if a new browser or email (or whatever) exploit emerges (And because of jailbreaking, people are looking *hard* for those) that makes it unsafe to bring an ipad 1 onto the net, it'll render them almost useless for corporate road warriors if they cant get a patch. Thats the core concern.

Doc Block
Apr 15, 2003
Fun Shoe
My knowledge of that whole scene is limited, but doesn't most of the jailbreaking work target the latest iOS version?

I don't envy people who have to support corporate/enterprise users.

some kinda jackal
Feb 25, 2003

 
 
I'm bummed that my OG iPad won't get 6, but I'm MORE scared that people will start compiling with 6 as the minimum target without even using 6+ features, cutting out the OG for no good reason.

I'm planning on keeping mine, even if I do end up getting a new one.

xgalaxy
Jan 27, 2004
i write code
Yea for my game projects I'm not sure what I'll do yet.
Adoption of 6 should be just as ubiquitous a 5 except for the iPad 1 deal.
The built in Facebook integration alongside Twitter means I can finally trim out a bunch of aging and bloated crap third party libraries. And the game center improvements seem nice.

Doc Block
Apr 15, 2003
Fun Shoe
Probably gonna keep my iPad 1 for iOS 5 testing. Hopefully iOS 6 will have as good of an adoption rate as iOS 5 did.

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.
I really hope that there is a Siri API in 6, but I doubt it. I "doubted" a Retina MBP, so I don't know what to think.

Just-In-Timeberlake
Aug 18, 2003

Martytoof posted:

I'm bummed that my OG iPad won't get 6, but I'm MORE scared that people will start compiling with 6 as the minimum target without even using 6+ features, cutting out the OG for no good reason.

I'm planning on keeping mine, even if I do end up getting a new one.

You know you've made it when instead of a stack of magazines in your bathroom you just keep an old iPad in there.

Jehde
Apr 21, 2010

Earlier I posted asking about how to get a Quartz 2D drawing into an iOS app and it was ignored, I was told the question was too vague. I managed to figure it out anyways, but I'm having troubles with the next step, which is to add things to the drawing through methods. (in main or another class)

So far I have this block for the Quartz 2D drawing:
Objective-C code:
#import "draw2d"

@implementation draw2d
- (id)initWithFrame:(CGRect)frame {
    self = [super initWithFrame:frame];
    if (self) {
        // Initialization code. [EMPTY]
    }
    return self;
}
- (void)drawRect:(CGRect)rect {
	CGContextRef context = UIGraphicsGetCurrentContext();
	//Draw code. [Giant block of path drawings.]	
}
- (void)dealloc {
    [super dealloc];
}
@end
And I'm trying to update the drawing and add to it using a method from another class. The application of this is drawing out a path on the image given an array of nodes with coordinates, which are generated in a seperate class outside of the UIView. Do I need to create some sort of function in the Quartz drawing that acts on some sort of event triggered? How're the nodes' coordinates passed into Quartz? I don't really have any experience in iOS development and I need to get this up and running tonight, so any help would be greatly appreciated.

Jehde fucked around with this message at 18:58 on Jun 18, 2012

pokeyman
Nov 26, 2006

That elephant ate my entire platoon.
Keep the array of coordinates somewhere (maybe an instance variable in the view) and update that array as necessary. In -drawRect:, simply iterate through the array doing whatever drawing you need.

Whenever you change the array of coordinates, send -setNeedsDisplay to your view to have it redraw itself.

Jehde
Apr 21, 2010

pokeyman posted:

Keep the array of coordinates somewhere (maybe an instance variable in the view) and update that array as necessary. In -drawRect:, simply iterate through the array doing whatever drawing you need.

Whenever you change the array of coordinates, send -setNeedsDisplay to your view to have it redraw itself.

That sounds like it'll work, and I'll try implementing it now. But how would I pass the coordinate data into the Quartz drawing to fill the array with?

haveblue
Aug 15, 2005



Toilet Rascal

Jehde posted:

That sounds like it'll work, and I'll try implementing it now. But how would I pass the coordinate data into the Quartz drawing to fill the array with?

NSBezierPath is the basis for all vector drawing in Quartz. You can probably find some combination of its abilities that lets you draw the array how you want.

If you mean how do you get the array from the object that loaded it to the view subclass, there are a couple of ways. You could connect the two in the xib file, or have one expose itself with a class method (those are global).

haveblue fucked around with this message at 20:56 on Jun 18, 2012

Physical
Sep 26, 2007

by T. Finninho

duck monster posted:

Our android guy at work had a funny comment about rubymotion: "IOS developers are insufferable enough. Mix in ruby hipsters into that mess just seems cruel."
I got a new job as a ruby dev, and in the interview my boss asked me "How do you feel about ruby on rails."

I told him that I thought it was an elitist language that made things more difficult than they have to be. He laughed and I got the job. Ruby on Rails is awesome and takes away so many boring errors and setup that I would spend hours trying to troubleshoot.

Then I got an iPhone and met objective-c, talk about a loving hipster language.

What iOS 3d game engines/libraries would yous guys recommend?

Sinestro
Oct 31, 2010

The perfect day needs the perfect set of wheels.

Physical posted:

I got a new job as a ruby dev, and in the interview my boss asked me "How do you feel about ruby on rails."

I told him that I thought it was an elitist language that made things more difficult than they have to be. He laughed and I got the job. Ruby on Rails is awesome and takes away so many boring errors and setup that I would spend hours trying to troubleshoot.

Then I got an iPhone and met objective-c, talk about a loving hipster language.

What iOS 3d game engines/libraries would yous guys recommend?

Unity is from 400 to 1,900 dollars, but kickass. Although, for most things, it is like bring a minigun to deal with a fly.

Jehde
Apr 21, 2010

gooby on rails posted:

NSBezierPath is the basis for all vector drawing in Quartz. You can probably find some combination of its abilities that lets you draw the array how you want.

If you mean how do you get the array from the object that loaded it to the view subclass, there are a couple of ways. You could connect the two in the xib file, or have one expose itself with a class method (those are global).

Yeah I understand how to actually draw the path out once I have the coordinates, it's passing those coordinates into the UIView subclass and using it from there. The concept of xibs is completely foreign to me (I don't actually have Xcode or anything), I'll try looking into it though. Could you possibly elaborate on the other method though? Exposing via class method?

haveblue
Aug 15, 2005



Toilet Rascal
Class methods are a feature of Objective-C that let a class implement general functionality that's shared among all instances of that class. They aren't associated with a particular instance, but they live in the class's name space. You can use a class method to return a certain instance of that class to any caller anywhere in the program, so the view can fetch the array-storing object and then read the array out of it.

You could also just make the array a global variable in the first place, but most people consider that messy.

How are you going to run and test this if you don't actually have Xcode?

Toady
Jan 12, 2009

Physical posted:

Then I got an iPhone and met objective-c, talk about a loving hipster language.

That is the first time I've ever seen Objective-C called a hipster language.

Adbot
ADBOT LOVES YOU

Doc Block
Apr 15, 2003
Fun Shoe

Jehde posted:

That sounds like it'll work, and I'll try implementing it now. But how would I pass the coordinate data into the Quartz drawing to fill the array with?

If you have an object that's generating coordinates, just have it pass the coordinates to the view. Give the view an NSMutableArray instance variable, and have it loop through that and draw the coordinates.

Something like this:
code:
@implementation draw2d {
	NSMutableArray *_points;
}

- (id)initWithFrame:(CGRect)frame
{
	if(self = [super initWithFrame:frame]) {
		_points = [[NSMutableArray alloc] initWithCapacity:100];
	}
}

- (void)dealloc
{
	// if you aren't using ARC
	[_points release];

	[super dealloc];
}

- (void)addPoint:(CGPoint)point
{
	NSValue *val = [NSValue valueWithCGPoint:point];
	[_points addObject:val];
	[self setNeedsDisplay];
}

- (void)removeAllPoints
{
	[_points removeAllObjects];
	[self setNeedsDisplay];
}

- (void)drawRect:(CGRect)rect
{
	CGContextRef context = UIGraphicsGetCurrentContext();

	// Your existing drawing code goes here

	CGFloat black[4] = {0.0f, 0.0f, 0.0f, 1.0f};
	CGContextSetStrokeColor(context, black);
	
	// you can leave these next two lines out if you just want your nodes to be a continuation of
	// whatever your previous code is drawing
	CGContextBeginPath(context);
	CGContextMoveToPoint(context, 100, 100);	// or whatever your starting point is for the nodes

	for(NSValue *val in _points) {
		// pull out the CGPoint and draw it however you need to
		// for example
		CGPoint point = [val CGPointValue];
		CGContextAddLineToPoint(context, point.x, point.y);
	}
	
	CGContextStrokePath(context);
}
or something like that. Your object can just call [myView addObject:CGPointMake(X, Y)] and call [myView removeAllPoints] if you want to start over.

edit: not to be a jerk, but how/why are you doing this if you don't have Xcode and don't know enough Objective-C to know something basic like what a class method is?

Doc Block fucked around with this message at 21:28 on Jun 18, 2012

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply