engage/generated/unity_engine/rendering/
depthstate.rs1#[cfg(feature = "unity_engine-rendering-depthstate-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/unity_engine/rendering/depthstate/DepthState.md"))]
14 #[repr(C)]
15 #[derive(::core::clone::Clone, ::core::marker::Copy)]
16 pub struct DepthState {
17 pub m_write_enabled: u8,
18 pub m_compare_function: i8,
19 }
20 impl ::unity::ClassIdentity for DepthState {
21 const NAME: &'static str = "DepthState";
22 const NAMESPACE: &'static str = "UnityEngine.Rendering";
23
24 fn class() -> ::unity::Class {
25 static CACHE: ::std::sync::OnceLock<::unity::Class> = ::std::sync::OnceLock::new();
26 *CACHE.get_or_init(|| ::unity::Class::lookup(Self::NAMESPACE, Self::NAME))
27 }
28 }
29 impl ::unity::IlType for DepthState {
30 fn il_type() -> &'static ::unity::il2cpp::Il2CppType {
31 &<Self as ::unity::ClassIdentity>::class().raw()._1.byval_arg
32 }
33 }
34}
35
36#[cfg(feature = "unity_engine-rendering-depthstate-types")]
37pub use __types::*;
38
39#[cfg(feature = "unity_engine-rendering-depthstate")]
40impl DepthState {
41 #[doc = "`get_defaultValue()` overload"]
42 pub fn get_default_value() -> crate::unity_engine::rendering::depthstate::DepthState {
43 unsafe {
44 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c000usize)as*mut u8,crate::unity_engine::rendering::depthstate::DepthState;
45 )
46 }
47 }
48}
49
50#[cfg(feature = "unity_engine-rendering-depthstate")]
51impl DepthState {
52 #[doc = "`.ctor(bool, crate::unity_engine::rendering::comparefunction::CompareFunction)` overload"]
53 pub fn ctor(
54 &mut self,
55 write_enabled: impl ::core::convert::Into<bool>,
56 compare_function: impl ::core::convert::Into<crate::unity_engine::rendering::comparefunction::CompareFunction>,
57 ) -> () {
58 unsafe {
59 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c070usize)as*mut u8,();
60(*mut DepthState)self as*mut DepthState,(bool)::core::convert::Into::into(write_enabled),(crate::unity_engine::rendering::comparefunction::CompareFunction)::core::convert::Into::into(compare_function))
61 }
62 }
63
64 #[doc = "`set_writeEnabled(bool)` overload"]
65 pub fn set_write_enabled(&mut self, value: impl ::core::convert::Into<bool>) -> () {
66 unsafe {
67 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c100usize)as*mut u8,();
68(*mut DepthState)self as*mut DepthState,(bool)::core::convert::Into::into(value))
69 }
70 }
71
72 #[doc = "`set_compareFunction(crate::unity_engine::rendering::comparefunction::CompareFunction)` overload"]
73 pub fn set_compare_function(
74 &mut self,
75 value: impl ::core::convert::Into<crate::unity_engine::rendering::comparefunction::CompareFunction>,
76 ) -> () {
77 unsafe {
78 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c180usize)as*mut u8,();
79(*mut DepthState)self as*mut DepthState,(crate::unity_engine::rendering::comparefunction::CompareFunction)::core::convert::Into::into(value))
80 }
81 }
82
83 #[doc = "`Equals(crate::unity_engine::rendering::depthstate::DepthState)` overload"]
84 pub fn equals(&mut self, other: impl ::core::convert::Into<crate::unity_engine::rendering::depthstate::DepthState>) -> bool {
85 unsafe {
86 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c190usize)as*mut u8,bool;
87(*mut DepthState)self as*mut DepthState,(crate::unity_engine::rendering::depthstate::DepthState)::core::convert::Into::into(other))
88 }
89 }
90
91 #[doc = "`Equals(crate::system::object::Object)` overload"]
92 pub fn equals_2(&mut self, obj: impl ::core::convert::Into<crate::system::object::Object>) -> bool {
93 unsafe {
94 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c1c0usize)as*mut u8,bool;
95(*mut DepthState)self as*mut DepthState,(crate::system::object::Object)::core::convert::Into::into(obj))
96 }
97 }
98
99 #[doc = "`GetHashCode()` overload"]
100 pub fn get_hash_code(&mut self) -> i32 {
101 unsafe {
102 ::unity::il2cpp_call!((::unity::module_base()+0x2c4c260usize)as*mut u8,i32;
103(*mut DepthState)self as*mut DepthState)
104 }
105 }
106}
107
108#[cfg(feature = "unity_engine-rendering-depthstate")]
109impl DepthState {
110 pub fn get_default_value_method_info() -> &'static ::unity::il2cpp::MethodInfo {
111 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
112 }
113
114 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
115 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
116 }
117
118 pub fn set_write_enabled_method_info() -> &'static ::unity::il2cpp::MethodInfo {
119 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
120 }
121
122 pub fn set_compare_function_method_info() -> &'static ::unity::il2cpp::MethodInfo {
123 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[3]
124 }
125
126 pub fn equals_method_info() -> &'static ::unity::il2cpp::MethodInfo {
127 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[4]
128 }
129
130 pub fn equals_2_method_info() -> &'static ::unity::il2cpp::MethodInfo {
131 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[5]
132 }
133
134 pub fn get_hash_code_method_info() -> &'static ::unity::il2cpp::MethodInfo {
135 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[6]
136 }
137}
138
139#[cfg(feature = "unity_engine-rendering-depthstate")]
140#[doc(hidden)]
141pub mod prelude {
142 pub use super::DepthState;
143 #[cfg(feature = "system-object")]
144 pub use crate::system::object::IObjectMethods;
145 #[cfg(feature = "system-valuetype")]
146 pub use crate::system::valuetype::IValueTypeMethods;
147 pub use crate::system::{object::IObject, valuetype::IValueType};
148}