Texture Compression

This walkthrough shows you some basics of the Creation Graph. In this part we discuss texture compression.

This tutorial will teach you:

  • How to compress a texture
  • What differentiates a creation graph from each other.

Note: walkthrough series makes use of the following free assets: KhronosGroup/glTF-Sample-Models.

Setup

Download the flight helmet asset from the git repo Download Now. After we have downloaded and extracted all parts of the dcc asset as described in Import and rigging tutorial or you follow this Guide Import assets. We can follow the rest of the tutorial.

How do we identify uncompressed images?

When we select a texture in the Asset Browser, lets select the leather of the helmet.

{image}

In the preview tab we can see that this texture is uncompressed indicated by the text line in the bottom of the preview.

{image}

How do we compress the texture?

We double click the selected texture and open its creation graph. This will open the instanced version of the core dcc_texturecreation graph. This creation graph looks as following:

{image}

Dissection

Let us dissect the graph step by step:

Input Node
DCC Asset Image
Image Settings

The Input node takes a dcc asset image this is a data container that contains the raw image data within the dcc asset. This raw data needs to be translated to a GPU image with the next node.

DCC Images
DCC Asset Image
GPU Image

After this translation we can make use of the Import Settings to filter the Image with the Filter Image. This node filters for example mipmap.

Filter Image
Settings
Image
GPU Image

The output is a modified GPU Image which we pass to the Image Output node.

How to Distinguish between creation graphs and creation graph.

The output nodes define the types of the creation graph. In this particular case the creation graph represents a texture now.

Add the compression node

We are using the crunch library for our image compression node. We can just press space and search for the "Compression Node" and add it to the graph. Since we are working in an Instance of the core graph we can modify this graph and the results will not change the prototype.

Compression Node
Image
GPU Image
Input Colour Space
Output Format
Release GPU Input

This node outputs an Image that is compressed and we can then connect this node to the Image Output node. Important to remember is that we need to remove the connection from the output node to the image filter node and remove the original connection.

{image}

If we now investigate the image in the asset browser we can see that the texture is compressed.

{image}