Main Page | Namespace List | Class Hierarchy | Alphabetical List | Compound List | File List | Namespace Members | Compound Members | File Members

Lamp::GraphicsDevice Class Reference

グラフィックスデバイス More...

#include <GraphicsDevice.h>

List of all members.

Public Member Functions

void setClipCursor (bool clipFlag)
 カーソルクリップの設定

bool getClipCursor ()
 カーソルクリップの取得

void clear (Color4c color=Color4c(0, 0, 0, 0), float zValue=1.0f, u_int stencilValue=0)
 クリア

bool presentation ()
 プレゼンテーション

void toggleFullscreen ()
 フルスクリーンモードとウィンドウモードを切り替える

void forceWindowed ()
 強制的にウィンドウモードにする

bool rebuild ()
 デバイスを再構築します


Static Public Member Functions

GraphicsDevicegetInstance ()
 インスタンス取得


Protected Member Functions

 GraphicsDevice ()
 コンストラクタ

virtual ~GraphicsDevice ()
 デストラクタ

void initializeWindowHandle (HWND windowHandle)
 ウィンドウハンドルの初期化

bool initialize ()
 初期化

bool reset ()
 リセット

void clipCursor ()
 カーソルのクリップ

void cleanup ()
 後始末

Direct3DDevicegetDirect3DDevice ()
 Direct3Dデバイスの取得.

LRESULT windowProcedure (HWND windowHandle, u_int message, WPARAM wParam, LPARAM lParam)
 ウィンドウプロシージャ

void adjustWindowForChange ()
 ウィンドウの調整

void handlePossibleSizeChange ()
 ウィンドウサイズ変更


Friends

class LampGraphics


Detailed Description

グラフィックスデバイス

Definition at line 36 of file GraphicsDevice.h.


Member Function Documentation

void Lamp::GraphicsDevice::clear Color4c  color = Color4c(0, 0, 0, 0),
float  zValue = 1.0f,
u_int  stencilValue = 0
 

クリア

Parameters:
color クリアカラー
zValue Zクリア値
stencilValue ステンシルクリア値

Definition at line 64 of file GraphicsDevice.cpp.

References Lamp::Color4c::getARGB(), Lamp::GraphicsDeviceSettings::getDepthStencilEnabled(), NULL, and u_int.

Referenced by handlePossibleSizeChange().

bool Lamp::GraphicsDevice::getClipCursor  )  [inline]
 

カーソルクリップの取得

Returns:
trueならカーソルがクリップされる

Definition at line 62 of file GraphicsDevice.h.

Direct3DDevice* Lamp::GraphicsDevice::getDirect3DDevice  )  [inline, protected]
 

Direct3Dデバイスの取得.

Returns:
Direct3Dデバイス

Definition at line 144 of file GraphicsDevice.h.

References Direct3DDevice.

Referenced by Lamp::LampGraphics::deviceReset().

GraphicsDevice* Lamp::GraphicsDevice::getInstance  )  [inline, static]
 

インスタンス取得

Returns:
インスタンス

Definition at line 44 of file GraphicsDevice.h.

References Assert, and NULL.

bool Lamp::GraphicsDevice::initialize  )  [protected]
 

初期化

Returns:
成功したらtrueを返す

Definition at line 164 of file GraphicsDevice.cpp.

References adjustWindowForChange(), AssertMessage, Lamp::GraphicsDeviceSettings::buildPresentationParameters(), cleanup(), clipCursor(), Direct3D, DirectXSucceeded, Lamp::GraphicsDeviceInformation::getAdapterOrdinal(), Lamp::VertexProcessingType::getCreateFlag(), Lamp::GraphicsDeviceSettings::getDeviceInformation(), Lamp::GraphicsDeviceInformation::getDeviceType(), Lamp::GraphicsDeviceSettings::getVertexProcessingType(), and u_int.

Referenced by Lamp::LampGraphics::initializeDevice(), and rebuild().

void Lamp::GraphicsDevice::initializeWindowHandle HWND  windowHandle  )  [protected]
 

ウィンドウハンドルの初期化

Parameters:
windowHandle ウィンドウハンドル

Definition at line 153 of file GraphicsDevice.cpp.

Referenced by Lamp::LampGraphics::initializeDevice().

bool Lamp::GraphicsDevice::presentation  ) 
 

プレゼンテーション

Returns:
デバイスがロストしていればtrueを返す

Definition at line 72 of file GraphicsDevice.cpp.

References Lamp::GraphicsDeviceSettings::buildPresentationParameters(), DirectXFailed, ErrorOut, Lamp::GraphicsDeviceSettings::isWindowed(), NULL, and reset().

bool Lamp::GraphicsDevice::rebuild  ) 
 

デバイスを再構築します

Returns:
成功したらtrueを返す

Definition at line 147 of file GraphicsDevice.cpp.

References cleanup(), and initialize().

Referenced by forceWindowed(), and toggleFullscreen().

bool Lamp::GraphicsDevice::reset  )  [protected]
 

リセット

Returns:
成功したらtrueを返す

Definition at line 216 of file GraphicsDevice.cpp.

References clipCursor().

Referenced by handlePossibleSizeChange(), presentation(), and toggleFullscreen().

void Lamp::GraphicsDevice::setClipCursor bool  clipFlag  )  [inline]
 

カーソルクリップの設定

Parameters:
clipFlag trueならカーソルをクリップする

Definition at line 56 of file GraphicsDevice.h.

LRESULT Lamp::GraphicsDevice::windowProcedure HWND  windowHandle,
u_int  message,
WPARAM  wParam,
LPARAM  lParam
[protected]
 

ウィンドウプロシージャ

Parameters:
windowHandle ウィンドウハンドル
message メッセージ
wParam wメッセージパラメータ
lParam lメッセージパラメータ

Definition at line 256 of file GraphicsDevice.cpp.

References handlePossibleSizeChange(), Lamp::GraphicsDeviceSettings::isWindowed(), and NULL.

Referenced by Lamp::LampGraphics::windowProcedure().


The documentation for this class was generated from the following files:
Generated on Wed Mar 16 10:29:46 2005 for Lamp by doxygen 1.3.2