|
float | SurfaceX (float x) |
| Convert an X position into the same position but on the Surface. TODO: Make this work with scale and rotation. More...
|
|
float | SurfaceY (float y) |
| Convert a Y position into the same position but on the Surface. TODO: Make this work with scale and rotation. More...
|
|
| Surface (int width, int height, Color color=null) |
| Creates a Surface with a specified size. More...
|
|
| Surface (int width, int height) |
| Creates a Surface of a specified size. More...
|
|
| Surface (int size) |
| Creates a Surface of a specified size. More...
|
|
| Surface (int size, Color color) |
| Creates a Surface of a specified size. More...
|
|
void | AddShader (Shader shader) |
| Add a shader to be drawn on the surface. If "Shader" is set, the shader list is ignored. More...
|
|
void | RemoveShader (Shader shader) |
| Remove a shader from the surface. More...
|
|
Shader | PopShader () |
| Remove the top most shader on the list of shaders. More...
|
|
void | Display () |
| Calls the SFML Display function on the internal render texture. Should be used before any sort of rendering, otherwise the texture will be upside down! More...
|
|
void | ClearShaders () |
| Remove all shaders from the surface. More...
|
|
void | SetShader (Shader shader) |
| Replace all shaders with a single shader. This will be ignored if "Shader" is set. More...
|
|
void | Draw (Graphic graphic, float x=0, float y=0) |
| Draws a graphic to this surface. More...
|
|
void | Fill (Color color) |
| Fills the surface with the specified color. More...
|
|
void | Clear () |
| Clears the surface with the fill color. More...
|
|
void | Clear (Color color) |
| Clears the surface with a specified color. More...
|
|
override void | Render (float x=0, float y=0) |
| Draw the Surface. More...
|
|
void | DrawToWindow (Game game) |
| Draw the surface directly to the game window. This will refresh the view, and Display the surface, as well as clear it if AutoClear is true. More...
|
|
void | DrawToWindow () |
| Draw the Surface to the Game window. More...
|
|
void | SetView (float x, float y, float angle=0, float zoom=1f) |
| Set view of the Surface. More...
|
|
Texture | GetTexture () |
| Returns a texture by getting the current render texture. I don't know if this works right yet. More...
|
|
void | SaveToFile (string path="") |
| Saves the next completed render to a file. The supported image formats are bmp, png, tga and jpg. Note that this waits until the end of the game's Render() to actually export, otherwise it will be blank! More...
|
|
void | CameraScene (Scene scene) |
| Matches the view of the surface to the same view of a Scene. More...
|
|
void | CenterCamera (float x, float y) |
| Centers the camera of the surface. More...
|
|
| Image (string source=null) |
| Creates a new Image using a filepath to a texture. More...
|
|
| Image (Texture texture) |
| Creates a new Image using a Texture. More...
|
|
| Image (AtlasTexture texture) |
| Creates a new Image using an AtlasTexture. More...
|
|
| Image (int width, int height) |
| Creates a new Image using a specified width and height. More...
|
|
Transformation | AddTransform (Transformation transform) |
|
Transformation | AddTransform (Vector2 translation, Vector2 scale, Vector2 origin, float rotation) |
|
Transformation | AddTransform () |
|
Transformation | RemoveTransformation (Transformation transform) |
|
Transformation | PopTransformation () |
|
virtual void | ClearShader () |
| Removes the shader from the graphic. More...
|
|
void | SetPosition (float x, float y) |
| Set the position of the Graphic. More...
|
|
void | SetPosition (Graphic g, float offsetX=0, float offsetY=0) |
| Set the position of the Graphic. More...
|
|
void | SetPosition (Vector2 xy) |
| Set the position of the Graphic. More...
|
|
void | SetOrigin (float x, float y) |
| Set the origin of the Graphic. More...
|
|
void | SetOrigin (Vector2 xy) |
| Set the origin of the Graphic. More...
|
|
void | SetTexture (string path) |
| Set the Texture that the Graphic is using (if it is using one.) More...
|
|
void | SetTexture (Texture texture) |
| Set the Texture that the Graphic is using (if it is using one.) More...
|
|
void | SetTexture (AtlasTexture atlasTexture) |
| Set the Texture that the Graphic is using (if it is using one.) More...
|
|
virtual void | Update () |
| Update the graphic. More...
|
|
virtual void | CenterOrigin () |
| Centers the graphic origin. More...
|
|
virtual void | CenterOriginZero () |
| Centers the graphic origin while retaining its relative position. More...
|
|
|
Game | Game [get, set] |
| The reference to the Game using this Surface (if it is the main Surface the game is rendering to!) More...
|
|
float | CameraX [get, set] |
| The camera X for the view of the surface. Note: For the game's main surface, this is controlled by the active Scene. More...
|
|
float | CameraY [get, set] |
| The camera Y for the view of the surface. Note: For the game's main surface, this is controlled by the active Scene. More...
|
|
float | CameraAngle [get, set] |
| The camera angle for the view of the surface. Note: For the game's main surface, this is controlled by the active Scene. More...
|
|
float | CameraZoom [get, set] |
| The camera zoom for the view of the surface. Note: For the game's main surface, this is controlled by the active Scene. More...
|
|
float | CameraWidth [get] |
|
float | CameraHeight [get] |
|
override Texture | Texture [get] |
| The Texture the Surface has rendered to. More...
|
|
override bool | Smooth [get, set] |
| Determines the pixel smoothing for the surface. More...
|
|
Rectangle | ClippingRegion [get, set] |
| Defines which area of the Image to show. More...
|
|
bool | FlippedX [get, set] |
| Flip the texture coordinates on the X axis. More...
|
|
bool | FlippedY [get, set] |
| Flip the texture coordinates on the Y axis. More...
|
|
Color | OutlineColor [get, set] |
| The outline color of the Image (only applies to circles and rectangles.) More...
|
|
float | OutlineThickness [get, set] |
| The outline thickness of the Image (only applies to circles and rectangles.) More...
|
|
Transformation | Transform [get] |
|
float | X [get, set] |
| The X position of the Graphic. More...
|
|
float | Y [get, set] |
| The Y position of the Graphic. More...
|
|
float | ScaleX [get, set] |
| The horizontal scale of the graphic. Used in the final transformation. More...
|
|
float | ScaleY [get, set] |
| The vertical scale of the graphic. Used in the final transformation. More...
|
|
float | Angle [get, set] |
| The angle of rotation of the graphic. Used in the final transformation. More...
|
|
float | OriginX [get, set] |
| The X origin point to scale and rotate the graphic with. Used in the final transformation. More...
|
|
float | OriginY [get, set] |
| The Y origin point to scale and rotate the graphic with. Used in the final transformation. More...
|
|
Color | Color [get, set] |
| The base color of the Graphic. Multiplies the vertices of the graphic by this color. More...
|
|
virtual Texture | Texture [get, set] |
| The texture that the graphic is using. More...
|
|
float | Alpha [get, set] |
| The base transparency of the graphic. A shortcut to access the base color's Alpha. More...
|
|
int | Width [get, set] |
| The width of the Graphic. More...
|
|
int | Height [get, set] |
| The height of the Graphic. More...
|
|
float | ScaledWidth [get, set] |
| The width in pixels of the image after applying the X scale. More...
|
|
float | ScaledHeight [get, set] |
| The height in pixels of the image after applying the Y scale. More...
|
|
virtual bool | Smooth [get, set] |
| Smooth the texture of a sprite image while scaling it. More...
|
|
float | Scroll [get, set] |
| Set both ScrollX and ScrollY. More...
|
|
float | HalfWidth [get] |
| Half of the width. More...
|
|
float | HalfHeight [get] |
| Half of the height. More...
|
|
float | Scale [set] |
| Sets both the ScaleX and ScaleY at the same time. More...
|
|
bool | Repeat [set] |
| Sets both RepeatX and RepeatY at the same time. More...
|
|
float | Shake [set] |
| A shortcut to set both ShakeX and ShakeY. More...
|
|
float | Left [get] |
| The X position of the left side of the Graphic. More...
|
|
float | Top [get] |
| The Y position of the top of the Graphic. More...
|
|
float | Right [get] |
| The X position of the right side of the Graphic. More...
|
|
float | Bottom [get] |
| The Y position of the bottom of the Graphic. More...
|
|
int | TextureLeft [get] |
| The X position of the left of the Texture. More...
|
|
int | TextureRight [get] |
| The X position of the right of the Texture. More...
|
|
int | TextureTop [get] |
| The Y position of the top of the Texture. More...
|
|
int | TextureBottom [get] |
| The Y position of the bottom of the Texture. More...
|
|
|
static Image | CreateRectangle (int width, int height, Color color) |
| Creates a rectangle. More...
|
|
static Image | CreateRectangle (Color color) |
| Creates a rectangle the size of the active Game window. More...
|
|
static Image | CreateRectangle () |
| Creates a simple black rectangle the size of the active Game window. More...
|
|
static Image | CreateRectangle (int width, int height) |
| Creates a rectangle. More...
|
|
static Image | CreateRectangle (int size) |
| Creates a rectangle. More...
|
|
static Image | CreateRectangle (int size, Color color) |
| Creates a rectangle. More...
|
|
static Image | CreateCircle (int radius, Color color) |
| Create a circle. More...
|
|
static Image | CreateCircle (int radius) |
| Create a white circle. More...
|
|
static int | CirclePointCount = 24 |
| The amount of points to use when rendering a circle shape. More...
|
|
override void | TextureChanged () |
|
override void | UpdateDrawable () |
| Updates the internal SFML data for rendering. More...
|
|
void | Append (float x, float y, Color color, float u, float v) |
|
void | Append (float x, float y, Color color=null) |
|
virtual void | SFMLRender (Drawable drawable, float x=0, float y=0) |
|
bool | flipX = false |
|
VertexArray | SFMLVertices = new VertexArray(PrimitiveType.Quads) |
|
Drawable | SFMLDrawable |
|
float | RepeatSizeX |
|
bool | roundRendering = true |
|
bool | Dynamic |
| If true the graphic will always update its drawable. More...
|
|
Graphic that represents a render target. By default the game uses a master surface to render the game to the window. Be aware of graphics card limiations of render textures when creating surfaces.