当前位置: 首页>>代码示例>>C++>>正文


C++ LPD3DXFONT::Release方法代码示例

本文整理汇总了C++中LPD3DXFONT::Release方法的典型用法代码示例。如果您正苦于以下问题:C++ LPD3DXFONT::Release方法的具体用法?C++ LPD3DXFONT::Release怎么用?C++ LPD3DXFONT::Release使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在LPD3DXFONT的用法示例。


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

示例1: Game_End

void Game_End()
{
    if (fontArial24) fontArial24->Release(); 
    if (fontGaramond36) fontGaramond36->Release();
    if (fontTimesNewRoman40) fontTimesNewRoman40->Release();

    DirectInput_Shutdown();
    Direct3D_Shutdown();
}
开发者ID:kyphelps,项目名称:spring-2013,代码行数:9,代码来源:MyGame.cpp

示例2: CloseDirect3D

// Close the Device and Direct3D
void CloseDirect3D()
{
	dxfont->Release();
	dxfontpeschkes->Release();
    d3ddev->Release();
    d3d->Release();

    return;
}
开发者ID:ppeschke,项目名称:hexar,代码行数:10,代码来源:direct3d.cpp

示例3: cleanD3D

// this is the function that cleans up Direct3D and COM
void cleanD3D(void)
{
    v_buffer->Release();    // close and release the vertex buffer
	font->Release();
    d3ddev->Release();    // close and release the 3D device
    d3d->Release();    // close and release Direct3D
}
开发者ID:m3lawren,项目名称:ClothDemo,代码行数:8,代码来源:main.cpp

示例4: cleanup

void cleanup()   // it's a dirty job.. but some function has to do it...
{
    if (myRect1)
        delete myRect1;
    if (myRect2)
        delete myRect2;
    if (myRect3)
        delete myRect3;
    if (myRect4)
        delete myRect4;
    if (myRect5)
        delete myRect5;

    if ( lpD3DDevice9 != NULL )
        lpD3DDevice9->Release();

    if ( lpD3D9 != NULL )
        lpD3D9->Release();

    if ( lpD3DXFont != NULL )
        lpD3DXFont->Release();

    if ( lpD3DTex1 != NULL )
        lpD3DTex1->Release();
}
开发者ID:pnchang,项目名称:advgraphics,代码行数:25,代码来源:example04.cpp

示例5: Game_End

void Game_End()
{
    background->Release();
    font->Release();
    DirectInput_Shutdown();
    Direct3D_Shutdown();
}
开发者ID:kyphelps,项目名称:spring-2013,代码行数:7,代码来源:MyGame.cpp

示例6: UninitDebugProc

//=============================================================================
// デバッグ表示処理の終了処理
//=============================================================================
void UninitDebugProc(void)
{
	if(g_pD3DXFont != NULL)
	{// 情報表示用フォントの開放
		g_pD3DXFont->Release();
		g_pD3DXFont = NULL;
	}
}
开发者ID:andylam5538,项目名称:sango,代码行数:11,代码来源:debugproc.cpp

示例7: DrawString

void DrawString(int x, int y, int FontSize, DWORD color, LPD3DXFONT g_pFont, LPCSTR Message)
{
	D3DXCreateFont(d3ddev, FontSize, 0, FW_BOLD, 1, 0, DEFAULT_CHARSET, OUT_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | FF_DONTCARE, "Arial", &pFont);

	RECT FontPos = { x, y, x + 120, y + 16 };

	pFont->DrawTextA(NULL, Message, -1, (LPRECT)&FontPos, 0, color);
	pFont->Release();
}
开发者ID:mathijs0587,项目名称:WinCpp,代码行数:9,代码来源:WinCpp.cpp

示例8: D3DShutdown

// Uninitialise D3D
void D3DShutdown()
{
	// Release D3D interfaces
	if (g_pFont != NULL)
		g_pFont->Release();

    if( g_pd3dDevice != NULL )
        g_pd3dDevice->Release();

    if( g_pD3D != NULL )
        g_pD3D->Release();
}
开发者ID:Nixxus,项目名称:GamesDevelopment2,代码行数:13,代码来源:MainApp.cpp

示例9: cleanup

void cleanup()   // it's a dirty job.. but some function has to do it...
{
   if (myRect1)
      delete myRect1;
   if (myRect2)
      delete myRect2;

   if ( lpD3DDevice8 != NULL ) 
        lpD3DDevice8->Release();

   if ( lpD3D8 != NULL )       
        lpD3D8->Release();

   if ( lpD3DXFont != NULL )
      lpD3DXFont->Release();
}
开发者ID:pnchang,项目名称:advgraphics,代码行数:16,代码来源:example03.cpp

示例10: Release

 VOID  JN_DXFontMgr::Release(  VOID  )
{
	FontMapIter		iter = m_FontMap.begin();

	for( ; iter != m_FontMap.end() ; iter++ )
	{
		LPD3DXFONT pFont	= iter->second;

		if( pFont != NULL )
		{
			pFont->Release();
		}
	}

	m_FontMap.clear();
}
开发者ID:KimHyeongJin,项目名称:MyDirect3D,代码行数:16,代码来源:JN_DXFontMgr.cpp

示例11: cleanD3D

// this is the function that cleans up Direct3D and COM
void cleanD3D(void) {
	if (d3ddev != NULL) {
		d3ddev->Release();
	}
	if (d3ddev != NULL) {
		d3d->Release();
	}
	if (tx != NULL) {
		tx->Release();
	}
	if (vb != NULL) {
		vb->Release();
	}
	if (font != NULL) {
		font->Release();
	}
}
开发者ID:Griffone,项目名称:Everward,代码行数:18,代码来源:Graphics.cpp

示例12: DrawScore

VOID Graphics::DrawScore(LPCWSTR TextString, int x, int y, int x1, int y1, D3DCOLOR MyColor)
{
	LPD3DXFONT pFont = NULL;
	RECT Rec;
	HFONT hFont;

	hFont = CreateFont(30,10,0,0,FW_NORMAL,FALSE,FALSE,0,1,0,0,0,DEFAULT_PITCH|FF_MODERN,TEXT("Arial"));

	Rec.left = x;
	Rec.top = y;
	Rec.right = x1;
	Rec.bottom = y1;

	D3DXCreateFont(this->GetDevice(),30,10,FW_NORMAL,0,FALSE,1,0,0,DEFAULT_PITCH|FF_MODERN,TEXT("Times New Roman"),&pFont);
	pFont->DrawText(NULL,TextString,-1,&Rec,DT_WORDBREAK,MyColor);

	DeleteObject(hFont);
	if (pFont != NULL)
		pFont->Release();
}
开发者ID:Atimormia,项目名称:scroller,代码行数:20,代码来源:Graphics.cpp

示例13: Cleanup

VOID Cleanup( )
{
	if (NULL != g_pFont)
	{
		g_pFont->Release();
	}

	if (NULL != g_pMesh)
	{
		g_pMesh->Release();
	}

	if ( NULL != g_pD3DDevice )
	{
		g_pD3DDevice->Release();
	}

	if ( NULL != g_pD3D )
	{
		g_pD3D->Release();
	}
}
开发者ID:trizdreaming,项目名称:AABB_OBB_collision,代码行数:22,代码来源:AABB_OBB_collision.cpp

示例14: DrawTextString

void cGraphicsLayer::DrawTextString( int x, int y,
                                     DWORD color, const char * str )
{

    HRESULT r = 0;

    if( !m_pBackSurf )
        return;

    // Get a handle for the font to use
    HFONT hFont = (HFONT)GetStockObject( SYSTEM_FONT );

    LPD3DXFONT pFont = 0;
    // Create the D3DX Font
    r = D3DXCreateFont( m_pDevice, hFont, &pFont );
    if( FAILED( r ) )
        return;

    // Rectangle where the text will be located
    RECT TextRect = { x, y, 0, 0 };

    // Inform font it is about to be used
    pFont->Begin();

    // Calculate the rectangle the text will occupy
    pFont->DrawText( str, -1, &TextRect, DT_CALCRECT, 0 );

    // Output the text, left aligned
    pFont->DrawText( str, -1, &TextRect, DT_LEFT, color );

    // Finish up drawing
    pFont->End();

    // Release the font
    pFont->Release();

}
开发者ID:ehershey,项目名称:development,代码行数:37,代码来源:GraphicsLayer.cpp

示例15:

void	IEX_ReleaseText( void )
{
	g_pd3dFont->Release();
	g_pd3dFontM->Release();
}
开发者ID:2015ECCSSPaperProject,项目名称:MAIN,代码行数:5,代码来源:IEX_Direct3D.cpp


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