diff options
| author | Jørgen P. Tjernø <[email protected]> | 2013-12-02 19:31:46 -0800 |
|---|---|---|
| committer | Jørgen P. Tjernø <[email protected]> | 2013-12-02 19:46:31 -0800 |
| commit | f56bb35301836e56582a575a75864392a0177875 (patch) | |
| tree | de61ddd39de3e7df52759711950b4c288592f0dc /mp/src/public/nvtc.h | |
| parent | Mark some more files as text. (diff) | |
| download | source-sdk-2013-f56bb35301836e56582a575a75864392a0177875.tar.xz source-sdk-2013-f56bb35301836e56582a575a75864392a0177875.zip | |
Fix line endings. WHAMMY.
Diffstat (limited to 'mp/src/public/nvtc.h')
| -rw-r--r-- | mp/src/public/nvtc.h | 174 |
1 files changed, 87 insertions, 87 deletions
diff --git a/mp/src/public/nvtc.h b/mp/src/public/nvtc.h index 6a11d141..fd1c9806 100644 --- a/mp/src/public/nvtc.h +++ b/mp/src/public/nvtc.h @@ -1,87 +1,87 @@ -//========= Copyright Valve Corporation, All rights reserved. ============//
-/*
- * Copyright (c) 1997-8 S3 Inc. All Rights Reserved.
- *
- * Module Name: s3_intrf.h
- *
- * Purpose: Constant, structure, and prototype definitions for S3TC
- * interface to DX surface
- *
- * Author: Dan Hung, Martin Hoffesommer
- *
- * Revision History:
- * version Beta 1.00.00-98-03-26
- */
-
-// Highlevel interface
-
-#ifndef NVTC_H
-#define NVTC_H
-
-#if defined( _WIN32 ) && !defined( _X360 )
-#include <ddraw.h>
-#endif
-
-// RGB encoding types
-#define S3TC_ENCODE_RGB_FULL 0x0
-#define S3TC_ENCODE_RGB_COLOR_KEY 0x1
-#define S3TC_ENCODE_RGB_ALPHA_COMPARE 0x2
-#define _S3TC_ENCODE_RGB_MASK 0xff
-
-// alpha encoding types
-#define S3TC_ENCODE_ALPHA_NONE 0x000
-#define S3TC_ENCODE_ALPHA_EXPLICIT 0x100
-#define S3TC_ENCODE_ALPHA_INTERPOLATED 0x200
-#define _S3TC_ENCODE_ALPHA_MASK 0xff00
-
-
-#if defined( _WIN32 ) && !defined( _X360 )
-// common encoding types
-//@@@TBD
-
-// error codes
-#define ERROR_ABORTED -1
-
-// Progress Callback for S3TCencode
-typedef BOOL (* LP_S3TC_PROGRESS_CALLBACK)(float fProgress, LPVOID lpUser1, LPVOID lpUser2);
-
-// set alpha reference value for alpha compare encoding
-void S3TCsetAlphaReference(int nRef);
-
-// determine number of bytes needed to compress given source image
-unsigned int S3TCgetEncodeSize(DDSURFACEDESC *lpDesc, // [in]
- unsigned int dwEncodeType // [in]
- );
-
-// encode (compress) given source image to given destination surface
-void S3TCencode(DDSURFACEDESC *lpSrc, // [in]
- PALETTEENTRY *lpPal, // [in], may be NULL
- DDSURFACEDESC *lpDest, // [out]
- void *lpDestBuf, // [in]
- unsigned int dwEncodeType, // [in]
- float *weight // [in]
- );
-
-int S3TCencodeEx(DDSURFACEDESC *lpSrc, // [in]
- PALETTEENTRY *lpPal, // [in], may be NULL
- DDSURFACEDESC *lpDest, // [out]
- void *lpDestBuf, // [in]
- unsigned int dwEncodeType, // [in]
- float *weight, // [in]
- LP_S3TC_PROGRESS_CALLBACK lpS3TCProgressProc, // [in], may be NULL
- LPVOID lpArg1, // in
- LPVOID lpArg2 // in
- );
-
-// determine number of bytes needed do decompress given compressed image
-unsigned int S3TCgetDecodeSize(DDSURFACEDESC *lpDesc);
-
-// decode (decompress) to ARGB8888
-void S3TCdecode(DDSURFACEDESC *lpSrc, // [in]
- DDSURFACEDESC *lpDest, // [out]
- void *lpDestBuf // [in]
- );
-
-#endif // _WIN32
-
-#endif // NVTC_H
+//========= Copyright Valve Corporation, All rights reserved. ============// +/* + * Copyright (c) 1997-8 S3 Inc. All Rights Reserved. + * + * Module Name: s3_intrf.h + * + * Purpose: Constant, structure, and prototype definitions for S3TC + * interface to DX surface + * + * Author: Dan Hung, Martin Hoffesommer + * + * Revision History: + * version Beta 1.00.00-98-03-26 + */ + +// Highlevel interface + +#ifndef NVTC_H +#define NVTC_H + +#if defined( _WIN32 ) && !defined( _X360 ) +#include <ddraw.h> +#endif + +// RGB encoding types +#define S3TC_ENCODE_RGB_FULL 0x0 +#define S3TC_ENCODE_RGB_COLOR_KEY 0x1 +#define S3TC_ENCODE_RGB_ALPHA_COMPARE 0x2 +#define _S3TC_ENCODE_RGB_MASK 0xff + +// alpha encoding types +#define S3TC_ENCODE_ALPHA_NONE 0x000 +#define S3TC_ENCODE_ALPHA_EXPLICIT 0x100 +#define S3TC_ENCODE_ALPHA_INTERPOLATED 0x200 +#define _S3TC_ENCODE_ALPHA_MASK 0xff00 + + +#if defined( _WIN32 ) && !defined( _X360 ) +// common encoding types +//@@@TBD + +// error codes +#define ERROR_ABORTED -1 + +// Progress Callback for S3TCencode +typedef BOOL (* LP_S3TC_PROGRESS_CALLBACK)(float fProgress, LPVOID lpUser1, LPVOID lpUser2); + +// set alpha reference value for alpha compare encoding +void S3TCsetAlphaReference(int nRef); + +// determine number of bytes needed to compress given source image +unsigned int S3TCgetEncodeSize(DDSURFACEDESC *lpDesc, // [in] + unsigned int dwEncodeType // [in] + ); + +// encode (compress) given source image to given destination surface +void S3TCencode(DDSURFACEDESC *lpSrc, // [in] + PALETTEENTRY *lpPal, // [in], may be NULL + DDSURFACEDESC *lpDest, // [out] + void *lpDestBuf, // [in] + unsigned int dwEncodeType, // [in] + float *weight // [in] + ); + +int S3TCencodeEx(DDSURFACEDESC *lpSrc, // [in] + PALETTEENTRY *lpPal, // [in], may be NULL + DDSURFACEDESC *lpDest, // [out] + void *lpDestBuf, // [in] + unsigned int dwEncodeType, // [in] + float *weight, // [in] + LP_S3TC_PROGRESS_CALLBACK lpS3TCProgressProc, // [in], may be NULL + LPVOID lpArg1, // in + LPVOID lpArg2 // in + ); + +// determine number of bytes needed do decompress given compressed image +unsigned int S3TCgetDecodeSize(DDSURFACEDESC *lpDesc); + +// decode (decompress) to ARGB8888 +void S3TCdecode(DDSURFACEDESC *lpSrc, // [in] + DDSURFACEDESC *lpDest, // [out] + void *lpDestBuf // [in] + ); + +#endif // _WIN32 + +#endif // NVTC_H |