diff --git a/source/IrrlichtDevice.cpp b/source/IrrlichtDevice.cpp index 7f5e5f2a..e6d17979 100644 --- a/source/IrrlichtDevice.cpp +++ b/source/IrrlichtDevice.cpp @@ -390,4 +390,4 @@ bool IrrlichtDevice::Event(IrrlichtLime::Event^ e) return OnEvent(e); } -} // end namespace IrrlichtLime \ No newline at end of file +} // end namespace IrrlichtLime diff --git a/source/IrrlichtDevice.h b/source/IrrlichtDevice.h index dbd88ef4..0ae9d83b 100644 --- a/source/IrrlichtDevice.h +++ b/source/IrrlichtDevice.h @@ -23,6 +23,12 @@ ref class OSOperator; ref class Randomizer; ref class Timer; +/// +/// The Irrlicht device. You can create it with IrrlichtDevice.CreateDevice(). +/// This is the most important class of the Irrlicht Engine. +/// You can access everything in the engine if you have a pointer to an instance of this class. +/// There should be only one instance of this class at any time. +/// public ref class IrrlichtDevice : ReferenceCounted { public: @@ -57,6 +63,12 @@ public ref class IrrlichtDevice : ReferenceCounted void RestoreWindow(); + /// + /// Runs the device. + /// Also increments the virtual timer by calling Timer.Tick(). + /// You can prevent this by calling Timer.Stop(); before and Timer.Start() after calling this method. + /// + /// False if device wants to be deleted. bool Run(); bool SetGammaRamp(float red, float green, float blue, float relativebrightness, float relativecontrast); @@ -66,6 +78,11 @@ public ref class IrrlichtDevice : ReferenceCounted void Sleep(int timeMs, bool pauseTimer); void Sleep(int timeMs); + + /// + /// Cause the device to temporarily pause execution and let other processes run. + /// This should bring down processor usage without major performance loss for Irrlicht. + /// void Yield(); property Video::ColorFormat ColorFormat { Video::ColorFormat get(); }