Skip to main content

engage/generated/tm_pro/
materialreference.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "tm_pro-materialreference-types")]
4mod __types {
5    #[allow(unused_imports)] use ::unity::prelude::*;
6
7    use super::*;
8    use crate::system::{
9        object::{IObject, Object},
10        valuetype::{IValueType, ValueType},
11    };
12
13    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/tm_pro/materialreference/MaterialReference.md"))]
14    #[repr(C)]
15    #[derive(::core::clone::Clone, ::core::marker::Copy)]
16    pub struct MaterialReference {
17        pub index: i32,
18        pub font_asset: crate::tm_pro::tmp_fontasset::TMP_FontAsset,
19        pub sprite_asset: crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset,
20        pub material: crate::unity_engine::material::Material,
21        pub is_default_material: bool,
22        pub is_fallback_material: bool,
23        pub fallback_material: crate::unity_engine::material::Material,
24        pub padding: f32,
25        pub reference_count: i32,
26    }
27    impl ::unity::ClassIdentity for MaterialReference {
28        const NAME: &'static str = "MaterialReference";
29        const NAMESPACE: &'static str = "TMPro";
30
31        fn class() -> ::unity::Class {
32            static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
33            *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
34        }
35    }
36    impl ::unity::IlType for MaterialReference {
37        fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
38            &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
39        }
40    }
41}
42
43#[cfg(feature = "tm_pro-materialreference-types")]
44pub use __types::*;
45
46#[cfg(feature = "tm_pro-materialreference")]
47impl MaterialReference {
48    #[doc = "`Contains(::unity::Array<crate::tm_pro::materialreference::MaterialReference>, crate::tm_pro::tmp_fontasset::TMP_FontAsset)` overload"]
49    pub fn contains(
50        material_references: impl ::core::convert::Into<::unity::Array<crate::tm_pro::materialreference::MaterialReference>>,
51        font_asset: impl ::core::convert::Into<crate::tm_pro::tmp_fontasset::TMP_FontAsset>,
52    ) -> bool {
53        unsafe {
54            ::unity::il2cpp_call!((::unity::module_base()+0x2d8d0c0usize)as*mut u8,bool;
55(::unity::Array<crate::tm_pro::materialreference::MaterialReference>)::core::convert::Into::into(material_references),(crate::tm_pro::tmp_fontasset::TMP_FontAsset)::core::convert::Into::into(font_asset))
56        }
57    }
58
59    #[doc = "`AddMaterialReference(crate::unity_engine::material::Material, crate::tm_pro::tmp_fontasset::TMP_FontAsset, *mut::unity::Array<crate::tm_pro::materialreference::MaterialReference>, crate::system::collections::generic::dictionary_2::Dictionary_2<i32,i32>)` overload"]
60    pub fn add_material_reference(
61        material: impl ::core::convert::Into<crate::unity_engine::material::Material>,
62        font_asset: impl ::core::convert::Into<crate::tm_pro::tmp_fontasset::TMP_FontAsset>,
63        material_reference_index_lookup: impl ::core::convert::Into<crate::system::collections::generic::dictionary_2::Dictionary_2<i32, i32>>,
64    ) -> (i32, ::unity::Array<crate::tm_pro::materialreference::MaterialReference>) {
65        unsafe {
66            let mut __out_0 = ::core::mem::MaybeUninit::<::unity::Array<crate::tm_pro::materialreference::MaterialReference>>::uninit();
67            let __ret = {
68                ::unity::il2cpp_call!((::unity::module_base()+0x2d8d1d0usize)as*mut u8,i32;
69(crate::unity_engine::material::Material)::core::convert::Into::into(material),(crate::tm_pro::tmp_fontasset::TMP_FontAsset)::core::convert::Into::into(font_asset),(*mut::unity::Array<crate::tm_pro::materialreference::MaterialReference>)__out_0.as_mut_ptr(),(crate::system::collections::generic::dictionary_2::Dictionary_2<i32,i32>)::core::convert::Into::into(material_reference_index_lookup))
70            };
71            (__ret, __out_0.assume_init())
72        }
73    }
74
75    #[doc = "`AddMaterialReference(crate::unity_engine::material::Material, crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset, *mut::unity::Array<crate::tm_pro::materialreference::MaterialReference>, crate::system::collections::generic::dictionary_2::Dictionary_2<i32,i32>)` overload"]
76    pub fn add_material_reference_2(
77        material: impl ::core::convert::Into<crate::unity_engine::material::Material>,
78        sprite_asset: impl ::core::convert::Into<crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset>,
79        material_reference_index_lookup: impl ::core::convert::Into<crate::system::collections::generic::dictionary_2::Dictionary_2<i32, i32>>,
80    ) -> (i32, ::unity::Array<crate::tm_pro::materialreference::MaterialReference>) {
81        unsafe {
82            let mut __out_0 = ::core::mem::MaybeUninit::<::unity::Array<crate::tm_pro::materialreference::MaterialReference>>::uninit();
83            let __ret = {
84                ::unity::il2cpp_call!((::unity::module_base()+0x2d8d3f0usize)as*mut u8,i32;
85(crate::unity_engine::material::Material)::core::convert::Into::into(material),(crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset)::core::convert::Into::into(sprite_asset),(*mut::unity::Array<crate::tm_pro::materialreference::MaterialReference>)__out_0.as_mut_ptr(),(crate::system::collections::generic::dictionary_2::Dictionary_2<i32,i32>)::core::convert::Into::into(material_reference_index_lookup))
86            };
87            (__ret, __out_0.assume_init())
88        }
89    }
90}
91
92#[cfg(feature = "tm_pro-materialreference")]
93impl MaterialReference {
94    #[doc = "`.ctor(i32, crate::tm_pro::tmp_fontasset::TMP_FontAsset, crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset, crate::unity_engine::material::Material, f32)` overload"]
95    pub fn ctor(
96        &mut self,
97        index: impl ::core::convert::Into<i32>,
98        font_asset: impl ::core::convert::Into<crate::tm_pro::tmp_fontasset::TMP_FontAsset>,
99        sprite_asset: impl ::core::convert::Into<crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset>,
100        material: impl ::core::convert::Into<crate::unity_engine::material::Material>,
101        padding: impl ::core::convert::Into<f32>,
102    ) -> () {
103        unsafe {
104            ::unity::il2cpp_call!((::unity::module_base()+0x2d8d010usize)as*mut u8,();
105(*mut MaterialReference)self as*mut MaterialReference,(i32)::core::convert::Into::into(index),(crate::tm_pro::tmp_fontasset::TMP_FontAsset)::core::convert::Into::into(font_asset),(crate::tm_pro::tmp_spriteasset::TMP_SpriteAsset)::core::convert::Into::into(sprite_asset),(crate::unity_engine::material::Material)::core::convert::Into::into(material),(f32)::core::convert::Into::into(padding))
106        }
107    }
108}
109
110#[cfg(feature = "tm_pro-materialreference")]
111impl MaterialReference {
112    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
113        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
114    }
115
116    pub fn contains_method_info() -> &'static ::unity::il2cpp::MethodInfo {
117        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
118    }
119
120    pub fn add_material_reference_method_info() -> &'static ::unity::il2cpp::MethodInfo {
121        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
122    }
123
124    pub fn add_material_reference_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
125        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
126    }
127}
128
129#[cfg(feature = "tm_pro-materialreference")]
130#[doc(hidden)]
131pub mod prelude {
132    pub use super::MaterialReference;
133    #[cfg(feature = "system-object")]
134    pub use crate::system::object::IObjectMethods;
135    #[cfg(feature = "system-valuetype")]
136    pub use crate::system::valuetype::IValueTypeMethods;
137    pub use crate::system::{object::IObject, valuetype::IValueType};
138}