This commit is contained in:
nub31
2025-10-20 18:32:27 +02:00
parent 78441549c7
commit 5be9f122e9
5 changed files with 28 additions and 379 deletions

View File

@@ -1,10 +1,5 @@
module "raylib"
export struct Vector2
{
x: f32
y: f32
}
export struct Vector2
{
x: f32
@@ -16,19 +11,6 @@ export struct Vector3
y: f32
z: f32
}
export struct Vector3
{
x: f32
y: f32
z: f32
}
export struct Vector4
{
x: f32
y: f32
z: f32
w: f32
}
export struct Vector4
{
x: f32
@@ -55,32 +37,6 @@ export struct Matrix
m11: f32
m15: f32
}
export struct Matrix
{
m0: f32
m4: f32
m8: f32
m12: f32
m1: f32
m5: f32
m9: f32
m13: f32
m2: f32
m6: f32
m10: f32
m14: f32
m3: f32
m7: f32
m11: f32
m15: f32
}
export struct Color
{
r: u8
g: u8
b: u8
a: u8
}
export struct Color
{
r: u8
@@ -95,13 +51,6 @@ export struct Rectangle
width: f32
height: f32
}
export struct Rectangle
{
x: f32
y: f32
width: f32
height: f32
}
export struct Image
{
data: ^void
@@ -110,22 +59,6 @@ export struct Image
mipmaps: i32
format: i32
}
export struct Image
{
data: ^void
width: i32
height: i32
mipmaps: i32
format: i32
}
export struct Texture
{
id: u32
width: i32
height: i32
mipmaps: i32
format: i32
}
export struct Texture
{
id: u32
@@ -140,12 +73,6 @@ export struct RenderTexture
texture: Texture
depth: Texture
}
export struct RenderTexture
{
id: u32
texture: Texture
depth: Texture
}
export struct NPatchInfo
{
source: Rectangle
@@ -155,23 +82,6 @@ export struct NPatchInfo
bottom: i32
layout: i32
}
export struct NPatchInfo
{
source: Rectangle
left: i32
top: i32
right: i32
bottom: i32
layout: i32
}
export struct GlyphInfo
{
value: i32
offsetX: i32
offsetY: i32
advanceX: i32
image: Image
}
export struct GlyphInfo
{
value: i32
@@ -189,15 +99,6 @@ export struct Font
recs: ^Rectangle
glyphs: ^GlyphInfo
}
export struct Font
{
baseSize: i32
glyphCount: i32
glyphPadding: i32
texture: Texture
recs: ^Rectangle
glyphs: ^GlyphInfo
}
export struct Camera3D
{
position: Vector3
@@ -206,21 +107,6 @@ export struct Camera3D
fovy: f32
projection: i32
}
export struct Camera3D
{
position: Vector3
target: Vector3
up: Vector3
fovy: f32
projection: i32
}
export struct Camera2D
{
offset: Vector2
target: Vector2
rotation: f32
zoom: f32
}
export struct Camera2D
{
offset: Vector2
@@ -248,42 +134,11 @@ export struct Mesh
vaoId: u32
vboId: ^u32
}
export struct Mesh
{
vertexCount: i32
triangleCount: i32
vertices: ^f32
texcoords: ^f32
texcoords2: ^f32
normals: ^f32
tangents: ^f32
colors: ^u8
indices: ^u16
animVertices: ^f32
animNormals: ^f32
boneIds: ^u8
boneWeights: ^f32
boneMatrices: ^Matrix
boneCount: i32
vaoId: u32
vboId: ^u32
}
export struct Shader
{
id: u32
locs: ^i32
}
export struct Shader
{
id: u32
locs: ^i32
}
export struct MaterialMap
{
texture: Texture
color: Color
value: f32
}
export struct MaterialMap
{
texture: Texture
@@ -296,18 +151,6 @@ export struct Material
maps: ^MaterialMap
params: [4]f32
}
export struct Material
{
shader: Shader
maps: ^MaterialMap
params: [4]f32
}
export struct Transform
{
translation: Vector3
rotation: Vector4
scale: Vector3
}
export struct Transform
{
translation: Vector3
@@ -319,23 +162,6 @@ export struct BoneInfo
name: [32]i8
parent: i32
}
export struct BoneInfo
{
name: [32]i8
parent: i32
}
export struct Model
{
transform: Matrix
meshCount: i32
materialCount: i32
meshes: ^Mesh
materials: ^Material
meshMaterial: ^i32
boneCount: i32
bones: ^BoneInfo
bindPose: ^Transform
}
export struct Model
{
transform: Matrix
@@ -356,19 +182,6 @@ export struct ModelAnimation
framePoses: ^^Transform
name: [32]i8
}
export struct ModelAnimation
{
boneCount: i32
frameCount: i32
bones: ^BoneInfo
framePoses: ^^Transform
name: [32]i8
}
export struct Ray
{
position: Vector3
direction: Vector3
}
export struct Ray
{
position: Vector3
@@ -381,18 +194,6 @@ export struct RayCollision
point: Vector3
normal: Vector3
}
export struct RayCollision
{
hit: bool
distance: f32
point: Vector3
normal: Vector3
}
export struct BoundingBox
{
min: Vector3
max: Vector3
}
export struct BoundingBox
{
min: Vector3
@@ -406,41 +207,14 @@ export struct Wave
channels: u32
data: ^void
}
export struct Wave
{
frameCount: u32
sampleRate: u32
sampleSize: u32
channels: u32
data: ^void
}
export struct rAudioBuffer
{
}
export struct rAudioProcessor
{
}
export struct AudioStream
{
buffer: ^rAudioBuffer
processor: ^rAudioProcessor
buffer: ^void
processor: ^void
sampleRate: u32
sampleSize: u32
channels: u32
}
export struct AudioStream
{
buffer: ^rAudioBuffer
processor: ^rAudioProcessor
sampleRate: u32
sampleSize: u32
channels: u32
}
export struct Sound
{
stream: AudioStream
frameCount: u32
}
export struct Sound
{
stream: AudioStream
@@ -454,26 +228,6 @@ export struct Music
ctxType: i32
ctxData: ^void
}
export struct Music
{
stream: AudioStream
frameCount: u32
looping: bool
ctxType: i32
ctxData: ^void
}
export struct VrDeviceInfo
{
hResolution: i32
vResolution: i32
hScreenSize: f32
vScreenSize: f32
eyeToScreenDistance: f32
lensSeparationDistance: f32
interpupillaryDistance: f32
lensDistortionValues: [4]f32
chromaAbCorrection: [4]f32
}
export struct VrDeviceInfo
{
hResolution: i32
@@ -497,23 +251,6 @@ export struct VrStereoConfig
scale: [2]f32
scaleIn: [2]f32
}
export struct VrStereoConfig
{
projection: [2]Matrix
viewOffset: [2]Matrix
leftLensCenter: [2]f32
rightLensCenter: [2]f32
leftScreenCenter: [2]f32
rightScreenCenter: [2]f32
scale: [2]f32
scaleIn: [2]f32
}
export struct FilePathList
{
capacity: u32
count: u32
paths: ^cstring
}
export struct FilePathList
{
capacity: u32
@@ -526,18 +263,6 @@ export struct AutomationEvent
type: u32
params: [4]i32
}
export struct AutomationEvent
{
frame: u32
type: u32
params: [4]i32
}
export struct AutomationEventList
{
capacity: u32
count: u32
events: ^AutomationEvent
}
export struct AutomationEventList
{
capacity: u32

View File

@@ -1,10 +1,5 @@
module "raymath"
export struct Vector2
{
x: f32
y: f32
}
export struct Vector2
{
x: f32
@@ -16,19 +11,6 @@ export struct Vector3
y: f32
z: f32
}
export struct Vector3
{
x: f32
y: f32
z: f32
}
export struct Vector4
{
x: f32
y: f32
z: f32
w: f32
}
export struct Vector4
{
x: f32
@@ -55,37 +37,10 @@ export struct Matrix
m11: f32
m15: f32
}
export struct Matrix
{
m0: f32
m4: f32
m8: f32
m12: f32
m1: f32
m5: f32
m9: f32
m13: f32
m2: f32
m6: f32
m10: f32
m14: f32
m3: f32
m7: f32
m11: f32
m15: f32
}
export struct float3
{
v: [3]f32
}
export struct float3
{
v: [3]f32
}
export struct float16
{
v: [16]f32
}
export struct float16
{
v: [16]f32

View File

@@ -19,36 +19,6 @@ export struct Matrix
m11: f32
m15: f32
}
export struct Matrix
{
m0: f32
m4: f32
m8: f32
m12: f32
m1: f32
m5: f32
m9: f32
m13: f32
m2: f32
m6: f32
m10: f32
m14: f32
m3: f32
m7: f32
m11: f32
m15: f32
}
export struct rlVertexBuffer
{
elementCount: i32
vertices: ^f32
texcoords: ^f32
normals: ^f32
colors: ^u8
indices: ^u32
vaoId: u32
vboId: [5]u32
}
export struct rlVertexBuffer
{
elementCount: i32
@@ -67,22 +37,6 @@ export struct rlDrawCall
vertexAlignment: i32
textureId: u32
}
export struct rlDrawCall
{
mode: i32
vertexCount: i32
vertexAlignment: i32
textureId: u32
}
export struct rlRenderBatch
{
bufferCount: i32
currentBuffer: i32
vertexBuffer: ^rlVertexBuffer
draws: ^rlDrawCall
drawCounter: i32
currentDepth: f32
}
export struct rlRenderBatch
{
bufferCount: i32