Files
UnrealEngineUWP/Engine/Source/Developer/CrashTracker/Public/Interfaces/ICrashTrackerModule.h
Ben Marsh 20bf0eb6a1 Updating copyright notices to 2017 (copying from //Tasks/UE4/Dev-Copyright-2017).
#rb none
#lockdown Nick.Penwarden

[CL 3226823 by Ben Marsh in Main branch]
2016-12-08 08:52:44 -05:00

83 lines
1.8 KiB
C++

// Copyright 1998-2017 Epic Games, Inc. All Rights Reserved.
#pragma once
#include "CoreMinimal.h"
#include "Modules/ModuleInterface.h"
namespace EWriteUserCaptureVideoError
{
/**
* Enumerates video capture write error codes.
*/
enum Type
{
None,
/** The video capture instance was invalid. */
VideoCaptureInvalid,
/** Video capture is not running. */
CaptureNotRunning,
/** Failed to create destination directory for the video. */
FailedToCreateDirectory,
};
}
/**
* Interface for crash tracker modules.
*/
class ICrashTrackerModule
: public IModuleInterface
{
public:
/**
* Forces the crash tracker to complete capturing as if the program had crashed.
*/
virtual void ForceCompleteCapture() = 0;
/**
* Invalidates the current crash tracker frame being generated.
*/
virtual void InvalidateCrashTrackerFrame() = 0;
/**
* Checks if the crash tracker is currently enabled.
*/
virtual bool IsCurrentlyCapturing() const = 0;
/**
* Checks if the crash tracker is available.
*/
virtual bool IsVideoCaptureAvailable() const = 0;
/**
* Enables or disables crash tracking while in flight.
*/
virtual void SetCrashTrackingEnabled(bool bEnabled) = 0;
/**
* Updates the crash tracker, which may trigger the capture of a frame.
* Will also begin capturing if it hasn't begun already.
*/
virtual void Update(float DeltaSeconds) = 0;
/**
* Write the current crash tracker as a user video.
*
* @param OutFinalSaveName The path and name of the file the video was saved as.
* @return If the video was successfully written will return EWriteUserCaptureVideoError::None, otherwise returns an error code.
*/
virtual EWriteUserCaptureVideoError::Type WriteUserVideoNow( FString& OutFinalSaveName ) = 0;
public:
/**
* Virtual destructor.
*/
virtual ~ICrashTrackerModule( ) { }
};