What is the fastest way to draw single pixels directly to the screen in an iPhone application?

后端 未结 4 1605
后悔当初
后悔当初 2021-01-03 04:21

I am looking the fastest way to draw thousands of individually calculated pixels directly to the screen in an iPhone application that preforms extremely well.

4条回答
  •  Happy的楠姐
    2021-01-03 04:42

    In all graphics frameworks I've ever used, the way you'd do this is to write your pixels into a block of memory (in ARGB or RGBA format for example), and then push the whole block of memory to the graphics subsystem. No "draw one point" API can possibly be fast, if you want to draw thousands of pixels quickly you need to push an image/texture/bitmap/whatever-you-want-to-call-it, rather than pushing individual points one at a time.

提交回复
热议问题