Kerbal Space Program  1.12.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Events Macros
Static Public Member Functions | List of all members
Steamworks.SteamScreenshots Class Reference

Static Public Member Functions

static ScreenshotHandle AddScreenshotToLibrary (string pchFilename, string pchThumbnailFilename, int nWidth, int nHeight)
 
static ScreenshotHandle AddVRScreenshotToLibrary (EVRScreenshotType eType, string pchFilename, string pchVRFilename)
 
static void HookScreenshots (bool bHook)
 
static bool IsScreenshotsHooked ()
 
static bool SetLocation (ScreenshotHandle hScreenshot, string pchLocation)
 
static bool TagPublishedFile (ScreenshotHandle hScreenshot, PublishedFileId_t unPublishedFileID)
 
static bool TagUser (ScreenshotHandle hScreenshot, CSteamID steamID)
 
static void TriggerScreenshot ()
 
static ScreenshotHandle WriteScreenshot (byte[] pubRGB, uint cubRGB, int nWidth, int nHeight)
 

Member Function Documentation

static ScreenshotHandle Steamworks.SteamScreenshots.AddScreenshotToLibrary ( string  pchFilename,
string  pchThumbnailFilename,
int  nWidth,
int  nHeight 
)
inlinestatic

Adds a screenshot to the user's screenshot library from disk. If a thumbnail is provided, it must be 200 pixels wide and the same aspect ratio

as the screenshot, otherwise a thumbnail will be generated if the user uploads the screenshot. The screenshots must be in either JPEG or TGA format.

The return value is a handle that is valid for the duration of the game process and can be used to apply tags.

JPEG, TGA, and PNG formats are supported.

static ScreenshotHandle Steamworks.SteamScreenshots.AddVRScreenshotToLibrary ( EVRScreenshotType  eType,
string  pchFilename,
string  pchVRFilename 
)
inlinestatic

Adds a VR screenshot to the user's screenshot library from disk in the supported type.

pchFilename should be the normal 2D image used in the library view

pchVRFilename should contain the image that matches the correct type

The return value is a handle that is valid for the duration of the game process and can be used to apply tags.

JPEG, TGA, and PNG formats are supported.

static void Steamworks.SteamScreenshots.HookScreenshots ( bool  bHook)
inlinestatic

Toggles whether the overlay handles screenshots when the user presses the screenshot hotkey, or the game handles them. If the game is hooking screenshots,

then the ScreenshotRequested_t callback will be sent if the user presses the hotkey, and the game is expected to call WriteScreenshot or AddScreenshotToLibrary

in response.

static bool Steamworks.SteamScreenshots.IsScreenshotsHooked ( )
inlinestatic

Returns true if the app has hooked the screenshot

static bool Steamworks.SteamScreenshots.SetLocation ( ScreenshotHandle  hScreenshot,
string  pchLocation 
)
inlinestatic

Sets metadata about a screenshot's location (for example, the name of the map)

static bool Steamworks.SteamScreenshots.TagPublishedFile ( ScreenshotHandle  hScreenshot,
PublishedFileId_t  unPublishedFileID 
)
inlinestatic

Tags a published file as being visible in the screenshot

static bool Steamworks.SteamScreenshots.TagUser ( ScreenshotHandle  hScreenshot,
CSteamID  steamID 
)
inlinestatic

Tags a user as being visible in the screenshot

static void Steamworks.SteamScreenshots.TriggerScreenshot ( )
inlinestatic

Causes the Steam overlay to take a screenshot. If screenshots are being hooked by the game then a ScreenshotRequested_t callback is sent back to the game instead.

static ScreenshotHandle Steamworks.SteamScreenshots.WriteScreenshot ( byte[]  pubRGB,
uint  cubRGB,
int  nWidth,
int  nHeight 
)
inlinestatic

Writes a screenshot to the user's screenshot library given the raw image data, which must be in RGB format.

The return value is a handle that is valid for the duration of the game process and can be used to apply tags.


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