Provides central control for 3D rendering, sound management, asset caching, etc.
More...
|
| Engine (Control target, EngineConfig config) |
| Initializes the Engine and its components. More...
|
|
void | Screenshot (string filename) |
| Saves the current screen at it's current resolution More...
|
|
void | Screenshot (string filename, int width, int height) |
| Saves the current screen at a scaled resolution as JPG More...
|
|
void | Screenshot (string filename, Size size) |
| Saves the current screen at a scaled resolution More...
|
|
void | Debug () |
| Displays a debug interface for the engine, allowing easy manipulation of Views, Renderable, etc. More...
|
|
void | DebugClose () |
| Closes the windows displayed by Debug More...
|
|
void | Render () |
| Renders all Views. Tracks elapsed game time automatically. More...
|
|
void | Render (double elapsedGameTime, bool noPresent=false) |
| Renders all Views. Uses external game time tracking. More...
|
|
void | Dispose () |
|
|
static Version | Version => Assembly.GetExecutingAssembly().GetName().Version |
| The version number of the engine. More...
|
|
Provides central control for 3D rendering, sound management, asset caching, etc.
◆ Engine()
OmegaEngine.Engine.Engine |
( |
Control |
target, |
|
|
EngineConfig |
config |
|
) |
| |
|
inline |
Initializes the Engine and its components.
- Parameters
-
target | The System.Windows.Forms.Control the engine should draw onto. |
config | Settings for initializing the engine. |
- Exceptions
-
NotSupportedException | The graphics card does not meet the engine's minimum requirements. |
Direct3D9NotFoundException | Throw if required DirectX version is missing. |
Direct3DX9NotFoundException | Throw if required DirectX version is missing. |
Direct3D9Exception | internal errors occurred while intiliazing the graphics card. |
SlimDX.DirectSound.DirectSoundException | internal errors occurred while intiliazing the sound card. |
◆ Debug()
void OmegaEngine.Engine.Debug |
( |
| ) |
|
|
inline |
Displays a debug interface for the engine, allowing easy manipulation of Views, Renderable, etc.
◆ DebugClose()
void OmegaEngine.Engine.DebugClose |
( |
| ) |
|
|
inline |
Closes the windows displayed by Debug
◆ OnDispose()
override void OmegaEngine.Engine.OnDispose |
( |
| ) |
|
|
inlineprotectedvirtual |
◆ Render() [1/2]
void OmegaEngine.Engine.Render |
( |
| ) |
|
|
inline |
Renders all Views. Tracks elapsed game time automatically.
◆ Render() [2/2]
void OmegaEngine.Engine.Render |
( |
double |
elapsedGameTime, |
|
|
bool |
noPresent = false |
|
) |
| |
|
inline |
Renders all Views. Uses external game time tracking.
- Parameters
-
elapsedGameTime | How many seconds of game time have elapsed since the last frame was drawn. |
noPresent | true to supress actually displaying the render output at the end. |
◆ Screenshot() [1/3]
void OmegaEngine.Engine.Screenshot |
( |
string |
filename | ) |
|
|
inline |
Saves the current screen at it's current resolution
- Parameters
-
filename | The file name to save the screenshot too |
◆ Screenshot() [2/3]
void OmegaEngine.Engine.Screenshot |
( |
string |
filename, |
|
|
int |
width, |
|
|
int |
height |
|
) |
| |
|
inline |
Saves the current screen at a scaled resolution as JPG
- Parameters
-
filename | The file name to save the screenshot too |
width | The width to scale the resolution down too |
height | The height to scale the resolution down too |
◆ Screenshot() [3/3]
void OmegaEngine.Engine.Screenshot |
( |
string |
filename, |
|
|
Size |
size |
|
) |
| |
|
inline |
Saves the current screen at a scaled resolution
- Parameters
-
filename | The file name to save the screenshot too |
size | The size to scale the resolution down too |
◆ Version
Version OmegaEngine.Engine.Version => Assembly.GetExecutingAssembly().GetName().Version |
|
static |
The version number of the engine.
◆ Views
ICollection<View> OmegaEngine.Engine.Views => _views |
◆ Anisotropic
bool OmegaEngine.Engine.Anisotropic |
|
getset |
Use anisotropic texture filtering
- See also
- EngineCapabilities.Anisotropic
◆ AudioDevice
DirectSound OmegaEngine.Engine.AudioDevice |
|
get |
◆ Cache
The central cache used for all graphics and sound assets.
◆ Capabilities
Methods for determining the rendering capabilities of the graphics hardware.
◆ Config
The settings the engine was initialized with.
Changing this will cause the engine to reset on the next Render() call
◆ DefaultShader
A shader used for default lighting
◆ Device
Device OmegaEngine.Engine.Device |
|
get |
The Direct3D device. Use State instead of manipulating this directly when possible.
◆ Effects
Turn specific rendering effects in the engine on or off.
◆ FadeExtra
bool OmegaEngine.Engine.FadeExtra |
|
getset |
◆ FadeLevel
int OmegaEngine.Engine.FadeLevel |
|
getset |
The level of scene fading from 0 (fully visible) to 255 (invisible).
◆ LastFrameGameTime
double OmegaEngine.Engine.LastFrameGameTime |
|
get |
How many seconds of game time have elapsed since the last frame started drawing.
◆ Music
Controls the playback of music (theme-selection, cross-fading, etc.)
◆ NeedsReset
bool OmegaEngine.Engine.NeedsReset |
|
get |
The engine will be reset on the next Render() call
Do not try to add new assets while this is true!
Just run Render() to fix the problem.
◆ Performance
Tracks the performance/speed of the engine.
◆ RenderSize
Size OmegaEngine.Engine.RenderSize |
|
getset |
The size of the render target
◆ RenderViewport
Viewport OmegaEngine.Engine.RenderViewport |
|
get |
The viewport for the render target
◆ ResourceCulture
CultureInfo OmegaEngine.Engine.ResourceCulture |
|
staticgetset |
The culture used for loading the assembly resources.
◆ ShaderDir
string OmegaEngine.Engine.ShaderDir |
|
get |
The base directory where shader files are stored
◆ State
Used by Renderable implementations to manipulate the graphics render state. Should not be manipulated manually.
◆ Target
Control OmegaEngine.Engine.Target |
|
get |
The System.Windows.Forms.Control the engine draws onto.
◆ TotalGameTime
double OmegaEngine.Engine.TotalGameTime |
|
get |
How many seconds of game time have elapsed in total.
◆ DeviceLost
Action OmegaEngine.Engine.DeviceLost |
Occurs after the Device was lost. This usually happens when switching to or from fullscreen mode.
◆ DeviceReset
Action OmegaEngine.Engine.DeviceReset |
Occurs after the Device was reset. This needs to be done to continue using it after DeviceLost.
◆ ExtraRender
Action OmegaEngine.Engine.ExtraRender |
Allows the integration of external render processes at the end of the Engine's presentation scheme.
◆ PostRender
Action OmegaEngine.Engine.PostRender |
Occurs once for every frame after rendering
◆ PreRender
Action OmegaEngine.Engine.PreRender |
Occurs once for every frame before rendering.
The documentation for this class was generated from the following files:
- OmegaEngine/Engine.Audio.cs
- OmegaEngine/Engine.cs
- OmegaEngine/Engine.Debug.cs
- OmegaEngine/Engine.Render.cs
- OmegaEngine/Engine.Terrain.cs