SGCT master (487fac4)
Simple Graphics Cluster Toolkit
Loading...
Searching...
No Matches
sgct::ScreenCapture Class Reference

This class is used internally by SGCT and is called when taking screenshots. More...

#include <sgct/screencapture.h>

Classes

struct  ScreenCaptureThreadInfo

Public Types

enum class  CaptureSource { Texture , BackBuffer , LeftBackBuffer , RightBackBuffer }
 The different file formats supported. More...
enum class  EyeIndex { Mono , StereoLeft , StereoRight }

Public Member Functions

 ScreenCapture (const Window &window, ScreenCapture::EyeIndex ei, int bytesPerColor, unsigned int colorDataType, bool addAlpha)
 ~ScreenCapture ()
void resize (ivec2 resolution)
 Initializes the PBO or re-sizes it if the frame buffer size have changed.
void saveScreenCapture (unsigned int textureId, CaptureSource capSrc=CaptureSource::Texture)
 This function saves the images to disc.

Detailed Description

This class is used internally by SGCT and is called when taking screenshots.

Member Enumeration Documentation

◆ CaptureSource

The different file formats supported.

Enumerator
Texture 
BackBuffer 
LeftBackBuffer 
RightBackBuffer 

◆ EyeIndex

enum class sgct::ScreenCapture::EyeIndex
strong
Enumerator
Mono 
StereoLeft 
StereoRight 

Constructor & Destructor Documentation

◆ ScreenCapture()

sgct::ScreenCapture::ScreenCapture ( const Window & window,
ScreenCapture::EyeIndex ei,
int bytesPerColor,
unsigned int colorDataType,
bool addAlpha )

◆ ~ScreenCapture()

sgct::ScreenCapture::~ScreenCapture ( )

Member Function Documentation

◆ resize()

void sgct::ScreenCapture::resize ( ivec2 resolution)

Initializes the PBO or re-sizes it if the frame buffer size have changed.

Parameters
resolutionThe pixel resolution of the frame buffer

◆ saveScreenCapture()

void sgct::ScreenCapture::saveScreenCapture ( unsigned int textureId,
CaptureSource capSrc = CaptureSource::Texture )

This function saves the images to disc.

Parameters
textureIdThe texture that will be streamed from the GPU if frame buffer objects are used in the rendering
capSrcThe object that should be captured

The documentation for this class was generated from the following file: