engage/generated/unity_engine/rendering/universal/
whitebalance.rs1#[cfg(feature = "unity_engine-rendering-universal-whitebalance-types")]
4mod __types {
5 #[allow(unused_imports)] use ::unity::prelude::*;
6
7 use super::*;
8 use crate::{
9 system::object::{IObject, Object},
10 unity_engine::{
11 object_2::{IObject_2, Object_2},
12 rendering::volumecomponent::{IVolumeComponent, VolumeComponent},
13 scriptableobject::{IScriptableObject, ScriptableObject},
14 },
15 };
16
17 #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/unity_engine/rendering/universal/whitebalance/WhiteBalance.md"))]
18 #[::unity::class(namespace = "UnityEngine.Rendering.Universal", name = "WhiteBalance")]
19 #[parent(crate::unity_engine::rendering::volumecomponent::VolumeComponent)]
20 pub struct WhiteBalance {
21 #[offset(56)]
22 #[rename(name = "temperature")]
23 pub temperature: crate::unity_engine::rendering::clampedfloatparameter::ClampedFloatParameter,
24 #[offset(64)]
25 #[rename(name = "tint")]
26 pub tint: crate::unity_engine::rendering::clampedfloatparameter::ClampedFloatParameter,
27 }
28}
29
30#[cfg(feature = "unity_engine-rendering-universal-whitebalance-types")]
31pub use __types::*;
32
33#[cfg(feature = "unity_engine-rendering-universal-whitebalance")]
34pub trait IWhiteBalanceMethods: IWhiteBalance {
35 #[doc = "`IsActive()` overload"]
36 fn is_active(self) -> bool {
37 unsafe {
38 let __receiver = <WhiteBalance as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
39 {
40 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
41 let __vi = *__vt.get(8usize).unwrap_or_else(|| {
42 panic!(
43 "unity: virtual slot {}
44 out of range (vtable len {}
45) on the runtime class behind {}
46 (method `{}
47`)",
48 8usize,
49 __vt.len(),
50 <WhiteBalance as ::unity::ClassIdentity>::NAME,
51 "IsActive",
52 )
53 });
54 let __inner: extern "C" fn(WhiteBalance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
55 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
56 __inner(__receiver, __mi)
57 }
58 }
59 }
60 #[doc = "`IsTileCompatible()` overload"]
61 fn is_tile_compatible(self) -> bool {
62 unsafe {
63 let __receiver = <WhiteBalance as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
64 {
65 let __vt = ::unity::Cast::get_class(__receiver).raw().get_vtable();
66 let __vi = *__vt.get(9usize).unwrap_or_else(|| {
67 panic!(
68 "unity: virtual slot {}
69 out of range (vtable len {}
70) on the runtime class behind {}
71 (method `{}
72`)",
73 9usize,
74 __vt.len(),
75 <WhiteBalance as ::unity::ClassIdentity>::NAME,
76 "IsTileCompatible",
77 )
78 });
79 let __inner: extern "C" fn(WhiteBalance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__vi.method_ptr);
80 let __mi: ::unity::OptionalMethod = ::core::option::Option::Some(&*(__vi.method_info as *const ::unity::MethodInfo as *const ()));
81 __inner(__receiver, __mi)
82 }
83 }
84 }
85 #[doc = "`.ctor()` overload"]
86 fn ctor(self) -> () {
87 unsafe {
88 let __receiver = <WhiteBalance as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
89 ::unity::il2cpp_call!((::unity::module_base()+0x2cb12d0usize)as*mut u8,();
90(WhiteBalance)__receiver)
91 }
92 }
93}
94
95#[cfg(feature = "unity_engine-rendering-universal-whitebalance")]
96impl<__T: IWhiteBalance> IWhiteBalanceMethods for __T {}
97
98#[cfg(feature = "unity_engine-rendering-universal-whitebalance")]
99impl WhiteBalance {
100 pub fn is_active_method_info() -> &'static ::unity::il2cpp::MethodInfo {
101 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
102 }
103
104 pub fn is_tile_compatible_method_info() -> &'static ::unity::il2cpp::MethodInfo {
105 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
106 }
107
108 pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
109 <Self as ::unity::ClassIdentity>::class().raw().get_methods()[2]
110 }
111}
112
113#[cfg(feature = "unity_engine-rendering-universal-whitebalance")]
114impl WhiteBalance {
115 #[doc = "Direct (non-virtual) call to `WhiteBalance`'s own `IsActive`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
116 pub unsafe fn is_active(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
117 let __mi = Self::is_active_method_info();
118 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
119 __inner(this.into(), ::core::option::Option::None)
120 }
121
122 #[doc = "Direct (non-virtual) call to `WhiteBalance`'s own `IsTileCompatible`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
123 pub unsafe fn is_tile_compatible(this: impl ::core::convert::Into<::unity::IlInstance>) -> bool {
124 let __mi = Self::is_tile_compatible_method_info();
125 let __inner: extern "C" fn(::unity::IlInstance, ::unity::OptionalMethod) -> bool = ::core::mem::transmute(__mi.method_ptr);
126 __inner(this.into(), ::core::option::Option::None)
127 }
128}
129
130#[cfg(feature = "unity_engine-rendering-universal-whitebalance")]
131impl WhiteBalance {
132 #[doc = "`.ctor()` — no args"]
133 pub fn new() -> Self {
134 let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
135 panic!(
136 "{}
137::{}
138 failed to instantiate",
139 ::core::stringify!(WhiteBalance),
140 ::core::stringify!(new),
141 )
142 });
143 <Self as IWhiteBalanceMethods>::ctor(this);
144 this
145 }
146}
147
148#[cfg(feature = "unity_engine-rendering-universal-whitebalance")]
149#[doc(hidden)]
150pub mod prelude {
151 pub use super::{IWhiteBalance, IWhiteBalanceMethods, WhiteBalance};
152 #[cfg(feature = "system-object")]
153 pub use crate::system::object::IObjectMethods;
154 #[cfg(feature = "unity_engine-object_2")]
155 pub use crate::unity_engine::object_2::IObject_2Methods;
156 #[cfg(feature = "unity_engine-rendering-volumecomponent")]
157 pub use crate::unity_engine::rendering::volumecomponent::IVolumeComponentMethods;
158 #[cfg(feature = "unity_engine-scriptableobject")]
159 pub use crate::unity_engine::scriptableobject::IScriptableObjectMethods;
160 pub use crate::{
161 system::object::IObject,
162 unity_engine::{object_2::IObject_2, rendering::volumecomponent::IVolumeComponent, scriptableobject::IScriptableObject},
163 };
164}