Popcorning Guinea Pig
Search Results for

    Show / Hide Table of Contents

    Class TilemapRenderer

    Service for rendering tilemaps using Raylib-cs. Provides efficient tilemap rendering with layer support and view culling.

    Inheritance
    object
    TilemapRenderer
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: PopcorningGuineaPig.Engine.Services
    Assembly: PopcorningGuineaPig.Engine.dll
    Syntax
    public class TilemapRenderer

    Methods

    | Edit this page View Source

    RenderDebugInfo(Tilemap, Vector2, bool, bool)

    Renders debug information for a tilemap. Shows tile bounds, layer information, and tileset data.

    Declaration
    public void RenderDebugInfo(Tilemap tilemap, Vector2 position = default, bool showTileBounds = true, bool showLayerInfo = true)
    Parameters
    Type Name Description
    Tilemap tilemap

    Tilemap to debug

    Vector2 position

    World position offset

    bool showTileBounds

    Whether to show individual tile boundaries

    bool showLayerInfo

    Whether to show layer information

    | Edit this page View Source

    RenderLayer(Tilemap, TilemapLayer, int, Vector2, Rectangle?)

    Renders a specific layer of a tilemap.

    Declaration
    public void RenderLayer(Tilemap tilemap, TilemapLayer layer, int layerIndex, Vector2 position = default, Rectangle? viewBounds = null)
    Parameters
    Type Name Description
    Tilemap tilemap

    Tilemap containing the layer

    TilemapLayer layer

    Layer to render

    int layerIndex

    Index of the layer

    Vector2 position

    World position offset

    Rectangle? viewBounds

    Optional view bounds for culling

    | Edit this page View Source

    RenderTile(Tilemap, int, int, int, Vector2, float)

    Renders a single tile at the specified grid coordinates.

    Declaration
    public void RenderTile(Tilemap tilemap, int tileId, int gridX, int gridY, Vector2 position, float opacity = 1)
    Parameters
    Type Name Description
    Tilemap tilemap

    Tilemap containing the tile

    int tileId

    Global tile ID

    int gridX

    Grid X coordinate

    int gridY

    Grid Y coordinate

    Vector2 position

    World position offset

    float opacity

    Layer opacity

    | Edit this page View Source

    RenderTileGridOverlay(TileGrid, Color)

    Renders a tile grid overlay for a tilemap layer. Useful for visualizing the GameTile integration.

    Declaration
    public void RenderTileGridOverlay(TileGrid tileGrid, Color color)
    Parameters
    Type Name Description
    TileGrid tileGrid

    TileGrid to overlay

    Color color

    Color for the grid lines

    | Edit this page View Source

    RenderTilemap(Tilemap, Vector2, Camera2D?)

    Renders a complete tilemap with all visible layers.

    Declaration
    public void RenderTilemap(Tilemap tilemap, Vector2 position = default, Camera2D? camera = null)
    Parameters
    Type Name Description
    Tilemap tilemap

    Tilemap to render

    Vector2 position

    World position offset for the tilemap

    Camera2D? camera

    Optional camera for view culling

    | Edit this page View Source

    RenderTilemapWithTransform(Tilemap, Matrix4x4, Camera2D?)

    Renders a tilemap with a specific transform matrix. Useful for advanced rendering scenarios.

    Declaration
    public void RenderTilemapWithTransform(Tilemap tilemap, Matrix4x4 transform, Camera2D? camera = null)
    Parameters
    Type Name Description
    Tilemap tilemap

    Tilemap to render

    Matrix4x4 transform

    Transform matrix

    Camera2D? camera

    Optional camera for view culling

    • Edit this page
    • View Source
    In this article
    Back to top © 2024 Popcorning Guinea Pig Game Engine. A custom C# game engine for indie developers.