Struct ResourceExtractor::Result
Defined in File resource-extractor.h
Nested Relationships
This struct is a nested type of Class ResourceExtractor.
Struct Documentation
-
struct Result
Parameters for interpreting data obtained from a ResourceExtractor::Request.
Public Types
-
enum class State
Enumeration of possible states of ResourceExtractor::Result.
Values:
-
enumerator PENDING
Indicates that a ResourceExtractor::Request::Info has been created but not yet submitted.
-
enumerator SUCCESS
Indicates that a ResourceExtractor::Request::Info has been submitted and the resource was successfully extracted.
-
enumerator FAILURE_UNKNOWN
Indicates that a ResourceExtractor::Request::Info has been submitted and failed for an unknown reason.
-
enumerator FAILURE_UNSUPPORTED
Indicates that a ResourceExtractor::Request::Info was submitted for a pResourceInfo which does not support extraction.
-
enumerator FAILURE_NO_RESOURCE_INFO_SPECIFIED
Indicates that a ResourceExtractor::Request::Info was submitted wihout a pResourceInfo.
-
enumerator FAILURE_RESOURCE_INFO_MISMATCH
Indicates that a ResourceExtractor::Request::Info was submitted with a pResourceInfoEx that does not reference the given pResourceInfo.
-
enumerator FAILURE_REGION_OUT_OF_BOUNDS
Indicates that a ResourceExtractor::Request::Info was submitted with a BufferRegion or TextureRegion outside of the bounds of the given pResourceInfo.
-
enumerator FAILURE_INTERNAL
Indicates that an internal error occured, indicates that GPA Framework maintenance is required.
-
enumerator PENDING
Public Functions
-
operator bool() const
Converts this ResourceExtractor::Result to a value indicating whether or not it's valid.
Note
A valid ResourceExtractor::Result has a state of State::SUCCESS, a non zero value for dataSize, and a non null pointer for pData
Public Members
-
State state = {State::PENDING}
This ResourceExtractor::Result object's state.
-
size_t dataSize = {0}
The size in bytes of the resource data referenced by this ResourceExtractor::Result.
-
uint8_t *pData = {nullptr}
A pointer to the resource data referenced by this ResourceExtractor::Result.
-
api_types::Format format = {api_types::GPA_FORMAT_UNKNOWN}
Pixel format of the result data. May be different to original texture format (planes)
-
size_t rowPitch = {0}
The size in bytes of a single row of data.
-
size_t slicePitch = {0}
The size in bytes of a single slice of data.
-
enum class State