[][src]Crate gdnative_common

Re-exports

pub extern crate libc;

Modules

geom

Geometric types.

init

Types and functionalities to declare and initialize gdnative classes.

libc

libc - Raw FFI bindings to platforms' system libraries

sys

Raw C API.

Macros

godot_class

Convenience macro to declare a native class.

godot_error

Print an error using the engine's logging system (visible in the editor).

godot_gdnative_init

Declare the API endpoint to initialize the gdnative API on startup.

godot_gdnative_terminate

Declare the API endpoint invoked during shutdown.

godot_nativescript_init

Declare the API endpoint to initialize nativescript classes on startup.

godot_print

Print a message using the engine's logging system (visible in the editor).

godot_warn

Print a warning using the engine's logging system (visible in the editor).

godot_wrap_constructor

Convenience macro to wrap an object's constructor into a function pointer that can be passed to the engine when registering a class.

godot_wrap_destructor

Convenience macro to wrap an object's destructor into a function pointer that can be passed to the engine when registering a class.

godot_wrap_method

Convenience macro to wrap an object's method into a function pointer that can be passed to the engine when registering a class.

Structs

AStar

core class AStar inherits Reference (reference counted).

Aabb

Axis-aligned bounding box.

AnimatedTexture

core class AnimatedTexture inherits Texture (reference counted).

ArrayMesh

core class ArrayMesh inherits Mesh (reference counted).

AtlasTexture

core class AtlasTexture inherits Texture (reference counted).

BackBufferCopy

core class BackBufferCopy inherits Node2D (unsafe).

Basis

A 3x3 matrix.

BitMap

core class BitMap inherits Resource (reference counted).

BitmapFont

core class BitmapFont inherits Font (reference counted).

BoxShape

core class BoxShape inherits Shape (reference counted).

ByteArray

A reference-counted vector of bytes that uses Godot's pool allocator.

Camera

core class Camera inherits Spatial (unsafe).

Camera2D

core class Camera2D inherits Node2D (unsafe).

CanvasItem

core class CanvasItem inherits Node (unsafe).

CanvasLayer

core class CanvasLayer inherits Node (unsafe).

CanvasModulate

core class CanvasModulate inherits Node2D (unsafe).

CapsuleMesh

core class CapsuleMesh inherits PrimitiveMesh (reference counted).

CapsuleShape

core class CapsuleShape inherits Shape (reference counted).

CapsuleShape2D

core class CapsuleShape2D inherits Shape2D (reference counted).

CircleShape2D

core class CircleShape2D inherits Shape2D (reference counted).

ClassDB

core singleton class ClassDB inherits Object (unsafe).

CollisionPolygon

core class CollisionPolygon inherits Spatial (unsafe).

Color

RGBA color with 32 bits floating point components.

ColorArray

A reference-counted vector of ColorArray that uses Godot's pool allocator.

ConcavePolygonShape

core class ConcavePolygonShape inherits Shape (reference counted).

ConcavePolygonShape2D

core class ConcavePolygonShape2D inherits Shape2D (reference counted).

ConfigFile

core class ConfigFile inherits Reference (reference counted).

ConvexPolygonShape

core class ConvexPolygonShape inherits Shape (reference counted).

ConvexPolygonShape2D

core class ConvexPolygonShape2D inherits Shape2D (reference counted).

CubeMesh

core class CubeMesh inherits PrimitiveMesh (reference counted).

Curve

core class Curve inherits Resource (reference counted).

Curve2D

core class Curve2D inherits Resource (reference counted).

Curve3D

core class Curve3D inherits Resource (reference counted).

CylinderMesh

core class CylinderMesh inherits PrimitiveMesh (reference counted).

CylinderShape

core class CylinderShape inherits Shape (reference counted).

Dictionary

A reference-counted Dictionary of Variant key-value pairs.

Directory

core class Directory inherits Reference (reference counted).

DynamicFont

core class DynamicFont inherits Font (reference counted).

DynamicFontData

core class DynamicFontData inherits Resource (reference counted).

EncodedObjectAsID

core class EncodedObjectAsID inherits Reference (reference counted).

Engine

core singleton class Engine inherits Object (unsafe).

Environment

core class Environment inherits Resource (reference counted).

File

core class File inherits Reference (reference counted).

Float32Array

A reference-counted vector of f32 that uses Godot's pool allocator.

Font

core class Font inherits Resource (reference counted).

FreeOnDrop

A wrapper that automatically frees the object when dropped.

FuncRef

core class FuncRef inherits Reference (reference counted).

GDNative

core class GDNative inherits Reference (reference counted).

GDNativeLibrary

core class GDNativeLibrary inherits Resource (reference counted).

GDScript

core class GDScript inherits Script (reference counted).

GDScriptFunctionState

core class GDScriptFunctionState inherits Reference (reference counted).

Geometry

core singleton class Geometry inherits Object (unsafe).

GeometryInstance

core class GeometryInstance inherits VisualInstance (unsafe).

GlobalConstants

core singleton class GlobalConstants (unsafe).

GodotString

Godot's reference-counted string type.

Gradient

core class Gradient inherits Resource (reference counted).

GradientTexture

core class GradientTexture inherits Texture (reference counted).

GridMap

core class GridMap inherits Spatial (unsafe).

Image

core class Image inherits Resource (reference counted).

ImageTexture

core class ImageTexture inherits Texture (reference counted).

ImmediateGeometry

core class ImmediateGeometry inherits GeometryInstance (unsafe).

Input

core singleton class Input inherits Object (unsafe).

InputDefault

core class InputDefault inherits Input (unsafe).

InputEvent

core class InputEvent inherits Resource (reference counted).

InputEventKey

core class InputEventKey inherits InputEventWithModifiers (reference counted).

InputEventWithModifiers

core class InputEventWithModifiers inherits InputEvent (reference counted).

InputMap

core singleton class InputMap inherits Object (unsafe).

InstancePlaceholder

core class InstancePlaceholder inherits Node (unsafe).

Int32Array

A reference-counted vector of i32 that uses Godot's pool allocator.

InterpolatedCamera

core class InterpolatedCamera inherits Camera (unsafe).

JSON

core singleton class JSON inherits Object (unsafe).

JSONParseResult

core class JSONParseResult inherits Reference (reference counted).

JavaScript

core singleton class JavaScript inherits Object (unsafe).

LargeTexture

core class LargeTexture inherits Texture (reference counted).

Line2D

core class Line2D inherits Node2D (unsafe).

LineShape2D

core class LineShape2D inherits Shape2D (reference counted).

Listener

core class Listener inherits Spatial (unsafe).

MainLoop

core class MainLoop inherits Object (unsafe).

Marshalls

core singleton class Marshalls inherits Reference (unsafe).

Material

core class Material inherits Resource (reference counted).

Mesh

core class Mesh inherits Resource (reference counted).

MeshDataTool

core class MeshDataTool inherits Reference (reference counted).

MeshInstance

core class MeshInstance inherits GeometryInstance (unsafe).

MeshInstance2D

core class MeshInstance2D inherits Node2D (unsafe).

MeshLibrary

core class MeshLibrary inherits Resource (reference counted).

MultiMesh

core class MultiMesh inherits Resource (reference counted).

MultiMeshInstance

core class MultiMeshInstance inherits GeometryInstance (unsafe).

MultiplayerAPI

core class MultiplayerAPI inherits Reference (reference counted).

Mutex

core class Mutex inherits Reference (reference counted).

NativeInstanceHeader

Godot native class implementation detail that must be stored in each instance.

NativeRef

A reference to a rust native script.

NativeScript

core class NativeScript inherits Script (reference counted).

Navigation

core class Navigation inherits Spatial (unsafe).

Navigation2D

core class Navigation2D inherits Node2D (unsafe).

NavigationMesh

core class NavigationMesh inherits Resource (reference counted).

NavigationMeshInstance

core class NavigationMeshInstance inherits Spatial (unsafe).

NavigationPolygon

core class NavigationPolygon inherits Resource (reference counted).

NavigationPolygonInstance

core class NavigationPolygonInstance inherits Node2D (unsafe).

NetworkedMultiplayerPeer

core class NetworkedMultiplayerPeer inherits PacketPeer (reference counted).

Node

core class Node inherits Object (unsafe).

Node2D

core class Node2D inherits CanvasItem (unsafe).

NodePath

A reference-counted relative or absolute path in a scene tree, for use with Node.get_node() and similar functions. It can reference a node, a resource within a node, or a property of a node or resource.

OS

core singleton class OS inherits Object (unsafe).

Object

The base class of most Godot classes.

OrientedPathFollow

core class OrientedPathFollow inherits Spatial (unsafe).

PCKPacker

core class PCKPacker inherits Reference (reference counted).

PHashTranslation

core class PHashTranslation inherits Translation (reference counted).

PackedDataContainer

core class PackedDataContainer inherits Resource (reference counted).

PackedDataContainerRef

core class PackedDataContainerRef inherits Reference (reference counted).

PackedScene

core class PackedScene inherits Resource (reference counted).

PacketPeer

core class PacketPeer inherits Reference (reference counted).

PanoramaSky

core class PanoramaSky inherits Sky (reference counted).

Path

core class Path inherits Spatial (unsafe).

Path2D

core class Path2D inherits Node2D (unsafe).

PathFollow

core class PathFollow inherits Spatial (unsafe).

PathFollow2D

core class PathFollow2D inherits Node2D (unsafe).

Performance

core singleton class Performance inherits Object (unsafe).

Plane

Plane in hessian form.

PlaneMesh

core class PlaneMesh inherits PrimitiveMesh (reference counted).

PlaneShape

core class PlaneShape inherits Shape (reference counted).

PluginScript

core class PluginScript inherits Script (reference counted).

Polygon2D

core class Polygon2D inherits Node2D (unsafe).

PolygonPathFinder

core class PolygonPathFinder inherits Resource (reference counted).

Position2D

core class Position2D inherits Node2D (unsafe).

Position3D

core class Position3D inherits Spatial (unsafe).

PrimitiveMesh

core class PrimitiveMesh inherits Mesh (reference counted).

PrismMesh

core class PrismMesh inherits PrimitiveMesh (reference counted).

ProceduralSky

core class ProceduralSky inherits Sky (reference counted).

ProjectSettings

core singleton class ProjectSettings inherits Object (unsafe).

ProximityGroup

core class ProximityGroup inherits Spatial (unsafe).

ProxyTexture

core class ProxyTexture inherits Texture (reference counted).

QuadMesh

core class QuadMesh inherits PrimitiveMesh (reference counted).

QueueFreeOnDrop

A wrapper that automatically enqueues the object for deletion when dropped.

RayCast

core class RayCast inherits Spatial (unsafe).

RayCast2D

core class RayCast2D inherits Node2D (unsafe).

RayShape

core class RayShape inherits Shape (reference counted).

RayShape2D

core class RayShape2D inherits Shape2D (reference counted).

RectangleShape2D

core class RectangleShape2D inherits Shape2D (reference counted).

Reference

Base class of all reference-counted types. Inherits Object.

RegEx

core class RegEx inherits Reference (reference counted).

RegExMatch

core class RegExMatch inherits Reference (reference counted).

RemoteTransform

core class RemoteTransform inherits Spatial (unsafe).

RemoteTransform2D

core class RemoteTransform2D inherits Node2D (unsafe).

Resource

core class Resource inherits Reference (reference counted).

ResourceImporter

core class ResourceImporter inherits Reference (reference counted).

ResourceInteractiveLoader

core class ResourceInteractiveLoader inherits Reference (reference counted).

ResourceLoader

core singleton class ResourceLoader inherits Object (unsafe).

ResourcePreloader

core class ResourcePreloader inherits Node (unsafe).

ResourceSaver

core singleton class ResourceSaver inherits Object (unsafe).

Rid

The RID type is used to access the unique integer ID of a resource. They are opaque, so they do not grant access to the associated resource by themselves.

RootMotionView

core class RootMotionView inherits VisualInstance (unsafe).

SceneState

core class SceneState inherits Reference (reference counted).

SceneTree

core class SceneTree inherits MainLoop (unsafe).

SceneTreeTimer

core class SceneTreeTimer inherits Reference (reference counted).

Script

core class Script inherits Resource (reference counted).

SegmentShape2D

core class SegmentShape2D inherits Shape2D (reference counted).

Semaphore

core class Semaphore inherits Reference (reference counted).

Shader

core class Shader inherits Resource (reference counted).

Shape

core class Shape inherits Resource (reference counted).

Shape2D

core class Shape2D inherits Resource (reference counted).

Sky

core class Sky inherits Resource (reference counted).

Spatial

core class Spatial inherits Node (unsafe).

SpatialGizmo

core class SpatialGizmo inherits Reference (reference counted).

SpatialVelocityTracker

core class SpatialVelocityTracker inherits Reference (reference counted).

SphereMesh

core class SphereMesh inherits PrimitiveMesh (reference counted).

SphereShape

core class SphereShape inherits Shape (reference counted).

StringArray

A vector of GodotString that uses Godot's pool allocator.

StringName
StyleBox

core class StyleBox inherits Resource (reference counted).

StyleBoxEmpty

core class StyleBoxEmpty inherits StyleBox (reference counted).

StyleBoxFlat

core class StyleBoxFlat inherits StyleBox (reference counted).

StyleBoxLine

core class StyleBoxLine inherits StyleBox (reference counted).

StyleBoxTexture

core class StyleBoxTexture inherits StyleBox (reference counted).

SurfaceTool

core class SurfaceTool inherits Reference (reference counted).

TextFile

core class TextFile inherits Resource (reference counted).

Texture

core class Texture inherits Resource (reference counted).

Thread

core class Thread inherits Reference (reference counted).

Timer

core class Timer inherits Node (unsafe).

Transform

3D Transformation (3x4 matrix) Using basis + origin representation.

Translation

core class Translation inherits Resource (reference counted).

TranslationServer

core singleton class TranslationServer inherits Object (unsafe).

TreeItem

core class TreeItem inherits Object (unsafe).

TriangleMesh

core class TriangleMesh inherits Reference (reference counted).

Variant

A Variant can represent many of godot's core types.

VariantArray

A reference-counted Variant vector. Godot's generic array data type. Negative indices can be used to count from the right.

Vector2Array

A reference-counted vector of Vector2 that uses Godot's pool allocator.

Vector3Array

A reference-counted vector of Vector3 that uses Godot's pool allocator.

Viewport

core class Viewport inherits Node (unsafe).

ViewportTexture

core class ViewportTexture inherits Texture (reference counted).

VisibilityEnabler

core class VisibilityEnabler inherits VisibilityNotifier (unsafe).

VisibilityEnabler2D

core class VisibilityEnabler2D inherits VisibilityNotifier2D (unsafe).

VisibilityNotifier

core class VisibilityNotifier inherits Spatial (unsafe).

VisibilityNotifier2D

core class VisibilityNotifier2D inherits Node2D (unsafe).

VisualInstance

core class VisualInstance inherits Spatial (unsafe).

WeakRef

core class WeakRef inherits Reference (reference counted).

World

core class World inherits Resource (reference counted).

World2D

core class World2D inherits Resource (reference counted).

WorldEnvironment

core class WorldEnvironment inherits Node (unsafe).

XMLParser

core class XMLParser inherits Reference (reference counted).

YSort

core class YSort inherits Node2D (unsafe).

Enums

ArrayMeshArrayFormat
ArrayMeshArrayType
BackBufferCopyCopyMode
Camera2DAnchorMode
CameraDopplerTracking
CameraKeepAspect
CameraProjection
CanvasItemBlendMode
CurveTangentMode
DynamicFontDataHinting
DynamicFontSpacingType
EnvironmentBGMode
EnvironmentDOFBlurQuality
EnvironmentGlowBlendMode
EnvironmentSSAOBlur
EnvironmentSSAOQuality
EnvironmentToneMapper
FileCompressionMode
FileModeFlags
GeometryInstanceFlags
GeometryInstanceShadowCastingSetting
GodotError
ImageAlphaMode
ImageCompressMode
ImageCompressSource
ImageFormat
ImageInterpolation
ImageTextureStorage
InputCursorShape
InputMouseMode
Line2DLineTextureMode
Line2DLineCapMode
Line2DLineJointMode
MeshArrayFormat
MeshArrayType
MeshBlendShapeMode
MeshPrimitiveType
MultiMeshColorFormat
MultiMeshTransformFormat
MultiplayerAPIRPCMode
NetworkedMultiplayerPeerConnectionStatus
NetworkedMultiplayerPeerTransferMode
NodeDuplicateFlags
NodePauseMode
OSMonth
OSPowerState
OSScreenOrientation
OSSystemDir
OSWeekday
ObjectConnectFlags
PackedSceneGenEditState
PathFollowRotationMode
PerformanceMonitor
ProceduralSkyTextureSize
ProximityGroupDispatchMode
ResourceSaverSaverFlags
SceneStateGenEditState
SceneTreeGroupCallFlags
SceneTreeStretchAspect
SceneTreeStretchMode
ShaderMode
SkyRadianceSize
StyleBoxTextureAxisStretchMode
TextureFlags
ThreadPriority
TimerTimerProcessMode
TreeItemTextAlign
TreeItemTreeCellMode
VariantOperator
VariantType
Vector3Axis
ViewportClearMode
ViewportDebugDraw
ViewportMSAA
ViewportRenderInfo
ViewportShadowAtlasQuadrantSubdiv
ViewportUpdateMode
ViewportUsage
VisibilityEnabler2DEnabler
VisibilityEnablerEnabler
XMLParserNodeType

Traits

Free

Manually managed Godot classes implementing free.

GodotObject

Internal details.

NativeClass
QueueFree

Manually managed Godot classes implementing queue_free.

ToVariant

Types that can be converted to and from a Variant.

Functions

result_from_sys

Type Definitions

GodotResult
Quat
Rect2
Transform2D
Vector2
Vector3