Render Target Texture and Max SIze?

This one is weird, but is there a setting in CreateScreenshotUsingRenderTarget that looks at some max size variable or is dependent on hardware?

When generating screenshots, after updating to Babylon 6.x, there seems to be a max size screenshot I can pull when run from inside Docker/Ubuntu using NVidia drivers. The result is that the image returned is the expected width/height, but the pixels are all 100% transparent. I can step the size down and there’s some arbitrary line in which they render correctly, around 1960x1960. Above that and the results are empty.

Any flags I might try on the method call?

(I noticed this recent PR and was wondering if there’s a way this is pulling pixels from 0x0 somehow

)

let s add @Evgeni_Popov who created the PR.

There is no limit to the size of screenshots, with the exception of the maximum dimensions of 2D textures supported by the GPU.

I don’t see why there should be a limit in your case…

Can you test with the old code, which didn’t create an additional engine to generate the screenshot (https://playground.babylonjs.com/#YCCU8U#23)?

Still trying to repro this. If I just load up any scene in a different harness such as a Playground, it downloads the file and the image looks correct, so now I’m trying to figure out how to isolate what’s different.

It turns out that this is an issue with using an older version of Chrome. In order to fix this I just needed to use the latest version.

2 Likes