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 > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 02-07-2009, 04:43 PM   #1 (permalink)
Registered Member
 
Join Date: Feb 2009
Posts: 4
Question draw pixels or modify the frame buffer???

hello folks,

i have a question regarding directly drawing pixels on the screen. i'm planning making a simple drawing program. i have to intensively modify the pixels on the screen.

on pc, i usually modify a huge 2d array that has the size of the screen, as this may be faster than directly drawing pixels on the screen. after i finish drawing on the screen, i then render the 2d array to the screen.

or maybe i will modify the frame buffer. but i'm really new to iphone development. i don't know if there is a frame buffer on iphone and what would be the best option to render pixels intensively.

thank you.
billconan is offline   Reply With Quote
Old 09-23-2009, 09:20 AM   #2 (permalink)
Otherwise
 
btschumy's Avatar
 
Join Date: Jan 2009
Location: Longmont, CO
Posts: 87
Send a message via AIM to btschumy
Default

Bill,

Did you ever find an answer to this? I'm in the same situation with respect to this need.
__________________
Bill Tschumy
www.otherwise.com
Longmont, CO
btschumy is offline   Reply With Quote
Old 09-23-2009, 12:09 PM   #3 (permalink)
Registered Member
 
Join Date: Jul 2008
Posts: 459
Default

There definitely is a framebuffer on the iPhone.

Have you checked out the GLPaint demo app? You can find it on developer.apple.com

It's a basic drawing app, using openGL. It might clear up a few things about framebuffers, etc... for you.

Hope, that was helpful.
__________________
Websites:
Friendlydeveloper - Coding Blog
Codingsessions - Live iOS Training

iPhone Apps:
TextPal - Powerful group messaging,
icePhone

Find me on LinkedIn
NewiPhoneDeveloper is offline   Reply With Quote
Old 09-23-2009, 01:49 PM   #4 (permalink)
Otherwise
 
btschumy's Avatar
 
Join Date: Jan 2009
Location: Longmont, CO
Posts: 87
Send a message via AIM to btschumy
Default

Thanks for the pointers.

I do have a related question about views and drawRect.

Say I put a UIView called filterView above all other views in a UIWindow (and it fully covers them). The filterView has an alpha of 0.1 to allow the underlying views to show through. Now when some underlying view calls setNeedsDisplay, I would would think that my filterViews drawRect would eventually be called it order to render properly.

However, that is not the case. The filterView's drawRect get called initially, but after that, underlying views will update themselves and filterView's drawRect will not get called. However if I set the background color of the filterView to some color, then the overall display is tinted by the filterView, so it is getting placed in play in that way.

Is there some other way to know when an area onscreen needs to be refreshed?
__________________
Bill Tschumy
www.otherwise.com
Longmont, CO
btschumy is offline   Reply With Quote
Reply

Bookmarks

Tags
pixel

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 251
18 members and 233 guests
ADY, AragornSG, BrianSlick, Dani77, Dattee, dre, glenn_sayers, HemiMG, JasonR, karlam963, nobre84, prchn4christ, Rudy, spiderguy84, themathminister, tomtom100, viniciusdamone, vvenkatachallam
Most users ever online was 1,187, 10-11-2011 at 08:09 AM.
» Stats
Members: 158,884
Threads: 89,229
Posts: 380,763
Top Poster: BrianSlick (7,129)
Welcome to our newest member, karlam963
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 02:19 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0