• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

C++ LoadTextures函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C++中LoadTextures函数的典型用法代码示例。如果您正苦于以下问题:C++ LoadTextures函数的具体用法?C++ LoadTextures怎么用?C++ LoadTextures使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了LoadTextures函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: player

PlayerResource ResourceCache::LoadPlayer(
   const PlayerType type,
   const std::string& name,
   const TiXmlHandle& hndl
)
{
   const Size size = { static_cast<int>(mAppConfig.GetCellSize().Width * 1.55f),
                       static_cast<int>(mAppConfig.GetCellSize().Height * 1.75f) };
   const auto walk_len = 1000_ms;
   const auto spawn_len = 1000_ms;
   const auto death_len = 1000_ms;
   const auto player_hndl = hndl.FirstChild(name);

   PlayerResource player(type);
   player.SetFrames(PlayerAnimation::StandUp, walk_len, LoadTextures(player_hndl, "StandUp", size));
   player.SetFrames(PlayerAnimation::StandDown, walk_len, LoadTextures(player_hndl, "StandDown", size));
   player.SetFrames(PlayerAnimation::StandLeft, walk_len, LoadTextures(player_hndl, "StandLeft", size));
   player.SetFrames(PlayerAnimation::StandRight, walk_len, LoadTextures(player_hndl, "StandRight", size));
   player.SetFrames(PlayerAnimation::WalkUp, walk_len, LoadTextures(player_hndl, "WalkUp", size));
   player.SetFrames(PlayerAnimation::WalkDown, walk_len, LoadTextures(player_hndl, "WalkDown", size));
   player.SetFrames(PlayerAnimation::WalkLeft, walk_len, LoadTextures(player_hndl, "WalkLeft", size));
   player.SetFrames(PlayerAnimation::WalkRight, walk_len, LoadTextures(player_hndl, "WalkRight", size));
   player.SetFrames(PlayerAnimation::Spawn, spawn_len, LoadTextures(player_hndl, "Spawn", size));
   player.SetFrames(PlayerAnimation::Destroy, death_len, LoadTextures(player_hndl, "Death", size));
   return player;
}
开发者ID:vobject,项目名称:bomberperson,代码行数:26,代码来源:ResourceCache.cpp


示例2: indestructible

void ResourceCache::LoadWallResources(const TiXmlHandle& hndl)
{
   const Size size = mAppConfig.GetCellSize();

   WallResource indestructible(WallType::Indestructible, LoadTextures(hndl, "Indestructible", size));
   WallResource destructible(WallType::Destructible, LoadTextures(hndl, "Destructible", size));

   mWallRes.insert({ indestructible.GetType(), indestructible });
   mWallRes.insert({ destructible.GetType(), destructible });
}
开发者ID:vobject,项目名称:bomberperson,代码行数:10,代码来源:ResourceCache.cpp


示例3: arena_1

void ResourceCache::LoadArenaResources(const TiXmlHandle& hndl)
{
   const Size size = mAppConfig.GetArenaSize();

   ArenaResource arena_1(ArenaType::Arena_1, LoadTextures(hndl, "Arena_1", size));
   ArenaResource arena_2(ArenaType::Arena_2, LoadTextures(hndl, "Arena_2", size));
   ArenaResource arena_3(ArenaType::Arena_3, LoadTextures(hndl, "Arena_3", size));

   mArenaRes.insert({ arena_1.GetType(), arena_1 });
   mArenaRes.insert({ arena_2.GetType(), arena_2 });
   mArenaRes.insert({ arena_3.GetType(), arena_3 });
}
开发者ID:vobject,项目名称:bomberperson,代码行数:12,代码来源:ResourceCache.cpp


示例4: countdown

void ResourceCache::LoadBombResources(const TiXmlHandle& hndl)
{
   const Size size = mAppConfig.GetCellSize();
   const auto len = mAppConfig.GetBombLifetime();

   BombResource countdown(BombType::Countdown);
   countdown.SetFrames(len, LoadTextures(hndl, "Countdown", size));

   BombResource remote(BombType::Remote);
   remote.SetFrames(len, LoadTextures(hndl, "Remote", size));

   mBombRes.insert({ countdown.GetType(), countdown });
   mBombRes.insert({ remote.GetType(), remote });
}
开发者ID:vobject,项目名称:bomberperson,代码行数:14,代码来源:ResourceCache.cpp


示例5: pContainer

World::Impl::Impl( World * container, sf::RenderTarget & target, FontManager & fonts, SoundPlayer & sounds, bool isNetworked ) :
	pContainer( container ),
	mTarget( target ),
	mWorldView( target.getDefaultView() ),
	mTextures(),
	mFonts( fonts ),
	mSounds( sounds ),
	mSceneGraph(),
	mSceneLayers(),
	mWorldBounds( 0.f, 0.f, mWorldView.getSize().x, 5000.f ),
	mSpawnPosition( mWorldView.getSize().x / 2.f, mWorldBounds.height - mWorldView.getSize().y / 2.f ),
	mScrollSpeed( -50.f ),
	mScrollSpeedCompensation( 1.f ),
	mPlayerAircrafts(),
	mEnemySpawnPoints(),
	mActiveEnemies(),
	mNetworkedWorld( isNetworked ),
	mNetworkNode( nullptr ),
	mPhysics( b2Vec2( 0.f, 9.8f ) )
{
	mSceneTexture.create( mTarget.getSize().x, mTarget.getSize().y );

	LoadTextures();
	BuildScene();
	mWorldView.setCenter( mSpawnPosition );
}
开发者ID:chehob,项目名称:SFMLDev,代码行数:26,代码来源:World.cpp


示例6: checkf

void FImGuiModuleManager::AddWidgetToViewport(UGameViewportClient* GameViewport)
{
	checkf(GameViewport, TEXT("Null game viewport."));
	checkf(FSlateApplication::IsInitialized(), TEXT("Slate should be initialized before we can add widget to game viewports."));

	// Make sure that we have a context for this viewport's world and get its index.
	int32 ContextIndex;
	auto& Proxy = ContextManager.GetWorldContextProxy(*GameViewport->GetWorld(), ContextIndex);

	// Make sure that textures are loaded before the first Slate widget is created.
	LoadTextures();

	// Create and initialize the widget.
	TSharedPtr<SImGuiWidget> SharedWidget;
	SAssignNew(SharedWidget, SImGuiWidget).ModuleManager(this).GameViewport(GameViewport).ContextIndex(ContextIndex);

	// We transfer widget ownerships to viewports but we keep weak references in case we need to manually detach active
	// widgets during module shutdown (important during hot-reloading).
	if (TWeakPtr<SImGuiWidget>* Slot = Widgets.FindByPredicate([](auto& Widget) { return !Widget.IsValid(); }))
	{
		*Slot = SharedWidget;
	}
	else
	{
		Widgets.Emplace(SharedWidget);
	}
}
开发者ID:peckhuang,项目名称:UnrealImGui,代码行数:27,代码来源:ImGuiModuleManager.cpp


示例7: LoadModel

bool ModelClass::Initialize(ID3D11Device *device, char *modelFilename, WCHAR *textureFilename1, WCHAR * textureFilename2, WCHAR *textureFilename3)
{
	bool result;

	//load model data
	result = LoadModel(modelFilename);
	if (!result)
	{
		return false;
	}

	//intialize the vertex and index buffer that hold the geometry for the triangle
	result = InitializeBuffers(device);
	if (!result)
	{
		return false;
	}

	//load the texture for this model
	result = LoadTextures(device, textureFilename1, textureFilename2, textureFilename3);
	if (!result)
	{
		return false;
	}

	return true;
}
开发者ID:miaojiuchen,项目名称:MGraphics,代码行数:27,代码来源:modelclass.cpp


示例8: CalModel

///<summary>
/// CAnimatedInstanceModel:: Initialize
///</summary>
///<param name="AnimatedCoreModel"></param>
void CAnimatedInstanceModel::Initialize(CAnimatedCoreModel *AnimatedCoreModel)
{
  m_AnimatedCoreModel = AnimatedCoreModel;
  m_iNumAnimations = m_AnimatedCoreModel->GetNumAnimations();

  m_CalModel = new CalModel(m_AnimatedCoreModel->GetCoreModel());
  int meshId;
  for(meshId = 0; meshId < AnimatedCoreModel->GetCoreModel()->getCoreMeshCount(); meshId++)
  {
    m_CalModel->attachMesh(meshId);
  }
  
  LoadTextures();
  
  BlendCycle(1, 0.0f);
	
	CEffectManager *l_EffectManager=CORE->GetEffectManager();
	std::string &l_EffectTechniqueName=l_EffectManager->GetTechniqueEffectNameByVertexDefault(CAL3D_HW_VERTEX::GetVertexType());
	const std::string &l_ModelName= m_AnimatedCoreModel->GetAnimatedCoreModelName();

	if(l_ModelName=="bot")
	{
		m_EffectTechnique=l_EffectManager->GetEffectTechnique(m_AnimatedCoreModel->GetTechniqueName());
	}
	else
	{
		m_EffectTechnique=l_EffectManager->GetEffectTechnique(l_EffectTechniqueName);
	}
}
开发者ID:BGCX261,项目名称:zombigame-svn-to-git,代码行数:33,代码来源:AnimatedInstanceModel.cpp


示例9: CleanUpMesh

HRESULT Mesh::LoadMesh(WCHAR* directory, WCHAR* name, WCHAR* extension)
{
  HRESULT hr;
  
  CleanUpMesh();
    
  SetDirectory( directory );
  SetName( name );
  WCHAR meshfile[120];
  WCHAR meshpathrel[120];
  WCHAR meshpath[120];
  Concat(meshfile, name, extension );
  Concat(meshpathrel, directory, meshfile );
  AppendToRootDir(meshpath, meshpathrel);

  hr = D3DXLoadMeshFromX( meshpath, 
                          D3DXMESH_MANAGED | D3DXMESH_32BIT, mDevice, NULL, 
                          &mMaterialBuffer, NULL, &mNumMaterials, &mMesh );
  
  PD(hr, L"load mesh from file");
  if(FAILED(hr)) return hr;

  mMaterials = (D3DXMATERIAL*)mMaterialBuffer->GetBufferPointer();
    
  PD( AdjustMeshDecl(), L"adjust mesh delaration" );
  PD( AttribSortMesh(), L"attribute sort mesh" );
  PD( LoadTextures(), L"load textures" );
	PD( CreateTopologyFromMesh(), L"create topology from mesh");
  return D3D_OK;
}
开发者ID:flosmn,项目名称:MeshPRT,代码行数:30,代码来源:Mesh.cpp


示例10: main

int main(int argc, char* argv[])
{
	glutInit(&argc, argv);
	glutInitWindowSize(1024, 768);
	glutInitDisplayMode(GLUT_DOUBLE | GLUT_RGB | GLUT_DEPTH);
	glutCreateWindow("Arkanoid");
	glutFullScreen();

	glutDisplayFunc(Render);
	glutReshapeFunc(Resize);
	glutIdleFunc(Render);
	glutKeyboardFunc(Keys);
	glutSpecialFunc(PressKey);
	glutPassiveMotionFunc(PassiveMouseMove);
	glutMotionFunc(MouseMove);
	glutMouseFunc(MouseButton);
	ShowCursor(GL_FALSE);

	glEnable(GL_DEPTH_TEST);
	glEnable(GL_TEXTURE_2D);
	glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
	glEnable(GL_BLEND);	
	
	LoadTextures();
	InitializeCubes();
	projection.InitParts(0.001, 0, ROOM_HEIGHT, -ROOM_HALF_LENGTH);

	glutMainLoop();
	return 0;
}
开发者ID:MetallEast,项目名称:Arkanoid3D,代码行数:30,代码来源:Main.cpp


示例11: LoadModel

bool ModelClass::Initialize(ID3D11Device* device, char* modelFilename, WCHAR* colorTextureFilename, WCHAR* normalTextureFilename)
{
	bool result;


	// Load in the model data,
	result = LoadModel(modelFilename);
	if(!result)
	{
		return false;
	}

	// Initialize the vertex and index buffers.
	result = InitializeBuffers(device);
	if(!result)
	{
		return false;
	}

	// Load the textures for this model.
	result = LoadTextures(device, colorTextureFilename, normalTextureFilename);
	if(!result)
	{
		return false;
	}

	return true;
}
开发者ID:Scillman,项目名称:rastertek-dx11-tutorials,代码行数:28,代码来源:modelclass.cpp


示例12: bitTrace

// Public funcions
BIT_UINT32 GUIManager::Load( )
{
	if( m_Loaded )
	{
		bitTrace( "[GUIManager::Load] Already loaded\n" );
		return BIT_ERROR;
	}

	if( m_pGraphicDevice == BIT_NULL )
	{
		bitTrace( "[GUIManager::Load] Graphic device is NULL\n" );
		return BIT_ERROR;
	}

	if( LoadVertexObject( ) != BIT_OK )
	{
		bitTrace( "[GUIManager::Load] Can not load the vertex object\n" );
		return BIT_ERROR;
	}

	if( LoadShaders( ) != BIT_OK )
	{
		bitTrace( "[GUIManager::Load] Can not load the shaders\n" );
		return BIT_ERROR;
	}

	if( LoadTextures( ) != BIT_OK )
	{
		bitTrace( "[GUIManager::Load] Can not load the textures\n" );
		return BIT_ERROR;
	}

	m_Loaded = BIT_TRUE;
	return BIT_OK;
}
开发者ID:jimmiebergmann,项目名称:Bit-Engine-Examples,代码行数:36,代码来源:GUIManager.cpp


示例13: LoadModel

bool BumpModelClass::Initialize(ID3D10Device* device, char* modelFilename, WCHAR* textureFilename1, WCHAR* textureFilename2)
{
    bool result;


    // Load in the model data.
    result = LoadModel(modelFilename);
    if(!result)
    {
        return false;
    }

    // Calculate the normal, tangent, and binormal vectors for the model.
    CalculateModelVectors();

    // Initialize the vertex and index buffer that hold the geometry for the model.
    result = InitializeBuffers(device);
    if(!result)
    {
        return false;
    }

    // Load the textures for this model.
    result = LoadTextures(device, textureFilename1, textureFilename2);
    if(!result)
    {
        return false;
    }

    return true;
}
开发者ID:jiangguang5201314,项目名称:ZNginx,代码行数:31,代码来源:bumpmodelclass.cpp


示例14: myinit

void myinit(void)
{
	auxInitDisplayMode(AUX_DOUBLE|AUX_RGBA);
	auxInitPosition(100,100,800,600);

	auxInitWindow((LPCWSTR)"Solar System");

	GLfloat light_ambient[]={0.3,0.5,0.3};
	GLfloat light_diffuse[]={1.0,1.0,1.0};
	GLfloat light_specular[]={0.8,0.8,0.0};
	GLfloat light_position[]={0.0,0.0,0.0};

	glLightfv(GL_LIGHT0,GL_AMBIENT,light_ambient);
	glLightfv(GL_LIGHT0,GL_DIFFUSE,light_diffuse);
	glLightfv(GL_LIGHT0,GL_SPECULAR,light_specular);
	glLightfv(GL_LIGHT0,GL_POSITION, light_position);
	glEnable(GL_LIGHTING);
	glEnable(GL_LIGHT0);

	glClearColor(0, 0, 0, 0);
	glShadeModel(GL_SMOOTH);

	glEnable(GL_TEXTURE_GEN_S);
	glEnable(GL_TEXTURE_2D);
	glEnable(GL_DEPTH_TEST);
	glEnable(GL_LIGHTING);
	glEnable(GL_CULL_FACE);
	LoadTextures(texture_id);

	for(int i = 0;i<8;i++){
		year[i]=(rand()%360);
		day[i]=0;
	}
		
}
开发者ID:SysMa,项目名称:msq-summer-project,代码行数:35,代码来源:1.cpp


示例15: InitView

/*!****************************************************************************
 @Function		InitView
 @Return		bool		true if no error occurred
 @Description	Code in InitView() will be called by PVRShell upon
				initialization or after a change in the rendering context.
				Used to initialize variables that are dependent on the rendering
				context (e.g. textures, vertex buffers, etc.)
******************************************************************************/
bool OGLESPVRScopeRemote::InitView()
{
	CPPLProcessingScoped PPLProcessingScoped(m_psSPSCommsData,
		__FUNCTION__, static_cast<unsigned int>(strlen(__FUNCTION__)), m_i32FrameCounter);

	CPVRTString ErrorStr;
	/*
		Initialize Print3D
	*/
    bool bRotate = PVRShellGet(prefIsRotated) && PVRShellGet(prefFullScreen);

	if(m_Print3D.SetTextures(0,PVRShellGet(prefWidth),PVRShellGet(prefHeight), bRotate) != PVR_SUCCESS)
	{
		PVRShellSet(prefExitMessage, "ERROR: Cannot initialise Print3D\n");
		return false;
	}

	// Sets the clear color
	glClearColor(0.6f, 0.8f, 1.0f, 1.0f);

	// Enables texturing
	glEnable(GL_TEXTURE_2D);

	//	Initialize VBO data
	if(!LoadVbos(&ErrorStr))
	{
		PVRShellSet(prefExitMessage, ErrorStr.c_str());
		return false;
	}

	/*
		Load textures
	*/
	if(!LoadTextures(&ErrorStr))
	{
		PVRShellSet(prefExitMessage, ErrorStr.c_str());
		return false;
	}

	/*
		Calculate the projection and view matrices
	*/

	m_mProjection = PVRTMat4::PerspectiveFovRH(PVRT_PIf/6, (float)PVRShellGet(prefWidth)/(float)PVRShellGet(prefHeight), CAM_NEAR, CAM_FAR, PVRTMat4::OGL, bRotate);

	m_mView = PVRTMat4::LookAtRH(PVRTVec3(0, 0, 75.0f), PVRTVec3(0, 0, 0), PVRTVec3(0, 1, 0));

	// Enable the depth test
	glEnable(GL_DEPTH_TEST);

	// Enable culling
	glEnable(GL_CULL_FACE);

	// Initialise variables used for the animation
	m_fFrame = 0;
	m_iTimePrev = PVRShellGetTime();

	return true;
}
开发者ID:joyfish,项目名称:GameThirdPartyLibs,代码行数:67,代码来源:OGLESPVRScopeRemote.cpp


示例16: LOGV

SObjModel::SObjModel(const std::string&  fname)
{
    LOGV("Opening obj model %s" ,fname.c_str());
    CObjMeshParser parser;
    ObjCtx * ctx = parser.ParseFromFile(fname);

    if (!ctx)
        {
            LOGE("Unable open model");
            return;
        }

    auto submesh_set = ctx->subMeshSet;
    long total_triangles = 0;
    for (auto it = submesh_set.begin(); it != submesh_set.end();++it) {
        MeshIndexer idx;
        auto res = idx.IndexNonIndexedMesh(*it);
        (*it)->vn.clear();
        total_triangles += res->vn.size();
        d_sm.push_back(res);
   }
    std::vector<std::string> mtlrefs = ctx->refMaterialFiles;
    CObjMeshParser::ReleaseContext(ctx);
    LOGV("Mesh information: Submesh count:%d, Total mesh triangles:%d", d_sm.size(), total_triangles );

    LOGV("Load materials");

    //std::string s = mtlrefs[0];
    //printf("RefMaterial:%s\n",s.c_str());

    if (!mtlrefs.empty())
    {
        std::string json_fname = std::string(mtlrefs[0]+std::string(".json"));

        //if (CheckFileExists(json_fname)) {
        if (false) {
        /* Load */
            std::ifstream ifs(json_fname);
            {
                cereal::JSONInputArchive arch(ifs);
                arch(d_materials);
            }

        } else {
            MTLParser mtl_p(mtlrefs[0]);
            d_materials = mtl_p.GetMaterials(); //OMG copy!! FIX ME
            mtl_p.SaveToJSON(json_fname);

        }
    }

    LoadTextures();
    BindVAOs();

    LOGV("Model configured");
    IsReady = true;

}
开发者ID:wingrime,项目名称:ShaderTestPlatform,代码行数:58,代码来源:ObjModel.cpp


示例17: center

void ResourceCache::LoadExplosionResources(const TiXmlHandle& hndl)
{
   const Size size = mAppConfig.GetCellSize();
   const auto len = mAppConfig.GetExplosionLifetime();

   ExplosionResource center(ExplosionType::Center);
   center.SetFrames(len, LoadTextures(hndl, "Center", size));

   ExplosionResource horizontal(ExplosionType::Horizontal);
   horizontal.SetFrames(len, LoadTextures(hndl, "Horizontal", size));

   ExplosionResource horizontal_leftend(ExplosionType::HorizontalLeftEnd);
   horizontal_leftend.SetFrames(len, LoadTextures(hndl, "HorizontalLeftEnd", size));

   ExplosionResource horizontal_rightend(ExplosionType::HorizontalRightEnd);
   horizontal_rightend.SetFrames(len, LoadTextures(hndl, "HorizontalRightEnd", size));

   ExplosionResource vertical(ExplosionType::Vertical);
   vertical.SetFrames(len, LoadTextures(hndl, "Vertical", size));

   ExplosionResource vertical_upend(ExplosionType::VerticalUpEnd);
   vertical_upend.SetFrames(len, LoadTextures(hndl, "VerticalUpEnd", size));

   ExplosionResource vertical_downend(ExplosionType::VerticalDownEnd);
   vertical_downend.SetFrames(len, LoadTextures(hndl, "VerticalDownEnd", size));

   mExplosionRes.insert({ center.GetType(), center });
   mExplosionRes.insert({ horizontal.GetType(), horizontal });
   mExplosionRes.insert({ horizontal_leftend.GetType(), horizontal_leftend });
   mExplosionRes.insert({ horizontal_rightend.GetType(), horizontal_rightend });
   mExplosionRes.insert({ vertical.GetType(), vertical });
   mExplosionRes.insert({ vertical_upend.GetType(), vertical_upend });
   mExplosionRes.insert({ vertical_downend.GetType(), vertical_downend });
}
开发者ID:vobject,项目名称:bomberperson,代码行数:34,代码来源:ResourceCache.cpp


示例18: Initsialaize

void Initsialaize() {
    LoadTextures();
    glEnable(GL_TEXTURE_2D);
    glClearColor(0.0, 0.0, 0.0, 1.0);
    glMatrixMode(GL_PROJECTION);
    glLoadIdentity();
    glOrtho(-4.0, 4.0, -4.0, 4.0, -10.0, 10.0);
    glMatrixMode(GL_MODELVIEW);
}
开发者ID:tapin13,项目名称:OpenGL-Lesson-12-2,代码行数:9,代码来源:main.cpp


示例19: InitView

/*!****************************************************************************
 @Function		InitView
 @Return		bool		true if no error occured
 @Description	Code in InitView() will be called by PVRShell upon
				initialization or after a change in the rendering context.
				Used to initialize variables that are dependant on the rendering
				context (e.g. textures, vertex buffers, etc.)
******************************************************************************/
bool OGLES3TextureStreaming::InitView()
{
	CPVRTString ErrorStr;

	//	Initialize VBO data
	if(!LoadVbos(&ErrorStr))
	{
		PVRShellSet(prefExitMessage, ErrorStr.c_str());
		return false;
	}

	//	Load textures
	if(!LoadTextures(&ErrorStr))
	{
		PVRShellSet(prefExitMessage, ErrorStr.c_str());
		return false;
	}

	//	Load and compile the shaders & link programs
	if(!LoadShaders(&ErrorStr))
	{
		PVRShellSet(prefExitMessage, ErrorStr.c_str());
		return false;
	}

	/*
		Initialize the textures used by Print3D.
		To properly display text, Print3D needs to know the viewport dimensions
		and whether the text should be rotated. We get the dimensions using the
		shell function PVRShellGet(prefWidth/prefHeight). We can also get the
		rotate parameter by checking prefIsRotated and prefFullScreen.
	*/
	bool bRotate = PVRShellGet(prefIsRotated) && PVRShellGet(prefFullScreen);

	if(m_Print3D.SetTextures(0, PVRShellGet(prefWidth), PVRShellGet(prefHeight), bRotate) != PVR_SUCCESS)
	{
		PVRShellSet(prefExitMessage, "ERROR: Cannot initialise Print3D\n");
		return false;
	}

	//Set OpenGL ES render states needed for this demo

	// Enable backface culling and depth test
	glCullFace(GL_BACK);
	glEnable(GL_CULL_FACE);

	glEnable(GL_DEPTH_TEST);

	// Sets the clear color
	glClearColor(0.6f, 0.8f, 1.0f, 1.0f);

	// Setup the AV capture
	if(!m_Camera.InitialiseSession(ePVRTHWCamera_Front))
		return false;

	return true;
}
开发者ID:joyfish,项目名称:GameThirdPartyLibs,代码行数:65,代码来源:OGLES3TextureStreaming.cpp


示例20: Initialize

//-----------------------------------------------------------------------------------------------
void Initialize( HINSTANCE applicationInstanceHandle )
{
	CreateOpenGLWindow( applicationInstanceHandle );
	OpenGLRenderer::Initalize();
	InitializeTime();
	LoadTextures();
	LoadDeveloperConsole();
	g_game.Initialize();
}
开发者ID:MrBowler,项目名称:SD6-A3,代码行数:10,代码来源:Main_Win32.cpp



注:本文中的LoadTextures函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C++ LoadTree函数代码示例发布时间:2022-05-30
下一篇:
C++ LoadTexture函数代码示例发布时间:2022-05-30
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap