{"id":765,"date":"2010-11-09T18:50:53","date_gmt":"2010-11-10T00:50:53","guid":{"rendered":"http:\/\/www.philhassey.com\/blog\/?p=765"},"modified":"2010-11-09T18:50:53","modified_gmt":"2010-11-10T00:50:53","slug":"stealth-target-day-31-ipad-cleanup","status":"publish","type":"post","link":"https:\/\/www.philhassey.com\/blog\/2010\/11\/09\/stealth-target-day-31-ipad-cleanup\/","title":{"rendered":"Stealth Target: Day 31 &#8211; iPad cleanup"},"content":{"rendered":"<p>It took a bit of messing with provisioning profiles, but I got it to deploy to the iPad, eventually.<\/p>\n<p>I also add to add setup for the depth buffer into ES1Renderer.mm .. This is not included for whatever reason.<\/p>\n<p>Then I got to do some iPad specific tweaks &#8211; since the game was first for the desktop, some of the code is specific to the mouse interface.  I&#8217;ve wrapped some #ifdefs around those things to check for BUILD_DESKTOP or BUILD_TOUCH so I can have some code that checks for certain mouse buttons and some code that doesn&#8217;t.<\/p>\n<p>There&#8217;s a pretty good list of things I need to do however:<\/p>\n<p>&#8211; Get music and sound effects working<\/p>\n<p>&#8211; Get the mini-level preview screens working better.<\/p>\n<p>&#8211; Do some smarter backface culling<\/p>\n<p>&#8211; Avoid overdraw as much as possible<\/p>\n<p>&#8211; Smarter touch interface<\/p>\n<p>But in general, the game seems to work alright \ud83d\ude42<\/p>\n<p>So by changing my rendering to use GL_ONE (additive) blending, I can easily see where I have overdraw happening in my scene.<\/p>\n<p><a href=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/11\/DynamiteScreenSnapz061.png\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/11\/DynamiteScreenSnapz061.png\" alt=\"DynamiteScreenSnapz061\" title=\"DynamiteScreenSnapz061\" width=\"800\" height=\"622\" class=\"aligncenter size-full wp-image-766\" srcset=\"https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/11\/DynamiteScreenSnapz061.png 800w, https:\/\/www.philhassey.com\/blog\/wp-content\/uploads\/2010\/11\/DynamiteScreenSnapz061-300x233.png 300w\" sizes=\"auto, (max-width: 800px) 100vw, 800px\" \/><\/a><\/p>\n<p>That shot has GL based backface culling enabled, but I&#8217;m going to disable it so I can do my culling on the software size so I don&#8217;t use so much memory in my buffers.  Not sure if that will give me a performance gain or not, but it&#8217;s something to try out.<\/p>\n<p>To get the music working, I converted my .wav file to an .aac file using this command on OS X:<\/p>\n<pre>afconvert music1.wav -f adts<\/pre>\n<p>That seemed to produce an .aac file.  <\/p>\n<p>From investigating speed issues on the rendering, it seems my use of GL_LIGHTs is slowing down things considerably.  If I disable all my lights it renders much faster.  I may have to investigate some other options here.<\/p>\n<p>Anyway, it&#8217;s nice getting this game started on the iPad.  I think it&#8217;ll come together pretty quickly with another day of tweaks.<\/p>\n<p>-Phil<\/p>\n","protected":false},"excerpt":{"rendered":"<p>It took a bit of messing with provisioning profiles, but I got it to deploy to the iPad, eventually. I also add to add setup for the depth buffer into ES1Renderer.mm .. This is not included for whatever reason. Then I got to do some iPad specific tweaks &#8211; since the game was first for [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[116],"tags":[],"class_list":["post-765","post","type-post","status-publish","format-standard","hentry","category-dynamite"],"_links":{"self":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts\/765","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/comments?post=765"}],"version-history":[{"count":1,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts\/765\/revisions"}],"predecessor-version":[{"id":767,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/posts\/765\/revisions\/767"}],"wp:attachment":[{"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/media?parent=765"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/categories?post=765"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.philhassey.com\/blog\/wp-json\/wp\/v2\/tags?post=765"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}