using System;
using System.Collections.Generic;
namespace Orvid.Graphics
{
///
/// This class describes a graphics driver.
///
public abstract class GraphicsDriver
{
///
/// Returns the name of the graphics driver.
///
public abstract string Name { get; }
///
/// Returns the version of the graphics driver.
///
public abstract string Version { get; }
///
/// Returns the company that created the graphics driver.
///
public abstract string Company { get; }
///
/// Returns the author of the graphics driver.
///
public abstract string Author { get; }
///
/// Returns the current graphics mode.
///
public abstract GraphicsMode Mode { get; }
///
/// This method is called to update the entire screen.
///
/// The image to draw.
public abstract void Update(Image i);
///
/// This method is used to get the resolutions the driver supports.
///
/// A list of graphics modes that the driver supports.
public abstract List GetSupportedModes();
///
/// This method is used to set the current graphics mode.
///
/// The mode to set to.
public abstract void SetMode(GraphicsMode mode);
///
/// Returns true if the given graphics mode is supported.
///
/// The mode to check.
/// True if the given mode is supported.
public bool SupportsMode(GraphicsMode mode)
{
return GetSupportedModes().Contains(mode);
}
///
/// This method is used to determine whether or not to load the driver.
///
/// True if the driver is valid for the current system, otherwise false.
public abstract bool Supported();
///
/// This method is called to initialize the graphics
/// driver and tell it we're going to use it.
///
public abstract void Initialize();
///
/// This method is called to tell the driver to shut-down.
///
public abstract void Shutdown();
}
}