Skip to content

Commit

Permalink
enable screenshots for librw
Browse files Browse the repository at this point in the history
  • Loading branch information
aap committed Jan 21, 2021
1 parent 8e825fa commit 6df52f0
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/skel/glfw/glfw.cpp
Original file line number Diff line number Diff line change
@@ -202,6 +202,10 @@ psGrabScreen(RwCamera *pCamera)
RwImageSetFromRaster(pImage, pRaster);
return pImage;
}
#else
rw::Image *image = RwCameraGetRaster(pCamera)->toImage();
if(image)
return image;
#endif
return nil;
}
4 changes: 4 additions & 0 deletions src/skel/win/win.cpp
Original file line number Diff line number Diff line change
@@ -249,6 +249,10 @@ psGrabScreen(RwCamera *pCamera)
RwImageSetFromRaster(pImage, pRaster);
return pImage;
}
#else
rw::Image *image = RwCameraGetRaster(pCamera)->toImage();
if(image)
return image;
#endif
return nil;
}

0 comments on commit 6df52f0

Please sign in to comment.