is Open GL a Overkill for a 2d Card Game?

孤街醉人 提交于 2019-12-23 19:20:18

问题


I was just have an idea of creating a card game and I was just thinking whether to use OpenGl or CoreAnimation.Can you please tell me whether it would be a bit of a overkill to use OpenGL for s 2D card game.Thanks :)


回答1:


It's hard to say without knowing more. You can get pretty far using CALayers, images or drawing with quartz for the cards though. It really depends on the level of visual effects you are considering. If it's just moving cards around, then I'd say use layers.




回答2:


Might want to check out GeekGameBoard.

"A small framework for building board and card games, using Apple's Core Animation."




回答3:


Given that Core Animation uses OpenGL for rendering, you probably won't notice much of a difference in performance or memory usage. I don't think that you would gain anything by using OpenGL. Plus, you would have to handle all the animations on your own, as opposed to the prebuilt "set it and forget it" technique in Core Animation.



来源:https://stackoverflow.com/questions/1566874/is-open-gl-a-overkill-for-a-2d-card-game

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!