libsquish v1.15.1.2
S3TC/DXT compliant image compression
Loading...
Searching...
No Matches
squish.h File Reference

The sole public header file of the squish library. More...

#include "squish/squish_export.h"
Include dependency graph for squish.h:

Go to the source code of this file.

Namespaces

namespace  squish
 All squish API functions live in this namespace.
 

Typedefs

typedef unsigned char squish::u8
 Typedef a quantity that is a single unsigned byte.
 

Enumerations

enum  {
  squish::kDxt1 = ( 1 << 0 ) ,
  squish::kDxt3 = ( 1 << 1 ) ,
  squish::kDxt5 = ( 1 << 2 ) ,
  squish::kBc4 = ( 1 << 3 ) ,
  squish::kBc5 = ( 1 << 4 ) ,
  squish::kColourClusterFit = ( 1 << 5 ) ,
  squish::kColourRangeFit = ( 1 << 6 ) ,
  squish::kWeightColourByAlpha = ( 1 << 7 ) ,
  squish::kColourIterativeClusterFit = ( 1 << 8 ) ,
  squish::kSourceBGRA = ( 1 << 9 )
}
 

Functions

void squish::Compress (u8 const *rgba, void *block, int flags, float *metric=0)
 Compresses a 4x4 block of pixels.
 
void squish::CompressImage (u8 const *rgba, int width, int height, int pitch, void *blocks, int flags, float *metric=0)
 Compresses an image in memory.
 
void squish::CompressImage (u8 const *rgba, int width, int height, void *blocks, int flags, float *metric=0)
 
void squish::CompressMasked (u8 const *rgba, int mask, void *block, int flags, float *metric=0)
 Compresses a 4x4 block of pixels.
 
void squish::ComputeMSE (u8 const *rgba, int width, int height, int pitch, u8 const *dxt, int flags, double &colourMSE, double &alphaMSE)
 Computes MSE of an compressed image in memory.
 
void squish::ComputeMSE (u8 const *rgba, int width, int height, u8 const *dxt, int flags, double &colourMSE, double &alphaMSE)
 
void squish::Decompress (u8 *rgba, void const *block, int flags)
 Decompresses a 4x4 block of pixels.
 
void squish::DecompressImage (u8 *rgba, int width, int height, int pitch, void const *blocks, int flags)
 Decompresses an image in memory.
 
void squish::DecompressImage (u8 *rgba, int width, int height, void const *blocks, int flags)
 
int squish::GetStorageRequirements (int width, int height, int flags)
 Computes the amount of compressed storage required.
 

Detailed Description

"