summaryrefslogtreecommitdiff
path: root/src/skel/win
diff options
context:
space:
mode:
authorSergeanur <s.anureev@yandex.ua>2020-08-14 18:57:23 +0300
committerSergeanur <s.anureev@yandex.ua>2020-08-14 18:57:23 +0300
commite7945625b59750459ff4876f7e076b4b8d5c3aee (patch)
tree0021cf5c59fa4e9600b732d221627c349eb0fc5d /src/skel/win
parent489743da419b0da842e82dc6d430f6f3d8752055 (diff)
Original screen grabber
Diffstat (limited to 'src/skel/win')
-rw-r--r--src/skel/win/win.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/skel/win/win.cpp b/src/skel/win/win.cpp
index cf4749b1..a064788c 100644
--- a/src/skel/win/win.cpp
+++ b/src/skel/win/win.cpp
@@ -241,6 +241,23 @@ psCameraShowRaster(RwCamera *camera)
/*
*****************************************************************************
*/
+RwImage *
+psGrabScreen(RwCamera *pCamera)
+{
+#ifndef LIBRW
+ RwRaster *pRaster = RwCameraGetRaster(pCamera);
+ if (RwImage *pImage = RwImageCreate(pRaster->width, pRaster->height, 32)) {
+ RwImageAllocatePixels(pImage);
+ RwImageSetFromRaster(pImage, pRaster);
+ return pImage;
+ }
+#endif
+ return nil;
+}
+
+/*
+ *****************************************************************************
+ */
RwUInt32
psTimer(void)
{