Jump to content

Screenshot not including 2D layer


Chimpana
 Share

Recommended Posts

Hello,

I'm having some trouble getting a 2D layer included in CreateScreenshotUsingRenderTarget.

CreateScreenshot includes a BABYLON.Layer background texture when a screenshot is created, however CreateScreenshotUsingRenderTarget leaves it as transparent.

Is there a way to get the background to draw for CreateScreenshotUsingRenderTarget?

I've created a playground to demonstrate: https://playground.babylonjs.com/#P70R9J#3

Thanks!

Link to comment
Share on other sites

Hello!

Because CreateScreenshotUsingRenderTarget use render targets, you cannot capture features not rendered in the RT.

As you mentioned, you can use the CreateScreenshot function for that (and use the successCallback function to get the data back and why not store it into your own dynamic texture?)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...