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

📄 baseentity.h

📁 java实现的简单的分形树。简单易学!是学习分形知识的很好的例子。其java语法简单
💻 H
字号:
#ifndef __BASE_ENTITY_H
#define __BASE_ENTITY_H

#include <dingus/math/AABox.h>
#include <dingus/renderer/RenderableMesh.h>


class CBaseEntity {
public:
	/**
	 *  Frustum-culls, if potentially visible then computes WorldView
	 *  and WVP matrices.
	 *  @return true if potentially visible.
	 */
	bool preRender() {
		const CRenderCamera& cam = G_RENDERCTX->getCamera();
		if( !mAABB.frustumCull( mMatrix, cam.getViewProjMatrix() ) ) {
			mWorldView = mMatrix * cam.getViewMatrix();
			mWVP = mWorldView * cam.getProjectionMatrix();
			return true;
		}
		return false;
	}

public:
	SMatrix4x4	mMatrix;
	SMatrix4x4	mWorldView;
	SMatrix4x4	mWVP;
	CAABox		mAABB;
};


#endif

⌨️ 快捷键说明

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