"""
pybind11 example plugin
"""
from __future__ import annotations
import collections.abc
import glm
import typing
import typing_extensions
__all__: list[str] = ['Collider', 'ComputeShader', 'Contact', 'EBO', 'Edges', 'Engine', 'FBO', 'FeaturePair', 'Force', 'Frame', 'GpuBuffer', 'GpuBufferDtype', 'Image', 'Joint', 'Manifold', 'Material', 'Mesh', 'Motor', 'Node', 'Node2D', 'Rigid', 'Scene', 'Shader', 'Solver', 'Spring', 'VAO', 'VBO']


def init_gpu() -> None:
    """Initialize the GPU compute backend (call once at startup)."""
    ...


class GpuBufferDtype:
    U32: int
    F32: int
    I32: int


class GpuBuffer:
    """Single GPU buffer; dtype controls element type ('u32'|'f32'|'i32'), len is element count."""
    def __init__(self, dtype: typing.Union[str, typing.Any], len: int) -> None:
        ...
    def write(self, data: collections.abc.Sequence[typing.Union[int, float]]) -> None:
        ...
    def read(self) -> list[typing.Union[int, float]]:
        ...
    def len(self) -> int:
        ...
    def size_bytes(self) -> int:
        ...
    def element_size(self) -> int:
        ...
    def dtype(self) -> str:
        """Return dtype string: 'u32', 'f32', or 'i32'."""
        ...
    def handle(self) -> int:
        """Return opaque handle for use with ComputeShader buffer_handles."""
        ...


class ComputeShader:
    def __init__(self, wgsl: str, buffer_handles: list[int], uniform_size: int = 0) -> None:
        ...
    def set_uniform_bytes(self, data: typing.Union[bytes, typing_extensions.Buffer]) -> None:
        """Set uniform data from a bytes-like or buffer object."""
        ...
    def dispatch(self, x: int, y: int = 1, z: int = 1) -> None:
        """Dispatch the compute shader with workgroup counts (x, y, z)."""
        ...
class Collider:
    def __init__(self, solver: Solver, vertices: collections.abc.Sequence[glm.vec2]) -> None:
        ...
    def getArea(self) -> float:
        ...
    def getBaseMoment(self) -> float:
        ...
    def getBaseRadius(self) -> float:
        ...
    def getCOM(self) -> glm.vec2:
        ...
    def getGC(self) -> glm.vec2:
        ...
    def getHalfDim(self) -> glm.vec2:
        ...
    def getMass(self, arg0: glm.vec2, arg1: typing.SupportsFloat) -> float:
        ...
    def getMoment(self, arg0: glm.vec2, arg1: typing.SupportsFloat) -> float:
        ...
    def getRadius(self, arg0: glm.vec2) -> float:
        ...
    def getVertices(self) -> list[glm.vec2]:
        ...
    def setArea(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setBaseMoment(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setCOM(self, arg0: glm.vec2) -> None:
        ...
    def setGC(self, arg0: glm.vec2) -> None:
        ...
    def setHalfDim(self, arg0: glm.vec2) -> None:
        ...
    def setVertices(self, arg0: collections.abc.Sequence[glm.vec2]) -> None:
        ...
class Contact:
    C0: glm.vec2
    feature: ...
    normal: glm.vec2
    rA: glm.vec2
    rB: glm.vec2
    stick: bool
class EBO:
    def __init__(self, data: collections.abc.Sequence[typing.SupportsInt], drawType: typing.SupportsInt = 35044) -> None:
        ...
    def bind(self) -> None:
        ...
    def getSize(self) -> int:
        ...
    def unbind(self) -> None:
        ...
    def write(self, data: typing_extensions.CapsuleType, size: typing.SupportsInt, offset: typing.SupportsInt) -> None:
        ...
class Edges:
    inEdge1: str
    inEdge2: str
    outEdge1: str
    outEdge2: str
class Engine:
    def __init__(self, width: typing.SupportsInt, height: typing.SupportsInt, title: str, autoMouseGrab: bool = True) -> None:
        ...
    def getFrame(self) -> ...:
        ...
    def getKeyboard(self) -> ...:
        ...
    def getMouse(self) -> ...:
        ...
    def getResourceServer(self) -> ...:
        ...
    def getWindow(self) -> ...:
        ...
    def isRunning(self) -> bool:
        ...
    def render(self) -> None:
        ...
    def setResolution(self, width: typing.SupportsInt, height: typing.SupportsInt) -> None:
        ...
    def update(self) -> None:
        ...
    def useContext(self) -> None:
        ...
class FBO:
    def __init__(self, width: typing.SupportsInt, height: typing.SupportsInt, components: typing.SupportsInt) -> None:
        ...
    def bind(self) -> None:
        ...
    def clear(self, r: typing.SupportsFloat, g: typing.SupportsFloat, b: typing.SupportsFloat, a: typing.SupportsFloat) -> None:
        ...
    def getDepthID(self) -> int:
        ...
    def getHeight(self) -> int:
        ...
    def getID(self) -> int:
        ...
    def getTextureID(self) -> int:
        ...
    def getWidth(self) -> int:
        ...
    def unbind(self) -> None:
        ...
class FeaturePair:
    e: ...
    @property
    def value(self) -> int:
        ...
    @value.setter
    def value(self, arg0: typing.SupportsInt) -> None:
        ...
class Force:
    def disable(self) -> None:
        ...
    def getBodyA(self) -> Rigid:
        ...
    def getBodyB(self) -> Rigid:
        ...
    def getC(self, arg0: typing.SupportsInt) -> float:
        ...
    def getFmax(self, arg0: typing.SupportsInt) -> float:
        ...
    def getFmin(self, arg0: typing.SupportsInt) -> float:
        ...
    def getFracture(self, arg0: typing.SupportsInt) -> float:
        ...
    def getH(self, arg0: typing.SupportsInt, arg1: Rigid) -> ...:
        ...
    def getJ(self, arg0: typing.SupportsInt, arg1: Rigid) -> glm.vec3:
        ...
    def getLambda(self, arg0: typing.SupportsInt) -> float:
        ...
    def getNext(self) -> Force:
        ...
    def getNextA(self) -> Force:
        ...
    def getNextB(self) -> Force:
        ...
    def getPenalty(self, arg0: typing.SupportsInt) -> float:
        ...
    def getPrev(self) -> Force:
        ...
    def getPrevA(self) -> Force:
        ...
    def getPrevB(self) -> Force:
        ...
    def getSolver(self) -> Solver:
        ...
    def getStiffness(self, arg0: typing.SupportsInt) -> float:
        ...
class Frame:
    def __init__(self, engine: Engine, width: typing.SupportsInt, height: typing.SupportsInt) -> None:
        ...
    def clear(self, r: typing.SupportsFloat, g: typing.SupportsFloat, b: typing.SupportsFloat, a: typing.SupportsFloat) -> None:
        ...
    def getAspectRatio(self) -> float:
        ...
    def getEBO(self) -> EBO:
        ...
    def getFBO(self) -> FBO:
        ...
    def getHeight(self) -> int:
        ...
    def getRenderHeight(self) -> int:
        ...
    def getRenderWidth(self) -> int:
        ...
    def getShader(self) -> Shader:
        ...
    def getVAO(self) -> VAO:
        ...
    def getVBO(self) -> VBO:
        ...
    def getWidth(self) -> int:
        ...
    @typing.overload
    def render(self) -> None:
        ...
    @typing.overload
    def render(self, x: typing.SupportsInt, y: typing.SupportsInt, width: typing.SupportsInt, height: typing.SupportsInt) -> None:
        ...
    def use(self) -> None:
        ...
class Image:
    def __init__(self, file: str) -> None:
        ...
    def getData(self) -> int:
        ...
    def getHeight(self) -> int:
        ...
    def getWidth(self) -> int:
        ...
class Joint(Force):
    def __init__(self, solver: Solver, bodyA: Rigid, bodyB: Rigid, rA: glm.vec2, rB: glm.vec2, stiffness: glm.vec3 = ..., fracture: typing.SupportsFloat = ...) -> None:
        ...
    def getC0(self) -> glm.vec3:
        ...
    def getRA(self) -> glm.vec2:
        ...
    def getRB(self) -> glm.vec2:
        ...
    def getRestAngle(self) -> float:
        ...
    def getTorqueArm(self) -> float:
        ...
    def setC0(self, arg0: glm.vec3) -> None:
        ...
    def setRA(self, arg0: glm.vec2) -> None:
        ...
    def setRB(self, arg0: glm.vec2) -> None:
        ...
    def setRestAngle(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setTorqueArm(self, arg0: typing.SupportsFloat) -> None:
        ...
class Manifold(Force):
    @staticmethod
    def collide(bodyA: Rigid, bodyB: Rigid, contacts: Contact) -> int:
        ...
    def __init__(self, solver: Solver, bodyA: Rigid, bodyB: Rigid) -> None:
        ...
    def getContact(self, arg0: typing.SupportsInt) -> Contact:
        ...
    def getContactRef(self, arg0: typing.SupportsInt) -> Contact:
        ...
    def getFriction(self) -> float:
        ...
    def getNumContacts(self) -> int:
        ...
class Material:
    def __init__(self, color: glm.vec3 = ..., albedo: Image = None, normal: Image = None) -> None:
        ...
    def getAlbedo(self) -> Image:
        ...
    def getColor(self) -> glm.vec3:
        ...
    def getNormal(self) -> Image:
        ...
class Mesh:
    def __init__(self, modelPath: str, generateUV: bool = False, generateNormals: bool = False) -> None:
        ...
    def get_indices(self) -> list[int]:
        ...
    def get_vertices(self) -> list[float]:
        ...
class Motor(Force):
    def __init__(self, solver: Solver, bodyA: Rigid, bodyB: Rigid, speed: typing.SupportsFloat, maxTorque: typing.SupportsFloat) -> None:
        ...
    def getSpeed(self) -> float:
        ...
    def setSpeed(self, arg0: typing.SupportsFloat) -> None:
        ...
class Node:
    @typing.overload
    def __init__(self, scene: Scene, mesh: ... = None, material: ... = None, position: glm.vec3 = ..., rotation: glm.quat = ..., scale: glm.vec3 = ...) -> None:
        ...
    @typing.overload
    def __init__(self, parent: Node, mesh: ... = None, material: ... = None, position: glm.vec3 = ..., rotation: glm.quat = ..., scale: glm.vec3 = ...) -> None:
        ...
    @typing.overload
    def __init__(self, scene: Scene, parent: Node) -> None:
        ...
    def setPosition(self, position: glm.vec3) -> None:
        ...
    def setRotation(self, rotation: glm.quat) -> None:
        ...
    def setScale(self, scale: glm.vec3) -> None:
        ...
class Node2D:
    @typing.overload
    def __init__(self, scene: ..., mesh: Mesh, material: Material, position: glm.vec2, rotation: typing.SupportsFloat, scale: glm.vec2, velocity: glm.vec3, collider: ..., density: typing.SupportsFloat, friction: typing.SupportsFloat) -> None:
        ...
    @typing.overload
    def __init__(self, parent: Node2D, mesh: Mesh, material: Material, position: glm.vec2, rotation: typing.SupportsFloat, scale: glm.vec2, velocity: glm.vec3, collider: ..., density: typing.SupportsFloat, friction: typing.SupportsFloat) -> None:
        ...
    @typing.overload
    def __init__(self, arg0: ..., arg1: Node2D) -> None:
        ...
    @typing.overload
    def setPosition(self, arg0: glm.vec2) -> None:
        ...
    @typing.overload
    def setPosition(self, arg0: glm.vec3) -> None:
        ...
    def setRotation(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setScale(self, arg0: glm.vec2) -> None:
        ...
    def setVelocity(self, arg0: glm.vec3) -> None:
        ...
class Rigid:
    def __init__(self, solver: Solver, node: Node2D, collider: Collider, position: glm.vec3, size: glm.vec2, density: typing.SupportsFloat, friction: typing.SupportsFloat, velocity: glm.vec3) -> None:
        ...
    def constrainedTo(self, arg0: Rigid) -> bool:
        ...
    def getAABB(self) -> tuple[glm.vec2, glm.vec2]:
        ...
    def getCollider(self) -> Collider:
        ...
    def getColor(self) -> int:
        ...
    def getDegree(self) -> int:
        ...
    def getDensity(self) -> float:
        ...
    def getForces(self) -> ...:
        ...
    def getFriction(self) -> float:
        ...
    def getIndex(self) -> int:
        ...
    def getInertial(self) -> glm.vec3:
        ...
    def getInitial(self) -> glm.vec3:
        ...
    def getMass(self) -> float:
        ...
    def getMoment(self) -> float:
        ...
    def getNext(self) -> Rigid:
        ...
    def getNextUnusedColor(self) -> int:
        ...
    def getNode(self) -> Node2D:
        ...
    def getPosition(self) -> glm.vec3:
        ...
    def getPrev(self) -> Rigid:
        ...
    def getPrevVelocity(self) -> glm.vec3:
        ...
    def getRadius(self) -> float:
        ...
    def getSatur(self) -> int:
        ...
    def getSize(self) -> glm.vec2:
        ...
    def getSolver(self) -> Solver:
        ...
    def getVel(self) -> glm.vec3:
        ...
    def getVelocity(self) -> glm.vec3:
        ...
    def incrSatur(self) -> None:
        ...
    def insert(self, arg0: ...) -> None:
        ...
    def isColorUsed(self, arg0: typing.SupportsInt) -> bool:
        ...
    def isColored(self) -> bool:
        ...
    def remove(self, arg0: ...) -> None:
        ...
    def reserveColors(self, arg0: typing.SupportsInt) -> None:
        ...
    def resetColoring(self) -> None:
        ...
    def setCollider(self, arg0: Collider) -> None:
        ...
    def setFriction(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setInertial(self, arg0: glm.vec3) -> None:
        ...
    def setInitial(self, arg0: glm.vec3) -> None:
        ...
    def setMass(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setMoment(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setNode(self, arg0: Node2D) -> None:
        ...
    def setPosition(self, arg0: glm.vec3) -> None:
        ...
    def setPrevVelocity(self, arg0: glm.vec3) -> None:
        ...
    def setRadius(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setScale(self, arg0: glm.vec2) -> None:
        ...
    def setVelocity(self, arg0: glm.vec3) -> None:
        ...
    def useColor(self, arg0: typing.SupportsInt) -> None:
        ...
    def verifyColoring(self) -> bool:
        ...
class Scene:
    def __init__(self, engine: Engine) -> None:
        ...
    def getCamera(self) -> ...:
        ...
    def getShader(self) -> ...:
        ...
    def render(self) -> None:
        ...
    def setCamera(self, camera: ...) -> None:
        ...
    def update(self) -> None:
        ...
class Shader:
    @staticmethod
    @typing.overload
    def setUniform(*args, **kwargs) -> None:
        ...
    def __init__(self, vertexPath: str, fragmentPath: str) -> None:
        ...
    @typing.overload
    def bind(self, name: str, texture: ..., slot: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def bind(self, name: str, textureArray: ..., slot: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def bind(self, name: str, tbo: ..., slot: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def bind(self, name: str, fbo: ..., slot: typing.SupportsInt) -> None:
        ...
    def getAttributes(self) -> ...:
        ...
    def getStride(self) -> int:
        ...
    def getUniformLocation(self, name: str) -> int:
        ...
    @typing.overload
    def setUniform(self, name: str, value: typing.SupportsFloat) -> None:
        ...
    @typing.overload
    def setUniform(self, name: str, value: typing.SupportsFloat) -> None:
        ...
    @typing.overload
    def setUniform(self, name: str, value: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def setUniform(self, name: str, value: glm.vec3) -> None:
        ...
    def use(self) -> None:
        ...
class Solver:
    @staticmethod
    def setGravity(*args, **kwargs) -> None:
        ...
    def __init__(self) -> None:
        ...
    def getAlpha(self) -> float:
        ...
    def getBeta(self) -> float:
        ...
    def getDt(self) -> float:
        ...
    def getGamma(self) -> float:
        ...
    def getGravity(self) -> ...:
        ...
    def getIterations(self) -> int:
        ...
    def getNumForces(self) -> int:
        ...
    def getNumRigids(self) -> int:
        ...
    def getPostStabilize(self) -> bool:
        ...
    @typing.overload
    def insert(self, arg0: ...) -> None:
        ...
    @typing.overload
    def insert(self, arg0: ...) -> None:
        ...
    @typing.overload
    def remove(self, arg0: ...) -> None:
        ...
    @typing.overload
    def remove(self, arg0: ...) -> None:
        ...
    def setAlpha(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setBeta(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setDt(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setGamma(self, arg0: typing.SupportsFloat) -> None:
        ...
    def setIterations(self, arg0: typing.SupportsInt) -> None:
        ...
    def setPostStabilize(self, arg0: bool) -> None:
        ...
class Spring(Force):
    def __init__(self, solver: Solver, bodyA: Rigid, bodyB: Rigid, rA: glm.vec2, rB: glm.vec2, stiffness: typing.SupportsFloat, rest: typing.SupportsFloat = -1.0) -> None:
        ...
    def getRA(self) -> glm.vec2:
        ...
    def getRB(self) -> glm.vec2:
        ...
    def getRest(self) -> float:
        ...
    def setRA(self, arg0: glm.vec2) -> None:
        ...
    def setRB(self, arg0: glm.vec2) -> None:
        ...
    def setRest(self, arg0: typing.SupportsFloat) -> None:
        ...
class VAO:
    def __init__(self, shader: Shader, vertices: VBO, indices: EBO) -> None:
        ...
    def bind(self) -> None:
        ...
    def bindAttribute(self, location: typing.SupportsInt, count: typing.SupportsInt, dataType: typing.SupportsInt, stride: typing.SupportsInt, offset: typing.SupportsInt, divisor: typing.SupportsInt) -> None:
        ...
    def bindAttributes(self, attribs: ..., std: ..., std: ..., std: ..., std: ..., std: ..., divisor: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def bindBuffer(self, buffer: VBO, attribs: ..., std: ..., std: ..., std: ..., std: ..., std: ..., divisor: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def bindBuffer(self, buffer: VBO, indices: EBO, attribs: ..., std: ..., std: ..., std: ..., std: ..., std: ..., divisor: typing.SupportsInt) -> None:
        ...
    def render(self, instanceCount: typing.SupportsInt) -> None:
        ...
class VBO:
    @typing.overload
    def __init__(self, data: typing_extensions.CapsuleType, size: typing.SupportsInt, drawType: typing.SupportsInt) -> None:
        ...
    @typing.overload
    def __init__(self, data: collections.abc.Sequence[typing.SupportsFloat], drawType: typing.SupportsInt = 35044) -> None:
        ...
    def bind(self) -> None:
        ...
    def getSize(self) -> int:
        ...
    def unbind(self) -> None:
        ...
