mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-05 19:11:50 +00:00
fix render advanced pipeline issues
This commit is contained in:
parent
0ab23a117d
commit
ac9772cd67
12 changed files with 192 additions and 86 deletions
|
|
@ -519,6 +519,7 @@ public:
|
|||
}
|
||||
|
||||
std::unique_ptr<ImageData> takeScreenshot() override {
|
||||
glBindFramebuffer(GL_FRAMEBUFFER, 0);
|
||||
auto data = std::make_unique<ubyte[]>(size.x * size.y * 3);
|
||||
glPixelStorei(GL_PACK_ALIGNMENT, 1);
|
||||
glReadPixels(0, 0, size.x, size.y, GL_RGB, GL_UNSIGNED_BYTE, data.get());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue