The cl-ktx Reference Manual

This is the cl-ktx Reference Manual, version 1.0.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Mon Feb 26 15:22:44 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 cl-ktx

An implementation of the Khronos KTX image file format

Maintainer

Yukari Hafner <>

Author

Yukari Hafner <>

Home Page

https://shinmera.github.io/cl-ktx/

Source Control

(GIT https://github.com/shinmera/cl-ktx.git)

Bug Tracker

https://github.com/shinmera/cl-ktx/issues

License

zlib

Version

1.0.0

Dependencies
  • binary-structures (system).
  • cl-opengl (system).
  • trivial-features (system).
  • documentation-utils (system).
Source

cl-ktx.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 cl-ktx/cl-ktx.asd

Source

cl-ktx.asd.

Parent Component

cl-ktx (system).

ASDF Systems

cl-ktx.


3.1.2 cl-ktx/package.lisp

Source

cl-ktx.asd.

Parent Component

cl-ktx (system).

Packages

org.shirakumo.ktx.


3.1.3 cl-ktx/ktx.lisp

Dependency

package.lisp (file).

Source

cl-ktx.asd.

Parent Component

cl-ktx (system).

Public Interface
Internals

3.1.4 cl-ktx/documentation.lisp

Dependency

ktx.lisp (file).

Source

cl-ktx.asd.

Parent Component

cl-ktx (system).


4 Packages

Packages are listed by definition order.


4.1 org.shirakumo.ktx

Source

package.lisp.

Use List
  • common-lisp.
  • org.shirakumo.binary-structures.types.
Public Interface
Internals

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Ordinary functions

Function: create-file (payloads gl-type gl-format &key width height depth face-count array-element-count mip-count gl-internal-format gl-base-internal-format gl-type-size keys)

Create a new file instance.

PAYLOADS should be a vector of data vectors to use for the mipmap levels to include in the file, stored in the correct order starting with level 0.

If GL-INTERNAL-FORMAT, GL-BASE-INTERNAL-FORMAT, or GL-TYPE-SIZE are not supplied, they are inferred based on the GL-TYPE and GL-FORMAT.

See FILE (type)

Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: make-mipmap-level (&key size data)

Create a new mipmap-level instance.

See MIPMAP-LEVEL (type)

Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-file (storage &rest args)

Reads a file from a backend supported by binary-structures.

This is, by default, one of:
- PATHNAME
- BINARY-STREAM
- OCTET-VECTOR
- FOREIGN-POINTER

See FILE (type)

Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-file (value storage &rest args)

Writes the file to a backend supported by binary-structures.

This is, by default, one of:
- PATHNAME
- BINARY-STREAM
- OCTET-VECTOR
- FOREIGN-POINTER

See FILE (type)

Package

org.shirakumo.ktx.

Source

ktx.lisp.


5.1.2 Generic functions

Generic Function: array-element-count (entry)

Accesses the number of texture array elements in the data.

As per spec:
numberOfArrayElements specifies the number of array elements. If the texture is not an array texture, numberOfArrayElements must equal 0.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: array-element-count ((entry file))
Source

ktx.lisp.

Generic Function: (setf array-element-count) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf array-element-count) ((entry file))
Source

ktx.lisp.

Generic Function: data (entry)

Accesses the mipmap level’s pixel data.

As per spec:
The data is stored as follows within the opaque array:

for each array_element in max(1, arrayElementCount)
for each face in max(1, faceCount)
for each z_slice in max(1, depth)
for each row or row_of_blocks in max(1, height)
for each pixel or block_of_pixels in width
Byte data[format-specific-number-of-bytes] end
end
end
Byte cubePadding[0-3]
end
end

For non-array cubemap textures (any texture where numberOfFaces is 6 and numberOfArrayElements is 0) cubePadding contains between 0 and 3 bytes of value 0x00 to ensure that the data in each face begins at a file offset that is a multiple of 4. In all other cases cubePadding is empty (0 bytes long). This is empty in the non-array cubemap case as well. The requirement of GL_UNPACK_ALIGNMENT = 4 means the size of uncompressed textures will always be a multiple of 4 bytes. All known compressed formats, that are usable for cubemaps, have block sizes that are a multiple of 4 bytes. The field is still shown in case a compressed format emerges with a block size that is not a multiple of 4 bytes.

See MIPMAP-LEVEL (type)

Package

org.shirakumo.ktx.

Methods
Method: data ((entry mipmap-level))
Source

ktx.lisp.

Generic Function: (setf data) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf data) ((entry mipmap-level))
Source

ktx.lisp.

Generic Function: depth (entry)

Accesses the depth of the pixel data.

As per spec:
The size of the texture image for level 0, in pixels. No rounding to block sizes should be applied for block compressed textures.
For 1D textures pixelHeight and pixelDepth must be 0. For 2D and cube textures pixelDepth must be 0.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: depth ((entry file))
Source

ktx.lisp.

Generic Function: (setf depth) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf depth) ((entry file))
Source

ktx.lisp.

Generic Function: endianness (entry)

Accesses the endianness type of the file.

Must be either :LITTLE-ENDIAN or :BIG-ENDIAN

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: endianness ((entry file))
Source

ktx.lisp.

Generic Function: (setf endianness) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf endianness) ((entry file))
Source

ktx.lisp.

Generic Function: face-count (entry)

Accesses the number of cubemap faces in the data.

As per spec:
numberOfFaces specifies the number of cubemap faces. For cubemaps and cubemap arrays this should be 6. For non cubemaps this should be 1. Cube map faces are stored in the order: +X, -X, +Y, -Y, +Z, -Z. Due to GL_OES_compressed_paletted_texture [OESCPT] not defining the interaction between cubemaps and its GL_PALETTE* formats, if ‘glInternalFormat‘ is one of its GL_PALETTE* format, numberOfFaces must be 1.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: face-count ((entry file))
Source

ktx.lisp.

Generic Function: (setf face-count) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf face-count) ((entry file))
Source

ktx.lisp.

Generic Function: gl-base-internal-format (entry)

Accesses the basic GL Internal Texture Format the data should be uploaded as.

As per spec:
For both compressed and uncompressed textures, glBaseInternalFormat specifies the base internal format of the texture, usually one of the values from table 8.11 of the OpenGL 4.4 specification [OPENGL44]
(RGB, RGBA, ALPHA, etc.). For uncompressed textures, this value will
be the same as glFormat and is used as the internalformat parameter
when loading into a context that does not support sized formats, such
as an unextended OpenGL ES 2.0 context.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: gl-base-internal-format ((entry file))
Source

ktx.lisp.

Generic Function: (setf gl-base-internal-format) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf gl-base-internal-format) ((entry file))
Source

ktx.lisp.

Generic Function: gl-format (entry)

Accesses the GL Pixel Format the data is stored as.

As per spec:
For compressed textures, glFormat must equal 0. For uncompressed textures, glFormat specifies the format parameter passed to glTex{,Sub}Image*D, usually one of the values from table 8.3 of the OpenGL 4.4 specification [OPENGL44] (RGB, RGBA, BGRA, etc.)

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: gl-format ((entry file))
Source

ktx.lisp.

Generic Function: (setf gl-format) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf gl-format) ((entry file))
Source

ktx.lisp.

Generic Function: gl-internal-format (entry)

Accesses the GL Internal Texture Format the data should be uploaded as.

As per spec:
For compressed textures, glInternalFormat must equal the compressed internal format, usually one of the values from table 8.14 of the OpenGL 4.4 specification [OPENGL44]. For uncompressed textures, glInternalFormat specifies the internalformat parameter passed to glTexStorage*D or glTexImage*D, usually one of the sized internal formats from tables 8.12 & 8.13 of the OpenGL 4.4 specification [OPENGL44]. The sized format should be chosen to match the bit depth of the data provided. glInternalFormat is used when loading both compressed and uncompressed textures, except when loading into a context that does not support sized formats, such as an unextended OpenGL ES 2.0 context where the internalformat parameter is required to have the same value as the format parameter.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: gl-internal-format ((entry file))
Source

ktx.lisp.

Generic Function: (setf gl-internal-format) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf gl-internal-format) ((entry file))
Source

ktx.lisp.

Generic Function: gl-type (entry)

Accesses the GL Pixel Type the data is stored as.

As per spec:
For compressed textures, glType must equal 0. For uncompressed textures, glType specifies the type parameter passed to glTex{,Sub}Image*D, usually one of the values from table 8.2 of the OpenGL 4.4 specification [OPENGL44] (UNSIGNED_BYTE, UNSIGNED_SHORT_5_6_5, etc.)

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: gl-type ((entry file))
Source

ktx.lisp.

Generic Function: (setf gl-type) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf gl-type) ((entry file))
Source

ktx.lisp.

Generic Function: gl-type-size (entry)

Accesses the size of the GL Pixel Type in octets.

As per spec:
glTypeSize specifies the data type size that should be used when endianness conversion is required for the texture data stored in the file. If glType is not 0, this should be the size in bytes corresponding to glType. For texture data which does not depend on platform endianness, including compressed texture data, glTypeSize must equal 1.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: gl-type-size ((entry file))
Source

ktx.lisp.

Generic Function: (setf gl-type-size) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf gl-type-size) ((entry file))
Source

ktx.lisp.

Generic Function: height (entry)

Accesses the height of the pixel data.

As per spec:
The size of the texture image for level 0, in pixels. No rounding to block sizes should be applied for block compressed textures.
For 1D textures pixelHeight and pixelDepth must be 0. For 2D and cube textures pixelDepth must be 0.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: height ((entry file))
Source

ktx.lisp.

Generic Function: (setf height) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf height) ((entry file))
Source

ktx.lisp.

Generic Function: kv-store (file)

Accesses the key-value store of the file.

Always returns a fresh hash-table.

Setting this will not preserve referential transparency. You may set it as either an ALIST or a HASH-TABLE.

As per spec:
Keys that begin with the 3 ascii characters ’KTX’ or ’ktx’ are reserved and must not be used except as described by this spec (this version of the KTX spec defines a single key, see FILE).

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: kv-store ((file file))
Source

ktx.lisp.

Generic Function: (setf kv-store) (file)
Package

org.shirakumo.ktx.

Methods
Method: (setf kv-store) ((file file))
Source

ktx.lisp.

Method: (setf kv-store) ((file file))
Source

ktx.lisp.

Generic Function: mip-count (entry)

Accesses the number of mipmap levels in the data.

As per spec:
numberOfMipmapLevels must equal 1 for non-mipmapped textures. For mipmapped textures, it equals the number of mipmaps. Mipmaps are stored in order from largest size to smallest size. The first mipmap level is always level 0. A KTX file does not need to contain a complete mipmap pyramid. If numberOfMipmapLevels equals 0, it indicates that a full mipmap pyramid should be generated from level 0 at load time (this is usually not allowed for compressed formats).

For the GL_PALETTE* formats, this equals the number of mipmaps and is passed as the levels, parameter when uploading to OpenGL
{,ES}. However all levels are packed into a single block of data along with the palette so numberOfMipmapLevels is considered to be 1 in the for loop over the data. Individual mipmaps are not identifiable.

See FILE (type)
See MIPMAPS

Package

org.shirakumo.ktx.

Methods
Method: mip-count ((entry file))
Source

ktx.lisp.

Generic Function: (setf mip-count) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf mip-count) ((entry file))
Source

ktx.lisp.

Generic Function: mipmaps (entry)

Accesses the vector of mipmap storage levels.

Even the base level is stored as a mipmap-level.

See FILE (type)
See MIPMAP-LEVEL (type)

Package

org.shirakumo.ktx.

Methods
Method: mipmaps ((entry file))
Source

ktx.lisp.

Generic Function: (setf mipmaps) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf mipmaps) ((entry file))
Source

ktx.lisp.

Generic Function: size (entry)

Accesses the size of the mipmap’s data vector in octets.

As per spec:
For most textures imageSize is the number of bytes of pixel data in the current LOD level. This includes all array layers, all z slices, all faces, all rows (or rows of blocks) and all pixels (or blocks) in each row for the mipmap level. It does not include any bytes in mipPadding.

The exception is non-array cubemap textures (any texture where numberOfFaces is 6 and numberOfArrayElements is 0). For these textures imageSize is the number of bytes in each face of the texture for the current LOD level, not including bytes in cubePadding or mipPadding.

See MIPMAP-LEVEL (type)

Package

org.shirakumo.ktx.

Methods
Method: size ((entry mipmap-level))
Source

ktx.lisp.

Generic Function: (setf size) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf size) ((entry mipmap-level))
Source

ktx.lisp.

Generic Function: width (entry)

Accesses the width of the pixel data.

As per spec:
The size of the texture image for level 0, in pixels. No rounding to block sizes should be applied for block compressed textures.
For 1D textures pixelHeight and pixelDepth must be 0. For 2D and cube textures pixelDepth must be 0.

See FILE (type)

Package

org.shirakumo.ktx.

Methods
Method: width ((entry file))
Source

ktx.lisp.

Generic Function: (setf width) (entry)
Package

org.shirakumo.ktx.

Methods
Method: (setf width) ((entry file))
Source

ktx.lisp.


5.1.3 Standalone methods

Method: octet-size ((value mipmap-level))
Package

org.shirakumo.binary-structures.

Source

ktx.lisp.

Method: octet-size ((value file))
Package

org.shirakumo.binary-structures.

Source

ktx.lisp.

Method: octet-size ((value kv-entry))
Package

org.shirakumo.binary-structures.

Source

ktx.lisp.

Method: print-object ((level mipmap-level) stream)
Source

ktx.lisp.

Method: print-object ((file file) stream)
Source

ktx.lisp.

Method: print-object ((entry kv-entry) stream)
Source

ktx.lisp.


5.1.4 Structures

Structure: file

Representation of a KTX file.

As per spec:
KTX™ is a format for storing textures for OpenGL® and OpenGL® ES applications. It is distinguished by the simplicity of the loader required to instantiate a GL texture object from the file contents.

The unpack alignment is 4. I.e. uncompressed pixel data is packed according to the rules described in section 8.4.4.1 of the OpenGL 4.4 specification [OPENGL44] for a GL_UNPACK_ALIGNMENT of 4.

Values listed in tables referred to in the OpenGL 4.4 specification [OPENGL44] may be supplemented by extensions. The references are given as examples and do not imply that all of those texture types can be loaded in OpenGL ES or earlier versions of OpenGL.

Texture data in a KTX file are arranged so that the first pixel in the data stream for each face and/or array element is closest to the origin of the texture coordinate system. In OpenGL that origin is conventionally described as being at the lower left, but this convention is not shared by all image file formats and content creation tools, so there is abundant room for confusion.

The desired texture axis orientation is often predetermined by, e.g. a content creation tool’s or existing application’s use of the
image. Therefore it is strongly recommended that tools for generating KTX files clearly describe their behaviour, and provide an option to specify the texture axis origin and orientation relative to the logical orientation of the source image. At minimum they should provide a choice between top-left and bottom-left as origin for 2D source images, with the positive S axis pointing right. Where possible, the preferred default is to use the logical upper-left corner of the image as the texture origin. Note that this is contrary to the standard interpretation of GL texture coordinates. However, the majority of texture compression tools use this convention.

As an aid to writing image manipulation tools and viewers, the logical orientation of the data in a KTX file may be indicated in the file’s key/value metadata. Note that this metadata affects only the logical interpretation of the data, has no effect on the mapping from pixels in the file byte stream to texture coordinates. The recommended key to use is:

KTXorientation
It is recommended that viewing and editing tools support at least the following values:

S=r,T=d
S=r,T=u
S=r,T=d,R=i
S=r,T=u,R=o

where

S indicates the direction of increasing S values
T indicates the direction of increasing T values
R indicates the direction of increasing R values
r indicates increasing to the right
l indicates increasing to the left
d indicates increasing downwards
u indicates increasing upwards
o indicates increasing out from the screen (moving towards viewer) i indicates increasing in towards the screen (moving away from viewer)

Although other orientations can be represented, it is recommended that tools that create KTX files use only the values listed above as other values may not be widely supported by other tools.

See READ-FILE
See WRITE-FILE
See ENDIANNESS
See GL-TYPE
See GL-TYPE-SIZE
See GL-FORMAT
See GL-INTERNAL-FORMAT
See GL-BASE-INTERNAL-FORMAT
See WIDTH
See HEIGHT
See DEPTH
See ARRAY-ELEMENT-COUNT
See FACE-COUNT
See MIP-COUNT
See MIPMAPS
See KV-STORE
See CREATE-FILE

Package

org.shirakumo.ktx.

Source

ktx.lisp.

Direct superclasses

io-structure-object.

Direct methods
Direct slots
Slot: endianness
Readers

file-endianness.

Writers

(setf file-endianness).

Slot: gl-type
Type

(unsigned-byte 32)

Initform

0

Readers

file-gl-type.

Writers

(setf file-gl-type).

Slot: gl-type-size
Type

(unsigned-byte 32)

Initform

0

Readers

file-gl-type-size.

Writers

(setf file-gl-type-size).

Slot: gl-format
Type

(unsigned-byte 32)

Initform

0

Readers

file-gl-format.

Writers

(setf file-gl-format).

Slot: gl-internal-format
Type

(unsigned-byte 32)

Initform

0

Readers

file-gl-internal-format.

Writers

(setf file-gl-internal-format).

Slot: gl-base-internal-format
Type

(unsigned-byte 32)

Initform

0

Readers

file-gl-base-internal-format.

Writers

(setf file-gl-base-internal-format).

Slot: width
Type

(unsigned-byte 32)

Initform

0

Readers

file-width.

Writers

(setf file-width).

Slot: height
Type

(unsigned-byte 32)

Initform

0

Readers

file-height.

Writers

(setf file-height).

Slot: depth
Type

(unsigned-byte 32)

Initform

0

Readers

file-depth.

Writers

(setf file-depth).

Slot: array-element-count
Type

(unsigned-byte 32)

Initform

0

Readers

file-array-element-count.

Writers

(setf file-array-element-count).

Slot: face-count
Type

(unsigned-byte 32)

Initform

0

Readers

file-face-count.

Writers

(setf file-face-count).

Slot: mip-count
Type

(unsigned-byte 32)

Initform

0

Readers

file-mip-count.

Writers

(setf file-mip-count).

Slot: kv-store-size
Type

(unsigned-byte 32)

Initform

0

Readers

file-kv-store-size.

Writers

(setf file-kv-store-size).

Slot: kv-store
Type

(array (unsigned-byte 8) (*))

Initform

(make-array 0 :element-type (quote (unsigned-byte 8)))

Readers

file-kv-store.

Writers

(setf file-kv-store).

Slot: mipmaps
Type

(array org.shirakumo.ktx:mipmap-level (*))

Initform

(make-array 0 :element-type (quote org.shirakumo.ktx:mipmap-level))

Readers

file-mipmaps.

Writers

(setf file-mipmaps).

Structure: mipmap-level

Representation of a mipmap level’s graphical data.

See SIZE
See DATA

Package

org.shirakumo.ktx.

Source

ktx.lisp.

Direct superclasses

io-structure-object.

Direct methods
Direct slots
Slot: size
Type

(unsigned-byte 32)

Initform

0

Readers

mipmap-level-size.

Writers

(setf mipmap-level-size).

Slot: data
Type

(array (unsigned-byte 8) (*))

Initform

(make-array 0 :element-type (quote (unsigned-byte 8)))

Readers

mipmap-level-data.

Writers

(setf mipmap-level-data).


5.2 Internals


5.2.1 Macros

Macro: define-accessors (type &rest names)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Macro: define-gl-accessors (type &rest names)
Package

org.shirakumo.ktx.

Source

ktx.lisp.


5.2.2 Ordinary functions

Function: copy-file (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: copy-kv-entry (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: copy-mipmap-level (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Reader: file-array-element-count (instance)
Writer: (setf file-array-element-count) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

array-element-count.

Reader: file-depth (instance)
Writer: (setf file-depth) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

depth.

Reader: file-endianness (instance)
Writer: (setf file-endianness) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

endianness.

Reader: file-face-count (instance)
Writer: (setf file-face-count) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

face-count.

Reader: file-gl-base-internal-format (instance)
Writer: (setf file-gl-base-internal-format) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

gl-base-internal-format.

Reader: file-gl-format (instance)
Writer: (setf file-gl-format) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

gl-format.

Reader: file-gl-internal-format (instance)
Writer: (setf file-gl-internal-format) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

gl-internal-format.

Reader: file-gl-type (instance)
Writer: (setf file-gl-type) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

gl-type.

Reader: file-gl-type-size (instance)
Writer: (setf file-gl-type-size) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

gl-type-size.

Reader: file-height (instance)
Writer: (setf file-height) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

height.

Reader: file-kv-store (instance)
Writer: (setf file-kv-store) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

kv-store.

Reader: file-kv-store-size (instance)
Writer: (setf file-kv-store-size) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

kv-store-size.

Reader: file-mip-count (instance)
Writer: (setf file-mip-count) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

mip-count.

Reader: file-mipmaps (instance)
Writer: (setf file-mipmaps) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

mipmaps.

Function: file-p (object)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Reader: file-width (instance)
Writer: (setf file-width) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

width.

Function: infer-internal-format (pixel-type pixel-format)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Reader: kv-entry-kv-string (instance)
Writer: (setf kv-entry-kv-string) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

kv-string.

Function: kv-entry-p (object)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Reader: kv-entry-size (instance)
Writer: (setf kv-entry-size) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

size.

Function: make-file (&key endianness gl-type gl-type-size gl-format gl-internal-format gl-base-internal-format width height depth array-element-count face-count mip-count kv-store-size kv-store mipmaps)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: make-kv-entry (&key size kv-string)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Reader: mipmap-level-data (instance)
Writer: (setf mipmap-level-data) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

data.

Function: mipmap-level-p (object)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Reader: mipmap-level-size (instance)
Writer: (setf mipmap-level-size) (instance)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Target Slot

size.

Function: pixel-data-stride (pixel-type pixel-format)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-foreign-pointer-file (pointer size)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-foreign-pointer-kv-entry (pointer size)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-foreign-pointer-mipmap-level (pointer size)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-octet-vector-file (vector start end)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-octet-vector-kv-entry (vector start end)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-octet-vector-mipmap-level (vector start end)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-stream-file (stream)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-stream-kv-entry (stream)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-io-stream-mipmap-level (stream)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-kv-entry (storage &rest args)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: read-mipmap-level (storage &rest args)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-foreign-pointer-file (value pointer size)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-foreign-pointer-kv-entry (value pointer size)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-foreign-pointer-mipmap-level (value pointer size)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-octet-vector-file (value vector start end)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-octet-vector-kv-entry (value vector start end)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-octet-vector-mipmap-level (value vector start end)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-stream-file (value stream)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-stream-kv-entry (value stream)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-io-stream-mipmap-level (value stream)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-kv-entry (value storage &rest args)
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Function: write-mipmap-level (value storage &rest args)
Package

org.shirakumo.ktx.

Source

ktx.lisp.


5.2.3 Structures

Structure: kv-entry
Package

org.shirakumo.ktx.

Source

ktx.lisp.

Direct superclasses

io-structure-object.

Direct methods
Direct slots
Slot: size
Type

(unsigned-byte 32)

Initform

0

Readers

kv-entry-size.

Writers

(setf kv-entry-size).

Slot: kv-string
Type

string

Initform

""

Readers

kv-entry-kv-string.

Writers

(setf kv-entry-kv-string).


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   (  
A   C   D   E   F   G   H   I   K   M   O   P   R   S   W  
Index Entry  Section

(
(setf array-element-count): Public generic functions
(setf array-element-count): Public generic functions
(setf data): Public generic functions
(setf data): Public generic functions
(setf depth): Public generic functions
(setf depth): Public generic functions
(setf endianness): Public generic functions
(setf endianness): Public generic functions
(setf face-count): Public generic functions
(setf face-count): Public generic functions
(setf file-array-element-count): Private ordinary functions
(setf file-depth): Private ordinary functions
(setf file-endianness): Private ordinary functions
(setf file-face-count): Private ordinary functions
(setf file-gl-base-internal-format): Private ordinary functions
(setf file-gl-format): Private ordinary functions
(setf file-gl-internal-format): Private ordinary functions
(setf file-gl-type): Private ordinary functions
(setf file-gl-type-size): Private ordinary functions
(setf file-height): Private ordinary functions
(setf file-kv-store): Private ordinary functions
(setf file-kv-store-size): Private ordinary functions
(setf file-mip-count): Private ordinary functions
(setf file-mipmaps): Private ordinary functions
(setf file-width): Private ordinary functions
(setf gl-base-internal-format): Public generic functions
(setf gl-base-internal-format): Public generic functions
(setf gl-format): Public generic functions
(setf gl-format): Public generic functions
(setf gl-internal-format): Public generic functions
(setf gl-internal-format): Public generic functions
(setf gl-type): Public generic functions
(setf gl-type): Public generic functions
(setf gl-type-size): Public generic functions
(setf gl-type-size): Public generic functions
(setf height): Public generic functions
(setf height): Public generic functions
(setf kv-entry-kv-string): Private ordinary functions
(setf kv-entry-size): Private ordinary functions
(setf kv-store): Public generic functions
(setf kv-store): Public generic functions
(setf kv-store): Public generic functions
(setf mip-count): Public generic functions
(setf mip-count): Public generic functions
(setf mipmap-level-data): Private ordinary functions
(setf mipmap-level-size): Private ordinary functions
(setf mipmaps): Public generic functions
(setf mipmaps): Public generic functions
(setf size): Public generic functions
(setf size): Public generic functions
(setf width): Public generic functions
(setf width): Public generic functions

A
array-element-count: Public generic functions
array-element-count: Public generic functions

C
copy-file: Private ordinary functions
copy-kv-entry: Private ordinary functions
copy-mipmap-level: Private ordinary functions
create-file: Public ordinary functions

D
data: Public generic functions
data: Public generic functions
define-accessors: Private macros
define-gl-accessors: Private macros
depth: Public generic functions
depth: Public generic functions

E
endianness: Public generic functions
endianness: Public generic functions

F
face-count: Public generic functions
face-count: Public generic functions
file-array-element-count: Private ordinary functions
file-depth: Private ordinary functions
file-endianness: Private ordinary functions
file-face-count: Private ordinary functions
file-gl-base-internal-format: Private ordinary functions
file-gl-format: Private ordinary functions
file-gl-internal-format: Private ordinary functions
file-gl-type: Private ordinary functions
file-gl-type-size: Private ordinary functions
file-height: Private ordinary functions
file-kv-store: Private ordinary functions
file-kv-store-size: Private ordinary functions
file-mip-count: Private ordinary functions
file-mipmaps: Private ordinary functions
file-p: Private ordinary functions
file-width: Private ordinary functions
Function, (setf file-array-element-count): Private ordinary functions
Function, (setf file-depth): Private ordinary functions
Function, (setf file-endianness): Private ordinary functions
Function, (setf file-face-count): Private ordinary functions
Function, (setf file-gl-base-internal-format): Private ordinary functions
Function, (setf file-gl-format): Private ordinary functions
Function, (setf file-gl-internal-format): Private ordinary functions
Function, (setf file-gl-type): Private ordinary functions
Function, (setf file-gl-type-size): Private ordinary functions
Function, (setf file-height): Private ordinary functions
Function, (setf file-kv-store): Private ordinary functions
Function, (setf file-kv-store-size): Private ordinary functions
Function, (setf file-mip-count): Private ordinary functions
Function, (setf file-mipmaps): Private ordinary functions
Function, (setf file-width): Private ordinary functions
Function, (setf kv-entry-kv-string): Private ordinary functions
Function, (setf kv-entry-size): Private ordinary functions
Function, (setf mipmap-level-data): Private ordinary functions
Function, (setf mipmap-level-size): Private ordinary functions
Function, copy-file: Private ordinary functions
Function, copy-kv-entry: Private ordinary functions
Function, copy-mipmap-level: Private ordinary functions
Function, create-file: Public ordinary functions
Function, file-array-element-count: Private ordinary functions
Function, file-depth: Private ordinary functions
Function, file-endianness: Private ordinary functions
Function, file-face-count: Private ordinary functions
Function, file-gl-base-internal-format: Private ordinary functions
Function, file-gl-format: Private ordinary functions
Function, file-gl-internal-format: Private ordinary functions
Function, file-gl-type: Private ordinary functions
Function, file-gl-type-size: Private ordinary functions
Function, file-height: Private ordinary functions
Function, file-kv-store: Private ordinary functions
Function, file-kv-store-size: Private ordinary functions
Function, file-mip-count: Private ordinary functions
Function, file-mipmaps: Private ordinary functions
Function, file-p: Private ordinary functions
Function, file-width: Private ordinary functions
Function, infer-internal-format: Private ordinary functions
Function, kv-entry-kv-string: Private ordinary functions
Function, kv-entry-p: Private ordinary functions
Function, kv-entry-size: Private ordinary functions
Function, make-file: Private ordinary functions
Function, make-kv-entry: Private ordinary functions
Function, make-mipmap-level: Public ordinary functions
Function, mipmap-level-data: Private ordinary functions
Function, mipmap-level-p: Private ordinary functions
Function, mipmap-level-size: Private ordinary functions
Function, pixel-data-stride: Private ordinary functions
Function, read-file: Public ordinary functions
Function, read-io-foreign-pointer-file: Private ordinary functions
Function, read-io-foreign-pointer-kv-entry: Private ordinary functions
Function, read-io-foreign-pointer-mipmap-level: Private ordinary functions
Function, read-io-octet-vector-file: Private ordinary functions
Function, read-io-octet-vector-kv-entry: Private ordinary functions
Function, read-io-octet-vector-mipmap-level: Private ordinary functions
Function, read-io-stream-file: Private ordinary functions
Function, read-io-stream-kv-entry: Private ordinary functions
Function, read-io-stream-mipmap-level: Private ordinary functions
Function, read-kv-entry: Private ordinary functions
Function, read-mipmap-level: Private ordinary functions
Function, write-file: Public ordinary functions
Function, write-io-foreign-pointer-file: Private ordinary functions
Function, write-io-foreign-pointer-kv-entry: Private ordinary functions
Function, write-io-foreign-pointer-mipmap-level: Private ordinary functions
Function, write-io-octet-vector-file: Private ordinary functions
Function, write-io-octet-vector-kv-entry: Private ordinary functions
Function, write-io-octet-vector-mipmap-level: Private ordinary functions
Function, write-io-stream-file: Private ordinary functions
Function, write-io-stream-kv-entry: Private ordinary functions
Function, write-io-stream-mipmap-level: Private ordinary functions
Function, write-kv-entry: Private ordinary functions
Function, write-mipmap-level: Private ordinary functions

G
Generic Function, (setf array-element-count): Public generic functions
Generic Function, (setf data): Public generic functions
Generic Function, (setf depth): Public generic functions
Generic Function, (setf endianness): Public generic functions
Generic Function, (setf face-count): Public generic functions
Generic Function, (setf gl-base-internal-format): Public generic functions
Generic Function, (setf gl-format): Public generic functions
Generic Function, (setf gl-internal-format): Public generic functions
Generic Function, (setf gl-type): Public generic functions
Generic Function, (setf gl-type-size): Public generic functions
Generic Function, (setf height): Public generic functions
Generic Function, (setf kv-store): Public generic functions
Generic Function, (setf mip-count): Public generic functions
Generic Function, (setf mipmaps): Public generic functions
Generic Function, (setf size): Public generic functions
Generic Function, (setf width): Public generic functions
Generic Function, array-element-count: Public generic functions
Generic Function, data: Public generic functions
Generic Function, depth: Public generic functions
Generic Function, endianness: Public generic functions
Generic Function, face-count: Public generic functions
Generic Function, gl-base-internal-format: Public generic functions
Generic Function, gl-format: Public generic functions
Generic Function, gl-internal-format: Public generic functions
Generic Function, gl-type: Public generic functions
Generic Function, gl-type-size: Public generic functions
Generic Function, height: Public generic functions
Generic Function, kv-store: Public generic functions
Generic Function, mip-count: Public generic functions
Generic Function, mipmaps: Public generic functions
Generic Function, size: Public generic functions
Generic Function, width: Public generic functions
gl-base-internal-format: Public generic functions
gl-base-internal-format: Public generic functions
gl-format: Public generic functions
gl-format: Public generic functions
gl-internal-format: Public generic functions
gl-internal-format: Public generic functions
gl-type: Public generic functions
gl-type: Public generic functions
gl-type-size: Public generic functions
gl-type-size: Public generic functions

H
height: Public generic functions
height: Public generic functions

I
infer-internal-format: Private ordinary functions

K
kv-entry-kv-string: Private ordinary functions
kv-entry-p: Private ordinary functions
kv-entry-size: Private ordinary functions
kv-store: Public generic functions
kv-store: Public generic functions

M
Macro, define-accessors: Private macros
Macro, define-gl-accessors: Private macros
make-file: Private ordinary functions
make-kv-entry: Private ordinary functions
make-mipmap-level: Public ordinary functions
Method, (setf array-element-count): Public generic functions
Method, (setf data): Public generic functions
Method, (setf depth): Public generic functions
Method, (setf endianness): Public generic functions
Method, (setf face-count): Public generic functions
Method, (setf gl-base-internal-format): Public generic functions
Method, (setf gl-format): Public generic functions
Method, (setf gl-internal-format): Public generic functions
Method, (setf gl-type): Public generic functions
Method, (setf gl-type-size): Public generic functions
Method, (setf height): Public generic functions
Method, (setf kv-store): Public generic functions
Method, (setf kv-store): Public generic functions
Method, (setf mip-count): Public generic functions
Method, (setf mipmaps): Public generic functions
Method, (setf size): Public generic functions
Method, (setf width): Public generic functions
Method, array-element-count: Public generic functions
Method, data: Public generic functions
Method, depth: Public generic functions
Method, endianness: Public generic functions
Method, face-count: Public generic functions
Method, gl-base-internal-format: Public generic functions
Method, gl-format: Public generic functions
Method, gl-internal-format: Public generic functions
Method, gl-type: Public generic functions
Method, gl-type-size: Public generic functions
Method, height: Public generic functions
Method, kv-store: Public generic functions
Method, mip-count: Public generic functions
Method, mipmaps: Public generic functions
Method, octet-size: Public standalone methods
Method, octet-size: Public standalone methods
Method, octet-size: Public standalone methods
Method, print-object: Public standalone methods
Method, print-object: Public standalone methods
Method, print-object: Public standalone methods
Method, size: Public generic functions
Method, width: Public generic functions
mip-count: Public generic functions
mip-count: Public generic functions
mipmap-level-data: Private ordinary functions
mipmap-level-p: Private ordinary functions
mipmap-level-size: Private ordinary functions
mipmaps: Public generic functions
mipmaps: Public generic functions

O
octet-size: Public standalone methods
octet-size: Public standalone methods
octet-size: Public standalone methods

P
pixel-data-stride: Private ordinary functions
print-object: Public standalone methods
print-object: Public standalone methods
print-object: Public standalone methods

R
read-file: Public ordinary functions
read-io-foreign-pointer-file: Private ordinary functions
read-io-foreign-pointer-kv-entry: Private ordinary functions
read-io-foreign-pointer-mipmap-level: Private ordinary functions
read-io-octet-vector-file: Private ordinary functions
read-io-octet-vector-kv-entry: Private ordinary functions
read-io-octet-vector-mipmap-level: Private ordinary functions
read-io-stream-file: Private ordinary functions
read-io-stream-kv-entry: Private ordinary functions
read-io-stream-mipmap-level: Private ordinary functions
read-kv-entry: Private ordinary functions
read-mipmap-level: Private ordinary functions

S
size: Public generic functions
size: Public generic functions

W
width: Public generic functions
width: Public generic functions
write-file: Public ordinary functions
write-io-foreign-pointer-file: Private ordinary functions
write-io-foreign-pointer-kv-entry: Private ordinary functions
write-io-foreign-pointer-mipmap-level: Private ordinary functions
write-io-octet-vector-file: Private ordinary functions
write-io-octet-vector-kv-entry: Private ordinary functions
write-io-octet-vector-mipmap-level: Private ordinary functions
write-io-stream-file: Private ordinary functions
write-io-stream-kv-entry: Private ordinary functions
write-io-stream-mipmap-level: Private ordinary functions
write-kv-entry: Private ordinary functions
write-mipmap-level: Private ordinary functions


A.3 Variables