Kzb file loader.
More...
#include <kanzi/core.ui/kzb/kzb_file.hpp>
Kzb file loader.
Stores all kzb information. This includes dictionaries for strings, files, property types, metaclasses. Resource manager refers to the KzbFile dictionaries when loading resources. Internally uses KzbMemoryParser to parse the values from files.
Container type for property values.
Type specifying maximum size of files. Currently at 4Gb.
kanzi::KzbFile::KzbFile |
( |
Domain * |
domain, |
|
|
unique_ptr< File > |
file |
|
) |
| |
|
explicit |
Constructor.
- Parameters
-
domain | The UI domain. |
file | File to read from. |
kanzi::KzbFile::~KzbFile |
( |
| ) |
|
Open a file by path.
Throws an error if file is not found.
- Parameters
-
- Returns
- File opened.
Tries to open file by path.
Silently returns an empty unique pointer if file is not found.
- Parameters
-
- Returns
- File opened.
Load a resource identified by path.
- Parameters
-
- Returns
- Resource loaded.
Gets load task for given path.
- Parameters
-
- Returns
- Load task created.
Domain* kanzi::KzbFile::getDomain |
( |
| ) |
const |
const Metaclass* kanzi::KzbFile::getMetaclass |
( |
size_t |
index | ) |
const |
Gets metaclass by index.
- Parameters
-
- Returns
- Metaclass.
Gets property type by index.
- Parameters
-
index | Index of property type. |
- Returns
- Property type.
string_view kanzi::KzbFile::getString |
( |
size_t |
index | ) |
const |
Gets string from string dictionary by index.
- Parameters
-
- Returns
- View into string.
string kanzi::KzbFile::getProjectName |
( |
| ) |
const |
Gets project name.
Project name is the base filename part of the URL identifying a kzb file. This corresponds to what is called a 'hostname' in URLs. Kzb files loaded are identified by this name. Multiple kzb files can correspond to the same project name in the ResourceManager.
Gets the color workflow The Color workflow that is used to generate a kzb file.
Collects resource URLs in for a kzb file.
- Parameters
-
urls | List to store URLs to. |
vector<string> kanzi::KzbFile::collectFileNames |
( |
| ) |
const |
Collects all file names in a kzb file.
- Returns
- Vector of file names.
const uint16_t kanzi::KzbFile::KzbFormatVersionMajor |
|
static |
The version number for the current kzb format.
Increased when the format changes. Major versions represent mainline (master branch) changes. Minor versions represent changes done on a specific branch. Version history:
- 0.0. The initial version. Used in Kanzi 3.6.1.
- 1.0. Introduced new versioning format that removes the Kanzi tool version from the kzb. Used in Kanzi 3.6.2.
- 2.0. Added multisample samples to render target textures. Cubemap images are flipped already in Kanzi Studio.
- 3.0. Added simple render target mode toggle to render target textures. Used in Kanzi 3.6.4.
- 4.0. Quaternion field order and Euler to quaternion algorithm changed.
- 5.0. Added enum to bindings specifying whether they are value sources or property modifiers.
- 6.0. Added To Source bindings. Changed order of fields in binding data to support To Source bindings.
- 7.0. Added render pass prefabs and render pass templates.
- 8.0. Reordered the MessageRouting enum, removed everything related to MessageRoutingDirect from Kanzi Engine.
- 9.0. Storing resource dictionary text resource strings locally.
- 10.0 Support for deferred loading of state node component templates.
- 11.0. Font file converted to FontFile. Font Family resource introduced.
- 12.0. Added bindings and changed uniform representation in material types. Changed precedence to target type in bindings, added render value binding target.
- 13.0. Added range binding processors.
- 14.0. Added color workflow.
- 15.0. Added Data Triggers.
- 16.0. Added data type field for shader uniforms.
- 17.0. Added binding texture access functions.
- 18.0. Consolidated Face To Camera properties.
- 19.0. Added parametric primitives.
- 20.0. Added stride to exported vertex data with necessary padding.
- 21.0. Remove LightEnabled property.
- 22.0. Added arguments to Write Log Action.
- 23.0. Added geometry, tessellation control, and tessellation evaluation shaders.
- 24.0. Added optional data texture to Morph.
- 25.0. Moved setting of Screen::HostNameProperty to Kanzi Studio.
- 26.0. Added bindings and child effects to Node Effect 2D prefabs.
- 27.0. Added Cubemap Render Target Texture.
- 27.1. Added inside out parameters for box and sphere primitives.
const uint16_t kanzi::KzbFile::KzbFormatVersionMinor |
|
static |
The documentation for this class was generated from the following file: