[−][src]Struct gdnative::api::SurfaceTool
core class SurfaceTool
inherits Reference
(reference counted).
Official documentation
See the documentation of this class in the Godot engine's official documentation.
Memory management
The lifetime of this object is automatically managed through reference counting.
Class hierarchy
SurfaceTool inherits methods from:
Safety
All types in the Godot API have "interior mutability" in Rust parlance.
To enforce that the official thread-safety guidelines are
followed, the typestate pattern is used in the Ref
and TRef
smart pointers,
and the Instance
API. The typestate Access
in these types tracks whether the
access is unique, shared, or exclusive to the current thread. For more information,
see the type-level documentation on Ref
.
Implementations
impl SurfaceTool
[src]
pub fn new() -> Ref<SurfaceTool, Unique>
[src]
Creates a new instance of this object.
This is a reference-counted type. The returned object is automatically managed
by Ref
.
pub fn add_bones(&self, bones: TypedArray<i32>)
[src]
pub fn add_color(&self, color: Color)
[src]
pub fn add_index(&self, index: i64)
[src]
pub fn add_normal(&self, normal: Vector3D<f32, UnknownUnit>)
[src]
pub fn add_smooth_group(&self, smooth: bool)
[src]
pub fn add_tangent(&self, tangent: Plane)
[src]
pub fn add_triangle_fan(
&self,
vertices: TypedArray<Vector3D<f32, UnknownUnit>>,
uvs: TypedArray<Vector2D<f32, UnknownUnit>>,
colors: TypedArray<Color>,
uv2s: TypedArray<Vector2D<f32, UnknownUnit>>,
normals: TypedArray<Vector3D<f32, UnknownUnit>>,
tangents: VariantArray<Shared>
)
[src]
&self,
vertices: TypedArray<Vector3D<f32, UnknownUnit>>,
uvs: TypedArray<Vector2D<f32, UnknownUnit>>,
colors: TypedArray<Color>,
uv2s: TypedArray<Vector2D<f32, UnknownUnit>>,
normals: TypedArray<Vector3D<f32, UnknownUnit>>,
tangents: VariantArray<Shared>
)
pub fn add_uv(&self, uv: Vector2D<f32, UnknownUnit>)
[src]
pub fn add_uv2(&self, uv2: Vector2D<f32, UnknownUnit>)
[src]
pub fn add_vertex(&self, vertex: Vector3D<f32, UnknownUnit>)
[src]
pub fn add_weights(&self, weights: TypedArray<f32>)
[src]
pub fn append_from(
&self,
existing: impl AsArg<Mesh>,
surface: i64,
transform: Transform
)
[src]
&self,
existing: impl AsArg<Mesh>,
surface: i64,
transform: Transform
)
pub fn begin(&self, primitive: i64)
[src]
pub fn clear(&self)
[src]
pub fn commit(
&self,
existing: impl AsArg<ArrayMesh>,
flags: i64
) -> Option<Ref<ArrayMesh, Shared>>
[src]
&self,
existing: impl AsArg<ArrayMesh>,
flags: i64
) -> Option<Ref<ArrayMesh, Shared>>
pub fn commit_to_arrays(&self) -> VariantArray<Shared>
[src]
pub fn create_from(&self, existing: impl AsArg<Mesh>, surface: i64)
[src]
pub fn create_from_blend_shape(
&self,
existing: impl AsArg<Mesh>,
surface: i64,
blend_shape: impl Into<GodotString>
)
[src]
&self,
existing: impl AsArg<Mesh>,
surface: i64,
blend_shape: impl Into<GodotString>
)
pub fn deindex(&self)
[src]
pub fn generate_normals(&self, flip: bool)
[src]
pub fn generate_tangents(&self)
[src]
pub fn index(&self)
[src]
pub fn set_material(&self, material: impl AsArg<Material>)
[src]
Methods from Deref<Target = Reference>
Trait Implementations
impl Debug for SurfaceTool
[src]
impl Deref for SurfaceTool
[src]
impl DerefMut for SurfaceTool
[src]
impl GodotObject for SurfaceTool
[src]
type RefKind = RefCounted
The memory management kind of this type. This modifies the behavior of the Ref
smart pointer. See its type-level documentation for more information. Read more
fn class_name() -> &'static str
[src]
fn null() -> Null<Self>
[src]
fn new() -> Ref<Self, Unique> where
Self: Instanciable,
[src]
Self: Instanciable,
fn cast<T>(&self) -> Option<&T> where
T: GodotObject + SubClass<Self>,
[src]
T: GodotObject + SubClass<Self>,
fn upcast<T>(&self) -> &T where
Self: SubClass<T>,
T: GodotObject,
[src]
Self: SubClass<T>,
T: GodotObject,
unsafe fn assume_shared(&self) -> Ref<Self, Shared>
[src]
unsafe fn assume_thread_local(&self) -> Ref<Self, ThreadLocal> where
Self: GodotObject<RefKind = RefCounted>,
[src]
Self: GodotObject<RefKind = RefCounted>,
unsafe fn assume_unique(&self) -> Ref<Self, Unique>
[src]
impl Instanciable for SurfaceTool
[src]
fn construct() -> Ref<SurfaceTool, Unique>
[src]
impl SubClass<Object> for SurfaceTool
[src]
impl SubClass<Reference> for SurfaceTool
[src]
Auto Trait Implementations
impl RefUnwindSafe for SurfaceTool
impl !Send for SurfaceTool
impl !Sync for SurfaceTool
impl Unpin for SurfaceTool
impl UnwindSafe for SurfaceTool
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> SubClass<T> for T where
T: GodotObject,
[src]
T: GodotObject,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,