diff --git a/Raylib-cs/interop/Raylib.cs b/Raylib-cs/interop/Raylib.cs
index ea8a480..432e7bd 100644
--- a/Raylib-cs/interop/Raylib.cs
+++ b/Raylib-cs/interop/Raylib.cs
@@ -360,11 +360,22 @@ namespace Raylib_cs
/// Set shader uniform value
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void SetShaderValue(Shader shader, int locIndex, void* value, ShaderUniformDataType uniformType);
+ public static extern void SetShaderValue(
+ Shader shader,
+ int locIndex,
+ void* value,
+ ShaderUniformDataType uniformType
+ );
/// Set shader uniform value vector
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void SetShaderValueV(Shader shader, int locIndex, void* value, ShaderUniformDataType uniformType, int count);
+ public static extern void SetShaderValueV(
+ Shader shader,
+ int locIndex,
+ void* value,
+ ShaderUniformDataType uniformType,
+ int count
+ );
/// Set shader uniform value (matrix 4x4)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -481,7 +492,9 @@ namespace Raylib_cs
/// Set custom file binary data saver
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void SetSaveFileDataCallback(delegate* unmanaged[Cdecl] callback);
+ public static extern void SetSaveFileDataCallback(
+ delegate* unmanaged[Cdecl] callback
+ );
/// Set custom file text data loader
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -651,11 +664,15 @@ namespace Raylib_cs
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern void SetExitKey(KeyboardKey key);
- /// Get key pressed (keycode), call it multiple times for keys queued, returns 0 when the queue is empty
+ ///
+ /// Get key pressed (keycode), call it multiple times for keys queued, returns 0 when the queue is empty
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern int GetKeyPressed();
- /// Get char pressed (unicode), call it multiple times for chars queued, returns 0 when the queue is empty
+ ///
+ /// Get char pressed (unicode), call it multiple times for chars queued, returns 0 when the queue is empty
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern int GetCharPressed();
@@ -881,12 +898,24 @@ namespace Raylib_cs
/// Draw line using quadratic bezier curves with a control point
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawLineBezierQuad(Vector2 startPos, Vector2 endPos, Vector2 controlPos, float thick, Color color);
+ public static extern void DrawLineBezierQuad(
+ Vector2 startPos,
+ Vector2 endPos,
+ Vector2 controlPos,
+ float thick,
+ Color color
+ );
/// Draw line using cubic bezier curves with 2 control points
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawLineBezierCubic(Vector2 startPos, Vector2 endPos, Vector2 startControlPos, Vector2 endControlPos, float thick, Color color);
-
+ public static extern void DrawLineBezierCubic(
+ Vector2 startPos,
+ Vector2 endPos,
+ Vector2 startControlPos,
+ Vector2 endControlPos,
+ float thick,
+ Color color
+ );
/// Draw lines sequence
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -898,15 +927,35 @@ namespace Raylib_cs
/// Draw a piece of a circle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCircleSector(Vector2 center, float radius, float startAngle, float endAngle, int segments, Color color);
+ public static extern void DrawCircleSector(
+ Vector2 center,
+ float radius,
+ float startAngle,
+ float endAngle,
+ int segments,
+ Color color
+ );
/// Draw circle sector outline
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCircleSectorLines(Vector2 center, float radius, float startAngle, float endAngle, int segments, Color color);
+ public static extern void DrawCircleSectorLines(
+ Vector2 center,
+ float radius,
+ float startAngle,
+ float endAngle,
+ int segments,
+ Color color
+ );
/// Draw a gradient-filled circle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCircleGradient(int centerX, int centerY, float radius, Color color1, Color color2);
+ public static extern void DrawCircleGradient(
+ int centerX,
+ int centerY,
+ float radius,
+ Color color1,
+ Color color2
+ );
/// Draw a color-filled circle (Vector version)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -926,11 +975,27 @@ namespace Raylib_cs
/// Draw ring
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawRing(Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, Color color);
+ public static extern void DrawRing(
+ Vector2 center,
+ float innerRadius,
+ float outerRadius,
+ float startAngle,
+ float endAngle,
+ int segments,
+ Color color
+ );
/// Draw ring outline
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawRingLines(Vector2 center, float innerRadius, float outerRadius, float startAngle, float endAngle, int segments, Color color);
+ public static extern void DrawRingLines(
+ Vector2 center,
+ float innerRadius,
+ float outerRadius,
+ float startAngle,
+ float endAngle,
+ int segments,
+ Color color
+ );
/// Draw a color-filled rectangle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -950,15 +1015,35 @@ namespace Raylib_cs
/// Draw a vertical-gradient-filled rectangle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawRectangleGradientV(int posX, int posY, int width, int height, Color color1, Color color2);
+ public static extern void DrawRectangleGradientV(
+ int posX,
+ int posY,
+ int width,
+ int height,
+ Color color1,
+ Color color2
+ );
/// Draw a horizontal-gradient-filled rectangle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawRectangleGradientH(int posX, int posY, int width, int height, Color color1, Color color2);
+ public static extern void DrawRectangleGradientH(
+ int posX,
+ int posY,
+ int width,
+ int height,
+ Color color1,
+ Color color2
+ );
/// Draw a gradient-filled rectangle with custom vertex colors
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawRectangleGradientEx(Rectangle rec, Color col1, Color col2, Color col3, Color col4);
+ public static extern void DrawRectangleGradientEx(
+ Rectangle rec,
+ Color col1,
+ Color col2,
+ Color col3,
+ Color col4
+ );
/// Draw rectangle outline
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -974,7 +1059,13 @@ namespace Raylib_cs
/// Draw rectangle with rounded edges outline
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawRectangleRoundedLines(Rectangle rec, float roundness, int segments, float lineThick, Color color);
+ public static extern void DrawRectangleRoundedLines(
+ Rectangle rec,
+ float roundness,
+ int segments,
+ float lineThick,
+ Color color
+ );
/// Draw a color-filled triangle (vertex in counter-clockwise order!)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1002,7 +1093,14 @@ namespace Raylib_cs
/// Draw a polygon outline of n sides with extended parameters
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawPolyLinesEx(Vector2 center, int sides, float radius, float rotation, float lineThick, Color color);
+ public static extern void DrawPolyLinesEx(
+ Vector2 center,
+ int sides,
+ float radius,
+ float rotation,
+ float lineThick,
+ Color color
+ );
// Basic shapes collision detection functions
@@ -1012,7 +1110,12 @@ namespace Raylib_cs
/// Check collision between two circles
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern CBool CheckCollisionCircles(Vector2 center1, float radius1, Vector2 center2, float radius2);
+ public static extern CBool CheckCollisionCircles(
+ Vector2 center1,
+ float radius1,
+ Vector2 center2,
+ float radius2
+ );
/// Check collision between circle and rectangle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1034,11 +1137,21 @@ namespace Raylib_cs
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern CBool CheckCollisionPointPoly(Vector2 point, Vector2* points, int pointCount);
- /// Check the collision between two lines defined by two points each, returns collision point by reference
+ ///
+ /// Check the collision between two lines defined by two points each, returns collision point by reference
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern CBool CheckCollisionLines(Vector2 startPos1, Vector2 endPos1, Vector2 startPos2, Vector2 endPos2, Vector2* collisionPoint);
+ public static extern CBool CheckCollisionLines(
+ Vector2 startPos1,
+ Vector2 endPos1,
+ Vector2 startPos2,
+ Vector2 endPos2,
+ Vector2* collisionPoint
+ );
- /// Check if point belongs to line created between two points [p1] and [p2] with defined margin in pixels [threshold]
+ ///
+ /// Check if point belongs to line created between two points [p1] and [p2] with defined margin in pixels [threshold]
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern CBool CheckCollisionPointLine(Vector2 point, Vector2 p1, Vector2 p2, int threshold);
@@ -1060,7 +1173,13 @@ namespace Raylib_cs
/// Load image from RAW file data
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Image LoadImageRaw(sbyte* fileName, int width, int height, PixelFormat format, int headerSize);
+ public static extern Image LoadImageRaw(
+ sbyte* fileName,
+ int width,
+ int height,
+ PixelFormat format,
+ int headerSize
+ );
/// Load image sequence from file (frames appended to image.data)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1111,11 +1230,24 @@ namespace Raylib_cs
/// Generate image: radial gradient
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Image GenImageGradientRadial(int width, int height, float density, Color inner, Color outer);
+ public static extern Image GenImageGradientRadial(
+ int width,
+ int height,
+ float density,
+ Color inner,
+ Color outer
+ );
/// Generate image: checked
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Image GenImageChecked(int width, int height, int checksX, int checksY, Color col1, Color col2);
+ public static extern Image GenImageChecked(
+ int width,
+ int height,
+ int checksX,
+ int checksY,
+ Color col1,
+ Color col2
+ );
/// Generate image: white noise
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1194,7 +1326,14 @@ namespace Raylib_cs
/// Resize canvas and fill with color
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void ImageResizeCanvas(Image* image, int newWidth, int newHeight, int offsetX, int offsetY, Color color);
+ public static extern void ImageResizeCanvas(
+ Image* image,
+ int newWidth,
+ int newHeight,
+ int offsetX,
+ int offsetY,
+ Color color
+ );
/// Generate all mipmap levels for a provided image
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1286,7 +1425,14 @@ namespace Raylib_cs
/// Draw line within an image
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void ImageDrawLine(Image* dst, int startPosX, int startPosY, int endPosX, int endPosY, Color color);
+ public static extern void ImageDrawLine(
+ Image* dst,
+ int startPosX,
+ int startPosY,
+ int endPosX,
+ int endPosY,
+ Color color
+ );
/// Draw line within an image (Vector version)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1310,7 +1456,14 @@ namespace Raylib_cs
/// Draw rectangle within an image
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void ImageDrawRectangle(Image* dst, int posX, int posY, int width, int height, Color color);
+ public static extern void ImageDrawRectangle(
+ Image* dst,
+ int posX,
+ int posY,
+ int width,
+ int height,
+ Color color
+ );
/// Draw rectangle within an image (Vector version)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1334,7 +1487,15 @@ namespace Raylib_cs
/// Draw text (custom sprite font) within an image (destination)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void ImageDrawTextEx(Image* dst, Font font, sbyte* text, Vector2 position, float fontSize, float spacing, Color tint);
+ public static extern void ImageDrawTextEx(
+ Image* dst,
+ Font font,
+ sbyte* text,
+ Vector2 position,
+ float fontSize,
+ float spacing,
+ Color tint
+ );
// Texture loading functions
@@ -1408,7 +1569,13 @@ namespace Raylib_cs
/// Draw a Texture2D with extended parameters
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTextureEx(Texture2D texture, Vector2 position, float rotation, float scale, Color tint);
+ public static extern void DrawTextureEx(
+ Texture2D texture,
+ Vector2 position,
+ float rotation,
+ float scale,
+ Color tint
+ );
/// Draw a part of a texture defined by a rectangle
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1416,11 +1583,25 @@ namespace Raylib_cs
/// Draw a part of a texture defined by a rectangle with 'pro' parameters
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTexturePro(Texture2D texture, Rectangle source, Rectangle dest, Vector2 origin, float rotation, Color tint);
+ public static extern void DrawTexturePro(
+ Texture2D texture,
+ Rectangle source,
+ Rectangle dest,
+ Vector2 origin,
+ float rotation,
+ Color tint
+ );
/// Draws a texture (or part of it) that stretches or shrinks nicely
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTextureNPatch(Texture2D texture, NPatchInfo nPatchInfo, Rectangle dest, Vector2 origin, float rotation, Color tint);
+ public static extern void DrawTextureNPatch(
+ Texture2D texture,
+ NPatchInfo nPatchInfo,
+ Rectangle dest,
+ Vector2 origin,
+ float rotation,
+ Color tint
+ );
// Color/pixel related functions
@@ -1509,7 +1690,14 @@ namespace Raylib_cs
/// Load font from memory buffer, fileType refers to extension: i.e. "ttf"
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Font LoadFontFromMemory(sbyte* fileType, byte* fileData, int dataSize, int fontSize, int* fontChars, int glyphCount);
+ public static extern Font LoadFontFromMemory(
+ sbyte* fileType,
+ byte* fileData,
+ int dataSize,
+ int fontSize,
+ int* fontChars,
+ int glyphCount
+ );
/// Check if a font is ready
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1517,11 +1705,25 @@ namespace Raylib_cs
/// Load font data for further use
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern GlyphInfo* LoadFontData(byte* fileData, int dataSize, int fontSize, int* fontChars, int glyphCount, FontType type);
+ public static extern GlyphInfo* LoadFontData(
+ byte* fileData,
+ int dataSize,
+ int fontSize,
+ int* fontChars,
+ int glyphCount,
+ FontType type
+ );
/// Generate image font atlas using chars info
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Image GenImageFontAtlas(GlyphInfo* chars, Rectangle** recs, int glyphCount, int fontSize, int padding, int packMethod);
+ public static extern Image GenImageFontAtlas(
+ GlyphInfo* chars,
+ Rectangle** recs,
+ int glyphCount,
+ int fontSize,
+ int padding,
+ int packMethod
+ );
/// Unload font chars info data (RAM)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1548,19 +1750,49 @@ namespace Raylib_cs
/// Draw text using font and additional parameters
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTextEx(Font font, sbyte* text, Vector2 position, float fontSize, float spacing, Color tint);
+ public static extern void DrawTextEx(
+ Font font,
+ sbyte* text,
+ Vector2 position,
+ float fontSize,
+ float spacing,
+ Color tint
+ );
/// Draw text using Font and pro parameters (rotation)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTextPro(Font font, sbyte* text, Vector2 position, Vector2 origin, float rotation, float fontSize, float spacing, Color tint);
+ public static extern void DrawTextPro(
+ Font font,
+ sbyte* text,
+ Vector2 position,
+ Vector2 origin,
+ float rotation,
+ float fontSize,
+ float spacing,
+ Color tint
+ );
/// Draw one character (codepoint)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTextCodepoint(Font font, int codepoint, Vector2 position, float fontSize, Color tint);
+ public static extern void DrawTextCodepoint(
+ Font font,
+ int codepoint,
+ Vector2 position,
+ float fontSize,
+ Color tint
+ );
/// Draw multiple characters (codepoint)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawTextCodepoints(Font font, int* codepoints, int count, Vector2 position, float fontSize, float spacing, Color tint);
+ public static extern void DrawTextCodepoints(
+ Font font,
+ int* codepoints,
+ int count,
+ Vector2 position,
+ float fontSize,
+ float spacing,
+ Color tint
+ );
// Text font info functions
@@ -1572,15 +1804,21 @@ namespace Raylib_cs
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern Vector2 MeasureTextEx(Font font, sbyte* text, float fontSize, float spacing);
- /// Get glyph index position in font for a codepoint (unicode character), fallback to '?' if not found
+ ///
+ /// Get glyph index position in font for a codepoint (unicode character), fallback to '?' if not found
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern int GetGlyphIndex(Font font, int character);
- /// Get glyph font info data for a codepoint (unicode character), fallback to '?' if not found
+ ///
+ /// Get glyph font info data for a codepoint (unicode character), fallback to '?' if not found
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern GlyphInfo GetGlyphInfo(Font font, int codepoint);
- /// Get glyph rectangle in font atlas for a codepoint (unicode character), fallback to '?' if not found
+ ///
+ /// Get glyph rectangle in font atlas for a codepoint (unicode character), fallback to '?' if not found
+ ///
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern Rectangle GetGlyphAtlasRec(Font font, int codepoint);
@@ -1704,7 +1942,13 @@ namespace Raylib_cs
/// Draw a circle in 3D world space
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCircle3D(Vector3 center, float radius, Vector3 rotationAxis, float rotationAngle, Color color);
+ public static extern void DrawCircle3D(
+ Vector3 center,
+ float radius,
+ Vector3 rotationAxis,
+ float rotationAngle,
+ Color color
+ );
/// Draw a color-filled triangle (vertex in counter-clockwise order!)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1744,27 +1988,69 @@ namespace Raylib_cs
/// Draw a cylinder/cone
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCylinder(Vector3 position, float radiusTop, float radiusBottom, float height, int slices, Color color);
+ public static extern void DrawCylinder(
+ Vector3 position,
+ float radiusTop,
+ float radiusBottom,
+ float height,
+ int slices,
+ Color color
+ );
/// Draw a cylinder with base at startPos and top at endPos
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCylinderEx(Vector3 startPos, Vector3 endPos, float startRadius, float endRadius, int sides, Color color);
+ public static extern void DrawCylinderEx(
+ Vector3 startPos,
+ Vector3 endPos,
+ float startRadius,
+ float endRadius,
+ int sides,
+ Color color
+ );
/// Draw a cylinder/cone wires
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCylinderWires(Vector3 position, float radiusTop, float radiusBottom, float height, int slices, Color color);
+ public static extern void DrawCylinderWires(
+ Vector3 position,
+ float radiusTop,
+ float radiusBottom,
+ float height,
+ int slices,
+ Color color
+ );
/// Draw a cylinder wires with base at startPos and top at endPos
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCylinderWiresEx(Vector3 startPos, Vector3 endPos, float startRadius, float endRadius, int sides, Color color);
+ public static extern void DrawCylinderWiresEx(
+ Vector3 startPos,
+ Vector3 endPos,
+ float startRadius,
+ float endRadius,
+ int sides,
+ Color color
+ );
/// Draw a capsule with the center of its sphere caps at startPos and endPos
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCapsule(Vector3 startPos, Vector3 endPos, float radius, int slices, int rings, Color color);
+ public static extern void DrawCapsule(
+ Vector3 startPos,
+ Vector3 endPos,
+ float radius,
+ int slices,
+ int rings,
+ Color color
+ );
/// Draw capsule wireframe with the center of its sphere caps at startPos and endPos
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawCapsuleWires(Vector3 startPos, Vector3 endPos, float radius, int slices, int rings, Color color);
+ public static extern void DrawCapsuleWires(
+ Vector3 startPos,
+ Vector3 endPos,
+ float radius,
+ int slices,
+ int rings,
+ Color color
+ );
/// Draw a plane XZ
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1814,7 +2100,14 @@ namespace Raylib_cs
/// Draw a model with extended parameters
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawModelEx(Model model, Vector3 position, Vector3 rotationAxis, float rotationAngle, Vector3 scale, Color tint);
+ public static extern void DrawModelEx(
+ Model model,
+ Vector3 position,
+ Vector3 rotationAxis,
+ float rotationAngle,
+ Vector3 scale,
+ Color tint
+ );
/// Draw a model wires (with texture if set)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1822,7 +2115,14 @@ namespace Raylib_cs
/// Draw a model wires (with texture if set) with extended parameters
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawModelWiresEx(Model model, Vector3 position, Vector3 rotationAxis, float rotationAngle, Vector3 scale, Color tint);
+ public static extern void DrawModelWiresEx(
+ Model model,
+ Vector3 position,
+ Vector3 rotationAxis,
+ float rotationAngle,
+ Vector3 scale,
+ Color tint
+ );
/// Draw bounding box (wires)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -1830,15 +2130,38 @@ namespace Raylib_cs
/// Draw a billboard texture
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawBillboard(Camera3D camera, Texture2D texture, Vector3 center, float size, Color tint);
+ public static extern void DrawBillboard(
+ Camera3D camera,
+ Texture2D texture,
+ Vector3 center,
+ float size,
+ Color tint
+ );
/// Draw a billboard texture defined by source
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawBillboardRec(Camera3D camera, Texture2D texture, Rectangle source, Vector3 position, Vector2 size, Color tint);
+ public static extern void DrawBillboardRec(
+ Camera3D camera,
+ Texture2D texture,
+ Rectangle source,
+ Vector3 position,
+ Vector2 size,
+ Color tint
+ );
/// Draw a billboard texture defined by source and rotation
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DrawBillboardPro(Camera3D camera, Texture2D texture, Rectangle source, Vector3 position, Vector3 up, Vector2 size, Vector2 origin, float rotation, Color tint);
+ public static extern void DrawBillboardPro(
+ Camera3D camera,
+ Texture2D texture,
+ Rectangle source,
+ Vector3 position,
+ Vector3 up,
+ Vector2 size,
+ Vector2 origin,
+ float rotation,
+ Color tint
+ );
// Mesh management functions
@@ -1977,7 +2300,12 @@ namespace Raylib_cs
/// Detect collision between two spheres
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern CBool CheckCollisionSpheres(Vector3 center1, float radius1, Vector3 center2, float radius2);
+ public static extern CBool CheckCollisionSpheres(
+ Vector3 center1,
+ float radius1,
+ Vector3 center2,
+ float radius2
+ );
/// Detect collision between two bounding boxes
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -2264,22 +2592,35 @@ namespace Raylib_cs
/// Audio thread callback to request new data
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void SetAudioStreamCallback(AudioStream stream, delegate* unmanaged[Cdecl] callback);
+ public static extern void SetAudioStreamCallback(
+ AudioStream stream,
+ delegate* unmanaged[Cdecl] callback
+ );
/// Attach audio stream processor to stream
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void AttachAudioStreamProcessor(AudioStream stream, delegate* unmanaged[Cdecl] processor);
+ public static extern void AttachAudioStreamProcessor(
+ AudioStream stream,
+ delegate* unmanaged[Cdecl] processor
+ );
/// Detach audio stream processor from stream
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DetachAudioStreamProcessor(AudioStream stream, delegate* unmanaged[Cdecl] processor);
+ public static extern void DetachAudioStreamProcessor(
+ AudioStream stream,
+ delegate* unmanaged[Cdecl] processor
+ );
/// Attach audio stream processor to the entire audio pipeline
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void AttachAudioMixedProcessor(delegate* unmanaged[Cdecl] processor);
+ public static extern void AttachAudioMixedProcessor(
+ delegate* unmanaged[Cdecl] processor
+ );
/// Detach audio stream processor from the entire audio pipeline
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void DetachAudioMixedProcessor(delegate* unmanaged[Cdecl] processor);
+ public static extern void DetachAudioMixedProcessor(
+ delegate* unmanaged[Cdecl] processor
+ );
}
}
diff --git a/Raylib-cs/interop/Raymath.cs b/Raylib-cs/interop/Raymath.cs
index dc3ba49..85e0609 100644
--- a/Raylib-cs/interop/Raymath.cs
+++ b/Raylib-cs/interop/Raymath.cs
@@ -37,7 +37,13 @@ namespace Raylib_cs
/// Remap input value within input range to output range
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern float Remap(float value, float inputStart, float inputEnd, float outputStart, float outputEnd);
+ public static extern float Remap(
+ float value,
+ float inputStart,
+ float inputEnd,
+ float outputStart,
+ float outputEnd
+ );
/// Wrap input value from min to max
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -398,7 +404,14 @@ namespace Raylib_cs
/// Get perspective projection matrix
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Matrix4x4 MatrixFrustum(double left, double right, double bottom, double top, double near, double far);
+ public static extern Matrix4x4 MatrixFrustum(
+ double left,
+ double right,
+ double bottom,
+ double top,
+ double near,
+ double far
+ );
///
/// Get perspective projection matrix
@@ -409,7 +422,14 @@ namespace Raylib_cs
/// Get orthographic projection matrix
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern Matrix4x4 MatrixOrtho(double left, double right, double bottom, double top, double near, double far);
+ public static extern Matrix4x4 MatrixOrtho(
+ double left,
+ double right,
+ double bottom,
+ double top,
+ double near,
+ double far
+ );
/// Get camera look-at matrix (view matrix)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
diff --git a/Raylib-cs/interop/Rlgl.cs b/Raylib-cs/interop/Rlgl.cs
index 79286bd..4203833 100644
--- a/Raylib-cs/interop/Rlgl.cs
+++ b/Raylib-cs/interop/Rlgl.cs
@@ -140,10 +140,24 @@ namespace Raylib_cs
}
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlFrustum(double left, double right, double bottom, double top, double znear, double zfar);
+ public static extern void rlFrustum(
+ double left,
+ double right,
+ double bottom,
+ double top,
+ double znear,
+ double zfar
+ );
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlOrtho(double left, double right, double bottom, double top, double znear, double zfar);
+ public static extern void rlOrtho(
+ double left,
+ double right,
+ double bottom,
+ double top,
+ double znear,
+ double zfar
+ );
/// Set the viewport area
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -415,7 +429,14 @@ namespace Raylib_cs
/// Set blending mode factors and equations separately (using OpenGL factors)
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlSetBlendFactorsSeparate(int glSrcRGB, int glDstRGB, int glSrcAlpha, int glDstAlpha, int glEqRGB, int glEqAlpha);
+ public static extern void rlSetBlendFactorsSeparate(
+ int glSrcRGB,
+ int glDstRGB,
+ int glSrcAlpha,
+ int glDstAlpha,
+ int glEqRGB,
+ int glEqAlpha
+ );
// ------------------------------------------------------------------------------------
@@ -520,7 +541,14 @@ namespace Raylib_cs
public static extern void rlUnloadVertexBuffer(uint vboId);
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlSetVertexAttribute(uint index, int compSize, int type, CBool normalized, int stride, void* pointer);
+ public static extern void rlSetVertexAttribute(
+ uint index,
+ int compSize,
+ int type,
+ CBool normalized,
+ int stride,
+ void* pointer
+ );
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
public static extern void rlSetVertexAttributeDivisor(uint index, int divisor);
@@ -539,7 +567,12 @@ namespace Raylib_cs
public static extern void rlDrawVertexArrayInstanced(int offset, int count, int instances);
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlDrawVertexArrayElementsInstanced(int offset, int count, void* buffer, int instances);
+ public static extern void rlDrawVertexArrayElementsInstanced(
+ int offset,
+ int count,
+ void* buffer,
+ int instances
+ );
// Textures data management
@@ -558,11 +591,24 @@ namespace Raylib_cs
/// Update GPU texture with new data
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlUpdateTexture(uint id, int offsetX, int offsetY, int width, int height, PixelFormat format, void* data);
+ public static extern void rlUpdateTexture(
+ uint id,
+ int offsetX,
+ int offsetY,
+ int width,
+ int height,
+ PixelFormat format,
+ void* data
+ );
/// Get OpenGL internal formats
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlGetGlTextureFormats(PixelFormat format, int* glInternalFormat, int* glFormat, int* glType);
+ public static extern void rlGetGlTextureFormats(
+ PixelFormat format,
+ int* glInternalFormat,
+ int* glFormat,
+ int* glType
+ );
/// Get OpenGL internal formats
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -593,7 +639,13 @@ namespace Raylib_cs
/// Attach texture/renderbuffer to a framebuffer
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlFramebufferAttach(uint fboId, uint texId, FramebufferAttachType attachType, FramebufferAttachTextureType texType, int mipLevel);
+ public static extern void rlFramebufferAttach(
+ uint fboId,
+ uint texId,
+ FramebufferAttachType attachType,
+ FramebufferAttachTextureType texType,
+ int mipLevel
+ );
/// Verify framebuffer is complete
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
@@ -683,7 +735,13 @@ namespace Raylib_cs
/// Copy SSBO data between buffers
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
- public static extern void rlCopyShaderBuffer(uint destId, uint srcId, uint destOffset, uint srcOffset, uint count);
+ public static extern void rlCopyShaderBuffer(
+ uint destId,
+ uint srcId,
+ uint destOffset,
+ uint srcOffset,
+ uint count
+ );
/// Get SSBO buffer size
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
diff --git a/Raylib-cs/types/Input.cs b/Raylib-cs/types/Input.cs
index 3b0f654..c5d254f 100644
--- a/Raylib-cs/types/Input.cs
+++ b/Raylib-cs/types/Input.cs
@@ -332,12 +332,12 @@ namespace Raylib_cs
/// Gamepad top/back trigger left (second), it could be a trailing button
///
GAMEPAD_BUTTON_LEFT_TRIGGER_2,
-
+
///
/// Gamepad top/back trigger right (first), it could be a trailing button
///
GAMEPAD_BUTTON_RIGHT_TRIGGER_1,
-
+
///
/// Gamepad top/back trigger right (second), it could be a trailing button
///
diff --git a/Raylib-cs/types/Raylib.Utils.cs b/Raylib-cs/types/Raylib.Utils.cs
index 897c97e..90728f5 100644
--- a/Raylib-cs/types/Raylib.Utils.cs
+++ b/Raylib-cs/types/Raylib.Utils.cs
@@ -137,43 +137,61 @@ namespace Raylib_cs
}
/// Set shader uniform value vector
- public static void SetShaderValueV(Shader shader, int uniformLoc, T[] values, ShaderUniformDataType uniformType, int count)
- where T : unmanaged
+ public static void SetShaderValueV(
+ Shader shader,
+ int locIndex,
+ T[] values,
+ ShaderUniformDataType uniformType,
+ int count
+ ) where T : unmanaged
{
- SetShaderValueV(shader, uniformLoc, (Span)values, uniformType, count);
+ SetShaderValueV(shader, locIndex, (Span)values, uniformType, count);
}
/// Set shader uniform value vector
- public static void SetShaderValueV(Shader shader, int uniformLoc, Span values, ShaderUniformDataType uniformType, int count)
- where T : unmanaged
+ public static void SetShaderValueV(
+ Shader shader,
+ int locIndex,
+ Span values,
+ ShaderUniformDataType uniformType,
+ int count
+ ) where T : unmanaged
{
fixed (T* valuePtr = values)
{
- SetShaderValueV(shader, uniformLoc, valuePtr, uniformType, count);
+ SetShaderValueV(shader, locIndex, valuePtr, uniformType, count);
}
}
/// Set shader uniform value
- public static void SetShaderValue(Shader shader, int uniformLoc, T value, ShaderUniformDataType uniformType)
+ public static void SetShaderValue(Shader shader, int locIndex, T value, ShaderUniformDataType uniformType)
where T : unmanaged
{
- SetShaderValue(shader, uniformLoc, &value, uniformType);
+ SetShaderValue(shader, locIndex, &value, uniformType);
}
/// Set shader uniform value
- public static void SetShaderValue(Shader shader, int uniformLoc, T[] values, ShaderUniformDataType uniformType)
- where T : unmanaged
+ public static void SetShaderValue(
+ Shader shader,
+ int locIndex,
+ T[] values,
+ ShaderUniformDataType uniformType
+ ) where T : unmanaged
{
- SetShaderValue(shader, uniformLoc, (Span)values, uniformType);
+ SetShaderValue(shader, locIndex, (Span)values, uniformType);
}
/// Set shader uniform value
- public static void SetShaderValue(Shader shader, int uniformLoc, Span values, ShaderUniformDataType uniformType)
- where T : unmanaged
+ public static void SetShaderValue(
+ Shader shader,
+ int locIndex,
+ Span values,
+ ShaderUniformDataType uniformType
+ ) where T : unmanaged
{
fixed (T* valuePtr = values)
{
- SetShaderValue(shader, uniformLoc, valuePtr, uniformType);
+ SetShaderValue(shader, locIndex, valuePtr, uniformType);
}
}
@@ -217,8 +235,16 @@ namespace Raylib_cs
}
}
- /// Check the collision between two lines defined by two points each, returns collision point by reference
- public static CBool CheckCollisionLines(Vector2 startPos1, Vector2 endPos1, Vector2 startPos2, Vector2 endPos2, ref Vector2 collisionPoint)
+ ///
+ /// Check the collision between two lines defined by two points each, returns collision point by reference
+ ///
+ public static CBool CheckCollisionLines(
+ Vector2 startPos1,
+ Vector2 endPos1,
+ Vector2 startPos2,
+ Vector2 endPos2,
+ ref Vector2 collisionPoint
+ )
{
fixed (Vector2* p = &collisionPoint)
{
@@ -322,7 +348,14 @@ namespace Raylib_cs
}
/// Resize canvas and fill with color
- public static void ImageResizeCanvas(ref Image image, int newWidth, int newHeight, int offsetX, int offsetY, Color color)
+ public static void ImageResizeCanvas(
+ ref Image image,
+ int newWidth,
+ int newHeight,
+ int offsetX,
+ int offsetY,
+ Color color
+ )
{
fixed (Image* p = &image)
{
@@ -466,7 +499,14 @@ namespace Raylib_cs
}
/// Draw line within an image
- public static void ImageDrawLine(ref Image dst, int startPosX, int startPosY, int endPosX, int endPosY, Color color)
+ public static void ImageDrawLine(
+ ref Image dst,
+ int startPosX,
+ int startPosY,
+ int endPosX,
+ int endPosY,
+ Color color
+ )
{
fixed (Image* p = &dst)
{
@@ -557,7 +597,15 @@ namespace Raylib_cs
}
/// Draw text (custom sprite font) within an image (destination)
- public static void ImageDrawTextEx(ref Image dst, Font font, string text, Vector2 position, int fontSize, float spacing, Color color)
+ public static void ImageDrawTextEx(
+ ref Image dst,
+ Font font,
+ string text,
+ Vector2 position,
+ int fontSize,
+ float spacing,
+ Color color
+ )
{
using var str1 = text.ToUTF8Buffer();
fixed (Image* p = &dst)
@@ -714,14 +762,30 @@ namespace Raylib_cs
}
/// Draw text using font and additional parameters
- public static void DrawTextEx(Font font, string text, Vector2 position, float fontSize, float spacing, Color tint)
+ public static void DrawTextEx(
+ Font font,
+ string text,
+ Vector2 position,
+ float fontSize,
+ float spacing,
+ Color tint
+ )
{
using var str1 = text.ToUTF8Buffer();
DrawTextEx(font, str1.AsPointer(), position, fontSize, spacing, tint);
}
/// Draw text using Font and pro parameters (rotation)
- public static void DrawTextPro(Font font, string text, Vector2 position, Vector2 origin, float rotation, float fontSize, float spacing, Color tint)
+ public static void DrawTextPro(
+ Font font,
+ string text,
+ Vector2 position,
+ Vector2 origin,
+ float rotation,
+ float fontSize,
+ float spacing,
+ Color tint
+ )
{
using var str1 = text.ToUTF8Buffer();
DrawTextPro(font, str1.AsPointer(), position, origin, rotation, fontSize, spacing, tint);
@@ -898,7 +962,12 @@ namespace Raylib_cs
return model.materials[materialIndex].maps[(int)mapIndex].texture;
}
- public static void SetMaterialTexture(ref Model model, int materialIndex, MaterialMapIndex mapIndex, ref Texture2D texture)
+ public static void SetMaterialTexture(
+ ref Model model,
+ int materialIndex,
+ MaterialMapIndex mapIndex,
+ ref Texture2D texture
+ )
{
SetMaterialTexture(&model.materials[materialIndex], mapIndex, texture);
}