entity clipped when composite cache true

Post your help queries and engine programming questions here

entity clipped when composite cache true

Postby robaldred » Fri Apr 25, 2014 4:52 pm

Hey,
I wanted to composite cache to cache some pins elements in my game works.
Like pins & overlays.

It caches, however the entity seems to get clipped, I'm guessing it's bounding box is miscalculated.

Screen Shot 2014-04-25 at 16.45.21.png
Entity without caching
Screen Shot 2014-04-25 at 16.45.21.png (9.36 KiB) Viewed 5780 times

Screen Shot 2014-04-25 at 16.44.58.png
Entity with caching clipped
Screen Shot 2014-04-25 at 16.44.58.png (10.4 KiB) Viewed 5780 times


Here's my entity creation code:

Code: Select all
#coffeescript
      @_bubble = new IgeEntity()
         .translateBy(0,-50,0)
         .texture(ige.gameManager.textures.pins)
         .cellById('yellowbgbubble')
         .dimensionsFromCell()
         .layer(2)
         .scaleTo(0,0,0)
         .originTo(.5,1,.5)
         .opacity(0)

      @_icon = new IgeEntity()
         .translateBy(0,-5,0)
         .texture(ige.gameManager.textures.pins)
         .cellById('pills')
         .dimensionsFromCell()
         .mount(@_bubble)

                 @_bubble.compositeCache(true)


Anyone seen this before?
I don't work for Irrelon. All comments are my own.
I would strongly encourage anyone building production projects with Isogenic to buy a premium licence, it costs very little and will help towards continued development of the engine. Irrelon have spent thousands of hours developing this wonderful platform with many features found in AAA game engine.
User avatar
robaldred
 
Posts: 243
Joined: Wed Oct 23, 2013 8:09 pm
Location: Manchester, England

Re: entity clipped when composite cache true

Postby rob » Wed May 21, 2014 6:11 pm

Hmm that does seem odd. Does the entity have any origin setting different from default?
CEO & Lead Developer
Irrelon Software Limited
http://www.isogenicengine.com
User avatar
rob
Site Admin
 
Posts: 316
Joined: Tue Oct 22, 2013 5:08 pm

Re: entity clipped when composite cache true

Postby robaldred » Wed May 21, 2014 6:19 pm

Indeed it does, its the @_bubble entity in my code above.
Code: Select all
originTo(.5, 1, .5)


I this is another instance where we need to adjust the translation by the origin :) I'll investigate.

Thanks!
I don't work for Irrelon. All comments are my own.
I would strongly encourage anyone building production projects with Isogenic to buy a premium licence, it costs very little and will help towards continued development of the engine. Irrelon have spent thousands of hours developing this wonderful platform with many features found in AAA game engine.
User avatar
robaldred
 
Posts: 243
Joined: Wed Oct 23, 2013 8:09 pm
Location: Manchester, England


Return to Help & Questions

Who is online

Users browsing this forum: No registered users and 1 guest
cron