Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Mockup & CodeGen, iPhone & iPad
($9.99)

Make your own iPhone apps
and run them live!
(free)

Manu
($0.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum

View Single Post
Old 03-01-2010, 06:01 AM   #2 (permalink)
headkaze
Registered Member
 
headkaze's Avatar
 
Join Date: Feb 2010
Posts: 342
Default

Do each of the models need to be able to rotate and translate on their own? If so how do you intend on rendering them in a batch? The only way I'm aware this is possible is to use matrix transforms on the vertex data and that could be slow applying to that many vertices. If you use glRotate, glTranslate etc. you obviously can't do them all in a batch.

Also are you enabling GL_BLEND? This seems to be a big performance hit, if your models don't have alpha blending then disable it and make sure your model textures are 24 bit.

Are you using PVR texture compression? Are all your textures in one big texture atlas?

GL_TRIANGLE_STRIP is faster than GL_TRIANGLES but I don't see much of a performance hit for what you're doing. iPhone's main problem is alpha blending and fill rate. Of course the less texture and state changes the better.

The best way to find out where your bottle necks are is to profile your code. A simple way to do this is the following

Code:
NSDate *start, *stop;
NSTimeInterval duration;
	
start = [NSDate date];

// Do stuff

stop = [NSDate date];
duration = [stop timeIntervalSinceDate:start];
NSLog(@"Stuff: %f", duration);
There are also some great performance analysers in XCode (Run->Run with Performance Tool).

Last edited by headkaze; 03-01-2010 at 06:05 AM.
headkaze is offline   Reply With Quote
 

» Advertisements
» Stats
Members: 158,861
Threads: 89,223
Posts: 380,683
Top Poster: BrianSlick (7,129)
Welcome to our newest member, TamsiE
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 05:30 AM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.