⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 texture.h

📁 Lido PXA270平台开发板的最新BSP,包括源代码
💻 H
字号:
/******************************************************************************
<module>
* Name         : Texture.h
* Title        : D3DM Texture functions
* Author(s)    : Imagination Technologies
* Created      : 2 March 2004
*
* Copyright    : 2004 by Imagination Technologies Limited.
*                All rights reserved.  No part of this software, either
*                material or conceptual may be copied or distributed,
*                transmitted, transcribed, stored in a retrieval system
*                or translated into any human or computer language in any
*                form by any means, electronic, mechanical, manual or
*                other-wise, or disclosed to third parties without the
*                express written permission of Imagination Technologies
*                Limited, Unit 8, HomePark Industrial Estate,
*                King's Langley, Hertfordshire, WD4 8LZ, U.K.
*
* Description  : Handles setup and creation of D3DM texures
*
* Platform     : Windows CE
*
</module>

$Log: texture.h $
********************************************************************************/
#if !defined(_TEXTURE_H_)
#define _TEXTURE_H_

/*****************************************************************************
 Texture map surface related flags
*****************************************************************************/

#define MAPDETAILSFLAGS_USEDINSTAGE0		0x00000001
#define MAPDETAILSFLAGS_USEDINSTAGE1		0x00000002
#define MAPDETAILSFLAGS_USEDINANYSTAGE		0x00000003

#define MAPDETAILSFLAGS_CANNOT_BE_STRIDE	0x00000004
#define MAPDETAILSFLAGS_OPAQUE				0x00000008


/***************************************************************************
 Texture Map information (shared by all mipmap-levels)
****************************************************************************/
typedef struct _MAP_DETAILS_
{
	/* General texture flags */
	DWORD				dwFlags;

	/* Size (in bytes) allocated for this texture */
	DWORD				dwAllocSize;

	/* Number of levels in this map */
	DWORD				dwMipLevels;

	/* Number of levels in this map */
	DWORD				dwSuppliedLevels;

	/*
		Horizontal scale-factor used to enlarge textures that are narrower
		than the minimum HW texture width
	*/
	DWORD				dwUScale;

	/*
		Vertical scale-factor used to enlarge textures that are shorter
		than the minimum HW texture height
	*/
	DWORD				dwVScale;

	/* Basic HW texture-related state, such as size, address and format */
	MBX1_TSPLAYER_STATE	sTSPCtl;
		
	/* rendering-context currently using this texture */
	LPD3DM_CONTEXT		psContext;

	/* Pointer to current top level surface */
	LPD3DM_SURFACE		psCurrentTopLevel;

} MAP_DETAILS, *PMAP_DETAILS;

/*****************************************************************************
 Function Prototypes
*****************************************************************************/
VOID CreateTexture(D3DM_CREATESURFACE_DATA *pcsd);
VOID DestroyTexture(D3DM_DESTROYSURFACE_DATA *pdsd);
BOOL GetSizeInfo(DWORD	dwSize,
				 DWORD	*pdwTSPSize,
				 DWORD	*pdwScale,
				 DWORD	*pdwMapLevels);

#endif /* #if !defined(_TEXTURE_H_) */
/*****************************************************************************
 End of file (Texture.h)
*****************************************************************************/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -