Umbra namespace

Namespace for the Umbra API.

Contents

Classes

class Allocator
Allocator interface for dynamic memory allocations.
class AssetJob
A request to either load or unload a texture/mesh/material.
class CameraTransform
A camera view frustum and the associated world transformation.
struct EnvironmentInfo
System info, capabilities, supported extensions etc.
class InputStream
Input byte stream abstraction.
class Logger
Logger interface.
class MaterialData
Data for creating a material.
class MeshData
Data for creating a mesh.
struct MetaData
Provides access to per-texel metadata.
class Model
Read-only model metadata.
class ModelCreateRequest
Asynchronous request to create a model.
class ModelVersion
Single version of a model.
class OutputStream
Output byte stream abstraction.
class Project
Read-only project metadata.
class ProjectApi
Interface to Umbra project web API.
struct ProjectContext
Identifier for a project/model.
class ProjectList
Read-only list of projects accessible to an account.
class ProjectRequest
Asynchronous request to fetch project list.
struct Renderable
Data for rendering a previously loaded mesh.
class RepositoryReader
Reading blobs.
class Runtime
Main runtime class.
class Scene
A scene is an umbrafied dataset.
class SceneCopy
A scene copy operation.
struct SceneInfo
Scene metadata.
class TextureData
Data for creating a texture.
class Uuid
Unique identifier.
class View
View into scenes.

Enums

enum MatrixFormat { MF_COLUMN_MAJOR = 0, MF_ROW_MAJOR = 1 }
The matrix format used when inputting and outputting matrices through this API.
enum TriangleWinding { WINDING_CCW, WINDING_CW, WINDING_TWO_SIDED }
Object triangle winding.
enum TextureType { TEXTURE_TYPE_DIFFUSE, TEXTURE_TYPE_NORMAL, TEXTURE_TYPE_LEGACY_UNUSED, TEXTURE_TYPE_SPECULAR, TEXTURE_TYPE_META_INDEX, TEXTURE_TYPE_COUNT }
Texture usage.
enum MaterialType { MATERIAL_TYPE_OPAQUE, MATERIAL_TYPE_TRANSPARENT, MATERIAL_TYPE_COUNT }
Base material usage.
enum ColorSpace { COLOR_SPACE_LINEAR, COLOR_SPACE_SRGB }
Gamma mode.
enum TextureWrapMode { TEXTURE_WRAP_REPEAT, TEXTURE_WRAP_CLAMP }
Texture wrap modes.
enum TextureFilterMode { TEXTURE_FILTER_POINT, TEXTURE_FILTER_BILINEAR }
Texture filter modes.
enum TextureFormat { TEXTURE_FORMAT_RGBA32, TEXTURE_FORMAT_RGB24, TEXTURE_FORMAT_BC1, TEXTURE_FORMAT_BC3, TEXTURE_FORMAT_BC4, TEXTURE_FORMAT_BC5, TEXTURE_FORMAT_ETC1_RGB, TEXTURE_FORMAT_RGBA_FLOAT32, TEXTURE_FORMAT_UNC1, TEXTURE_FORMAT_JPEG, TEXTURE_FORMAT_PNG, TEXTURE_FORMAT_BMP, TEXTURE_FORMAT_PSD, TEXTURE_FORMAT_TGA, TEXTURE_FORMAT_GIF, TEXTURE_FORMAT_HDR, TEXTURE_FORMAT_PIC, TEXTURE_FORMAT_PNM, TEXTURE_FORMAT_ASTC_4X4, TEXTURE_FORMAT_ASTC_5X4, TEXTURE_FORMAT_ASTC_5X5, TEXTURE_FORMAT_ASTC_6X5, TEXTURE_FORMAT_ASTC_6X6, TEXTURE_FORMAT_ASTC_8X5, TEXTURE_FORMAT_ASTC_8X6, TEXTURE_FORMAT_ASTC_10X5, TEXTURE_FORMAT_ASTC_10X6, TEXTURE_FORMAT_ASTC_8X8, TEXTURE_FORMAT_ASTC_10X8, TEXTURE_FORMAT_ASTC_10X10, TEXTURE_FORMAT_ASTC_12X10, TEXTURE_FORMAT_ASTC_12X12, TEXTURE_FORMAT_ARGB32, TEXTURE_FORMAT_R8, TEXTURE_FORMAT_PVRTC1_RGB4, TEXTURE_FORMAT_PVRTC1_RGBA4, TEXTURE_FORMAT_UINT8, TEXTURE_FORMAT_UINT16, TEXTURE_FORMAT_UINT32, TEXTURE_FORMAT_COUNT }
Texture formats.
enum LODTransitionDirection { LOD_TRANSITION_DIRECTION_X_MINUS = 0, LOD_TRANSITION_DIRECTION_X_PLUS, LOD_TRANSITION_DIRECTION_Y_MINUS, LOD_TRANSITION_DIRECTION_Y_PLUS, LOD_TRANSITION_DIRECTION_Z_MINUS, LOD_TRANSITION_DIRECTION_Z_PLUS, LOD_TRANSITION_DIRECTION_COUNT, LOD_TRANSITION_DIRECTION_NONE = LOD_TRANSITION_DIRECTION_COUNT }
LOD transition directions.
enum VertexAttribute { VertexAttribute_Position = 0, VertexAttribute_TextureCoordinate, VertexAttribute_Normal, VertexAttribute_Tangent, VertexAttribute_Last }
Vertex attribute name.
enum CoordinateSystem { CoordinateSystem_Undefined = -1, CoordinateSystem_Local_Meter = 0, CoordinateSystem_WGS84_Angular_Degree = 1 }
Input coordinate system. Local_Meter is generally assumed.
enum RequestStatus { Request_Ok = 0, Request_InProgress, Request_ConnectionError, Request_BadKeyError, Request_LicenseExpiredError, Request_BadLicenseTypeError, Request_ReadError, Request_UnknownError }
Status of an async request.
enum TextureCapabilityFlags { TextureCapabilityNone = 0, TextureCapabilityBC1 = 1 << 0, TextureCapabilityBC2 = 1 << 1, TextureCapabilityBC3 = 1 << 2, TextureCapabilityBC4 = 1 << 3, TextureCapabilityBC5 = 1 << 4, TextureCapabilityBC6H = 1 << 5, TextureCapabilityBC7 = 1 << 6, TextureCapabilityASTC = 1 << 7, TextureCapabilityETC1 = 1 << 8, TextureCapabilityETC2 = 1 << 9, TextureCapabilityEAC_R = 1 << 10, TextureCapabilityEAC_RG = 1 << 11, TextureCapabilityPVRTC1 = 1 << 12, TextureCapabilityPVRTC2 = 1 << 13, TextureCapabilityATC = 1 << 14, TextureCapabilityAll = 0xffffffffu }
Mask enum of supported texture formats.

Typedefs

using UserPointer = uint64_t
User-defined identifier for data referenced by both Umbra and user code UserPointers are set with AssetJob::finish.

Functions

auto contentProfileString(ContentProfile profile) -> const char*
auto compressedPointDataMax(int num) -> int
auto compressPointData(const int32_t* pointData, int num, uint8_t* output) -> int
void decompressPointData(const uint8_t* compressed, int size, int32_t* output, int num)
auto getSerializedSize(const BlobModel& model) -> uint32_t
auto getSerializedSize(const BlobObject& object) -> uint32_t
auto getSerializedSize(const BlobVolume& volume) -> uint32_t
auto getSerializedSize(const BlobTexture& texture) -> uint32_t
auto getSerializedSize(const BlobMaterial& material) -> uint32_t
auto getSerializedSize(const BlobNode& node) -> uint32_t

Enum details

enum Umbra::MatrixFormat

The matrix format used when inputting and outputting matrices through this API.

Enumerators
MF_COLUMN_MAJOR

column-major matrix format

row-major matrix format

MF_ROW_MAJOR

enum Umbra::TriangleWinding

Object triangle winding.

Enumerators
WINDING_CCW

counterclockwise

WINDING_CW

clockwise

WINDING_TWO_SIDED

double-sided triangles

enum Umbra::TextureType

Texture usage.

Indicates how the renderer is expected to use a texture and what kind of properties it can be expected to have.

Enumerators
TEXTURE_TYPE_DIFFUSE

RGB(A) diffuse/albedo map.

Alpha component may be present depending on format. Expected to be in SRGB color space.

TEXTURE_TYPE_NORMAL

Tangent space normal map. Requires transformation from [0,1] to [-1,1].

TEXTURE_TYPE_LEGACY_UNUSED

No longer used, but kept for backwards compatability.

TEXTURE_TYPE_SPECULAR

Specular multiplier from Unity material model.

Poorly defined, used mostly when source and final renderer are both Unity

TEXTURE_TYPE_META_INDEX

Index to a MetaData lookup.

TEXTURE_TYPE_COUNT

enum Umbra::MaterialType

Base material usage.

Roughly corresponds to a category of shader/rendering setup needed to correctly render a mesh.

Enumerators
MATERIAL_TYPE_OPAQUE

Basic opaque surface. Other properties applicable if relevant textures are present.

MATERIAL_TYPE_TRANSPARENT

Alpha blended surface. Alpha values are stored in the alpha channel of the diffuse texture.

MATERIAL_TYPE_COUNT

enum Umbra::TextureFormat

Texture formats.

Enumerators
TEXTURE_FORMAT_RGBA32
TEXTURE_FORMAT_RGB24
TEXTURE_FORMAT_BC1

Also known as DXT1.

TEXTURE_FORMAT_BC3

Also known as DXT5.

TEXTURE_FORMAT_BC4
TEXTURE_FORMAT_BC5
TEXTURE_FORMAT_ETC1_RGB
TEXTURE_FORMAT_RGBA_FLOAT32
TEXTURE_FORMAT_UNC1

Deprecated internal format, for backwards compatibility.

TEXTURE_FORMAT_JPEG
TEXTURE_FORMAT_PNG
TEXTURE_FORMAT_BMP
TEXTURE_FORMAT_PSD
TEXTURE_FORMAT_TGA
TEXTURE_FORMAT_GIF
TEXTURE_FORMAT_HDR
TEXTURE_FORMAT_PIC
TEXTURE_FORMAT_PNM
TEXTURE_FORMAT_ASTC_4X4
TEXTURE_FORMAT_ASTC_5X4
TEXTURE_FORMAT_ASTC_5X5
TEXTURE_FORMAT_ASTC_6X5
TEXTURE_FORMAT_ASTC_6X6
TEXTURE_FORMAT_ASTC_8X5
TEXTURE_FORMAT_ASTC_8X6
TEXTURE_FORMAT_ASTC_10X5
TEXTURE_FORMAT_ASTC_10X6
TEXTURE_FORMAT_ASTC_8X8
TEXTURE_FORMAT_ASTC_10X8
TEXTURE_FORMAT_ASTC_10X10
TEXTURE_FORMAT_ASTC_12X10
TEXTURE_FORMAT_ASTC_12X12
TEXTURE_FORMAT_ARGB32
TEXTURE_FORMAT_R8
TEXTURE_FORMAT_PVRTC1_RGB4
TEXTURE_FORMAT_PVRTC1_RGBA4
TEXTURE_FORMAT_UINT8
TEXTURE_FORMAT_UINT16
TEXTURE_FORMAT_UINT32
TEXTURE_FORMAT_COUNT

enum Umbra::VertexAttribute

Vertex attribute name.

Enumerators
VertexAttribute_Position

Position, 3x float.

VertexAttribute_TextureCoordinate

Texture Coordinate, 2x float.

VertexAttribute_Normal

Normal, 3x float.

VertexAttribute_Tangent

Tangent, 3x float.

VertexAttribute_Last

enum Umbra::RequestStatus

Status of an async request.

Enumerators
Request_Ok

Request is ready and results can be read.

Request_InProgress

Request in progress, should wait and call ProjectAPI::pump again.

Request_ConnectionError
Request_BadKeyError
Request_LicenseExpiredError
Request_BadLicenseTypeError
Request_ReadError
Request_UnknownError

enum Umbra::TextureCapabilityFlags

Mask enum of supported texture formats.

Umbra generates multiple output texture formats to support a wider variety of devices. Reporting as many supported texture formats as possible is likely to result in better performance/quality.

Enumerators
TextureCapabilityNone
TextureCapabilityBC1
TextureCapabilityBC2
TextureCapabilityBC3
TextureCapabilityBC4
TextureCapabilityBC5
TextureCapabilityBC6H
TextureCapabilityBC7
TextureCapabilityASTC
TextureCapabilityETC1
TextureCapabilityETC2
TextureCapabilityEAC_R
TextureCapabilityEAC_RG
TextureCapabilityPVRTC1
TextureCapabilityPVRTC2
TextureCapabilityATC
TextureCapabilityAll