Jump to content

Search the Community

Showing results for tags 'offscreen render'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Standards
    • Coding and Game Design
    • Paid Promotion (Buy Banner)
  • Frameworks
    • Pixi.js
    • Phaser 3
    • Phaser 2
    • Babylon.js
    • Panda 2
    • melonJS
    • Haxe JS
    • Kiwi.js
  • General
    • General Talk
    • GameMonetize
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered
    • Marketplace (Sell Apps, Websites, Games)

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


Twitter


Skype


Location


Interests

Found 2 results

  1. Hi Drawing invisible objects on a canvas causes performance loss. What's the best way you know to prevent this? I think there are two options: adding a mask to the all-encompassing container and changing the renderable property to false. I may have misunderstood the masking feature. I wonder which one is more logical to prevent unseen elements from being drawn in the scene? To change the Renderable property, it is necessary to loop through and check each element with a for loop. Wouldn't that be compelling for each frame?
  2. Hi all, I'm looking to optimize our game by rendering chunks of our game grid offscreen and only redrawing them when something inside them animates/dies. The way i do it at the moment is as follows: Creating the render texture and adding it to a group: var renderTexture = game.add.renderTexture(name, width, height);var renderSprite = new phaser.Sprite(game, x, y, renderTexture);renderSprite.parent = undefined;var index = parent.getIndex(replaceChild);parent.addAt(renderSprite, index);return renderSprite;And rendering it: target.renderXY(object, object.x, object.y, clear);Note that I have to set the renderSprite's parent to undefined, otherwise Phaser 1.1.5 crashes trying to disconnect the sprite from its current parent. This was not an issue in 1.1.4. However, on Android stock browser ( note, not the Galaxy S4 which uses a Chromium fork ), it just refuses to render anything. Any ideas on this? Thanks in advance, David Goemans
×
×
  • Create New...