亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? opc_aabbtree.h

?? opcode是功能強大
?? H
字號:
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/*
 *	OPCODE - Optimized Collision Detection
 *	Copyright (C) 2001 Pierre Terdiman
 *	Homepage: http://www.codercorner.com/Opcode.htm
 */
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
 *	Contains code for a versatile AABB tree.
 *	\file		OPC_AABBTree.h
 *	\author		Pierre Terdiman
 *	\date		March, 20, 2001
 */
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Include Guard
#ifndef __OPC_AABBTREE_H__
#define __OPC_AABBTREE_H__

#ifdef OPC_NO_NEG_VANILLA_TREE
	//! TO BE DOCUMENTED
	#define IMPLEMENT_TREE(base_class, volume)																			\
		public:																											\
		/* Constructor / Destructor */																					\
									base_class();																		\
									~base_class();																		\
		/* Data access */																								\
		inline_	const volume*		Get##volume()	const	{ return &mBV;							}					\
		/* Clear the last bit */																						\
		inline_	const base_class*	GetPos()		const	{ return (const base_class*)(mPos&~1);	}					\
		inline_	const base_class*	GetNeg()		const	{ const base_class* P = GetPos(); return P ? P+1 : null;}	\
																														\
		/* We don't need to test both nodes since we can't have one without the other	*/								\
		inline_	bool				IsLeaf()		const	{ return !GetPos();						}					\
																														\
		/* Stats */																										\
		inline_	udword				GetNodeSize()	const	{ return sizeof(*this);					}					\
		protected:																										\
		/* Tree-independent data */																						\
		/* Following data always belong to the BV-tree, regardless of what the tree actually contains.*/				\
		/* Whatever happens we need the two children and the enclosing volume.*/										\
				volume				mBV;		/* Global bounding-volume enclosing all the node-related primitives */	\
				size_t				mPos;		/* "Positive" & "Negative" children */
#else
	//! TO BE DOCUMENTED
	#define IMPLEMENT_TREE(base_class, volume)																			\
		public:																											\
		/* Constructor / Destructor */																					\
									base_class();																		\
									~base_class();																		\
		/* Data access */																								\
		inline_	const volume*		Get##volume()	const	{ return &mBV;							}					\
		/* Clear the last bit */																						\
		inline_	const base_class*	GetPos()		const	{ return (const base_class*)(mPos&~1);	}					\
		inline_	const base_class*	GetNeg()		const	{ return (const base_class*)(mNeg&~1);	}					\
																														\
/*		inline_	bool				IsLeaf()		const	{ return (!GetPos() && !GetNeg());	}	*/					\
		/* We don't need to test both nodes since we can't have one without the other	*/								\
		inline_	bool				IsLeaf()		const	{ return !GetPos();						}					\
																														\
		/* Stats */																										\
		inline_	udword				GetNodeSize()	const	{ return sizeof(*this);					}					\
		protected:																										\
		/* Tree-independent data */																						\
		/* Following data always belong to the BV-tree, regardless of what the tree actually contains.*/				\
		/* Whatever happens we need the two children and the enclosing volume.*/										\
				volume				mBV;		/* Global bounding-volume enclosing all the node-related primitives */	\
				size_t				mPos;		/* "Positive" child */													\
				size_t				mNeg;		/* "Negative" child */
#endif

	typedef		void				(*CullingCallback)		(udword nb_primitives, udword* node_primitives, BOOL need_clipping, void* user_data);

	class AABBTreeNode
	{
//									IMPLEMENT_TREE(AABBTreeNode, IceMaths::AABB)
   public:
      /* Constructor / Destructor */
      AABBTreeNode();
      ~AABBTreeNode();
      /* Data access */
      inline_	const IceMaths::AABB*		GetAABB()	const	{ return &mBV;							}
      /* Clear the last bit */
      inline_	const AABBTreeNode*	GetPos()		const	{ return (const AABBTreeNode*)(mPos&~1);	}
      inline_	const AABBTreeNode*	GetNeg()		const	{ const AABBTreeNode* P = GetPos(); return P ? P+1 : null;}

      /* We don't need to test both nodes since we can't have one without the other	*/
      inline_	bool				IsLeaf()		const	{ return !GetPos();						}

      /* Stats */
      inline_	udword				GetNodeSize()	const	{ return sizeof(*this);					}
   protected:
   /* Tree-independent data */
   /* Following data always belong to the BV-tree, regardless of what the tree actually contains.*/
   /* Whatever happens we need the two children and the enclosing volume.*/
   IceMaths::AABB				mBV;		/* Global bounding-volume enclosing all the node-related primitives */
   size_t				mPos;		/* "Positive" & "Negative" children */
		public:
		// Data access
		inline_	const udword*		GetPrimitives()		const	{ return mNodePrimitives;	}
		inline_	udword				GetNbPrimitives()	const	{ return mNbPrimitives;		}

		protected:
		// Tree-dependent data
				udword*				mNodePrimitives;	//!< Node-related primitives (shortcut to a position in mIndices below)
				udword				mNbPrimitives;		//!< Number of primitives for this node
		// Internal methods
				udword				Split(udword axis, AABBTreeBuilder* builder);
				bool				Subdivide(AABBTreeBuilder* builder);
				void				_BuildHierarchy(AABBTreeBuilder* builder);
				void				_Refit(AABBTreeBuilder* builder);
	};

	///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
	/**
	 *	User-callback, called for each node by the walking code.
	 *	\param		current		[in] current node
	 *	\param		depth		[in] current node's depth
	 *	\param		user_data	[in] user-defined data
	 *	\return		true to recurse through children, else false to bypass them
	 */
	///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
	typedef		bool				(*WalkingCallback)	(const AABBTreeNode* current, udword depth, void* user_data);

	class AABBTree : public AABBTreeNode
	{
		public:
		// Constructor / Destructor
									AABBTree();
									~AABBTree();
		// Build
				bool				Build(AABBTreeBuilder* builder);
				void				Release();

		// Data access
		inline_	const udword*		GetIndices()		const	{ return mIndices;		}	//!< Catch the indices
		inline_	udword				GetNbNodes()		const	{ return mTotalNbNodes;	}	//!< Catch the number of nodes

		// Infos
				bool				IsComplete()		const;
		// Stats
				udword				ComputeDepth()		const;
				udword				GetUsedBytes()		const;
				udword				Walk(WalkingCallback callback, void* user_data) const;

				bool				Refit(AABBTreeBuilder* builder);
				bool				Refit2(AABBTreeBuilder* builder);
		private:
				udword*				mIndices;			//!< Indices in the app list. Indices are reorganized during build (permutation).
				AABBTreeNode*		mPool;				//!< Linear pool of nodes for complete trees. Null otherwise. [Opcode 1.3]
		// Stats
				udword				mTotalNbNodes;		//!< Number of nodes in the tree.
	};

#endif // __OPC_AABBTREE_H__

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩中文字幕91| wwwwxxxxx欧美| 国产成人在线电影| 久久精品国产澳门| 亚洲v中文字幕| 一区二区三区精品| 亚洲一区二区三区在线看| 国产欧美一区视频| 久久久青草青青国产亚洲免观| 日韩免费观看2025年上映的电影 | 91精品国产综合久久香蕉麻豆| jizzjizzjizz欧美| av在线不卡观看免费观看| 成人永久免费视频| 色婷婷国产精品| 在线免费观看日本欧美| 欧美色中文字幕| 制服丝袜av成人在线看| 欧美成人vr18sexvr| 2020国产精品自拍| 中文字幕亚洲不卡| 亚洲在线一区二区三区| 婷婷中文字幕综合| 国产激情视频一区二区在线观看| 粉嫩蜜臀av国产精品网站| 97精品视频在线观看自产线路二| 在线观看精品一区| 欧美一区二区三区人| 久久噜噜亚洲综合| 亚洲精品国产精品乱码不99| 午夜亚洲国产au精品一区二区| 日本成人在线看| 成人免费高清视频在线观看| 日本道精品一区二区三区| 日韩一区二区影院| 国产精品久久久久永久免费观看 | 欧美特级限制片免费在线观看| 欧美一个色资源| 欧美激情一区二区三区蜜桃视频| 亚洲图片欧美综合| 久久精品国产999大香线蕉| aa级大片欧美| 日韩午夜激情av| 亚洲欧美日韩国产另类专区| 丝袜亚洲另类欧美| 成人av电影在线网| 日韩视频一区二区三区在线播放| 国产精品国产三级国产aⅴ无密码| 亚洲 欧美综合在线网络| 国产99久久精品| 91麻豆精品国产自产在线观看一区| 国产婷婷色一区二区三区在线| 亚洲免费av观看| 国产精品正在播放| 911精品国产一区二区在线| 亚洲三级在线播放| 国产成人aaa| 欧美大尺度电影在线| 亚洲午夜视频在线观看| 成人免费毛片片v| 日韩欧美成人一区| 午夜欧美2019年伦理| 99久久久无码国产精品| 久久久av毛片精品| 狠狠色综合播放一区二区| 欧美日韩免费高清一区色橹橹| 中文字幕一区二区三区不卡 | 亚洲成人资源在线| 99re8在线精品视频免费播放| 精品国产123| 美女精品一区二区| 日韩一区二区不卡| 日韩电影免费在线| 制服丝袜av成人在线看| 午夜视频一区在线观看| 欧美老年两性高潮| 天堂午夜影视日韩欧美一区二区| 日本高清不卡一区| 亚洲一卡二卡三卡四卡无卡久久 | 日韩欧美亚洲国产精品字幕久久久| 亚洲国产毛片aaaaa无费看| 91年精品国产| 亚洲精品视频自拍| 欧美在线三级电影| 亚洲第一久久影院| 69久久99精品久久久久婷婷| 亚洲成人你懂的| 欧美一级专区免费大片| 日本不卡1234视频| 久久嫩草精品久久久精品一| 国产一区二区三区| 欧美国产成人精品| 色哟哟亚洲精品| 午夜精品福利一区二区三区av| 欧美日韩国产一级片| 免费观看一级特黄欧美大片| 欧美一区二区福利在线| 久久精品国产99国产| 国产精品丝袜黑色高跟| 一本大道av伊人久久综合| 午夜精品在线看| 亚洲精品一区二区三区精华液| 国产99久久久久| 亚洲国产一区二区三区| 日韩亚洲欧美成人一区| eeuss影院一区二区三区| 一区二区三区**美女毛片| 日韩一区二区三区av| 波多野结衣中文一区| 日韩中文字幕区一区有砖一区| 国产性色一区二区| 欧美三级在线看| 黄页网站大全一区二区| 一区在线观看视频| 在线观看亚洲a| 蜜桃视频一区二区| 亚洲精品免费播放| 91精品婷婷国产综合久久竹菊| 另类成人小视频在线| 中文天堂在线一区| 蜜桃在线一区二区三区| 亚洲欧洲三级电影| 欧美精品乱码久久久久久按摩| 美国三级日本三级久久99| 国产午夜亚洲精品理论片色戒 | 波多野结衣在线aⅴ中文字幕不卡| 1024成人网| 91精品国产综合久久久久久久久久 | 亚洲精品乱码久久久久久黑人| 欧美喷水一区二区| 成人在线综合网| 亚洲成人在线观看视频| 欧美国产禁国产网站cc| 欧美精品一卡二卡| 一本到不卡精品视频在线观看 | 26uuu久久综合| 欧美精品vⅰdeose4hd| 国产二区国产一区在线观看| 亚洲精品成人在线| 久久久www免费人成精品| 欧美天天综合网| 国产aⅴ综合色| 狠狠色丁香婷综合久久| 亚洲国产一二三| 中文一区二区完整视频在线观看| 69久久夜色精品国产69蝌蚪网| 波多野结衣在线一区| 高清在线不卡av| 久久99在线观看| 视频一区中文字幕| 一区二区三区在线视频免费| 欧美日韩国产在线观看| 欧美日韩精品一区二区三区四区| 国产高清精品久久久久| 美女一区二区三区| 亚洲一区二区三区小说| 亚洲四区在线观看| 亚洲欧美电影院| 国产精品国产精品国产专区不蜜 | 欧美日韩免费高清一区色橹橹| 成人的网站免费观看| 久久成人免费电影| 国产伦理精品不卡| 激情深爱一区二区| 亚洲一区二区三区四区在线免费观看| 精品国产伦理网| 欧美一级二级三级蜜桃| 欧美精品v国产精品v日韩精品| 欧美一级淫片007| 欧美一二区视频| 欧美一区二区三区啪啪| 欧美一区二区视频网站| 日本道免费精品一区二区三区| 精品视频123区在线观看| 在线一区二区视频| 欧美中文字幕亚洲一区二区va在线 | 亚洲成人精品在线观看| 午夜精品在线看| 秋霞电影网一区二区| 日本不卡免费在线视频| 国产精品一二三在| 成人毛片视频在线观看| 99精品视频在线观看| 97国产一区二区| 91在线视频播放地址| 欧美日韩国产色站一区二区三区| 欧美午夜精品免费| 欧美综合一区二区| 欧美丝袜丝交足nylons图片| 69堂亚洲精品首页| 久久久久综合网| 亚洲色图在线看| 婷婷久久综合九色国产成人| 麻豆一区二区在线| 国产精品中文字幕日韩精品| 精品一区二区三区在线观看 | 在线日韩一区二区| 精品国产青草久久久久福利| 日韩免费视频线观看| 亚洲色图20p|