Skip to main content

engage/generated/unity_engine/rendering/
intparameter.rs

1// @generated by il2cpp-bindgen — do not edit by hand.
2
3#[cfg(feature = "unity_engine-rendering-intparameter-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::rendering::{
11            volumeparameter::{IVolumeParameter, VolumeParameter},
12            volumeparameter_1::{IVolumeParameter_1, VolumeParameter_1},
13        },
14    };
15
16    #[doc=include_str!(concat!(env!("CARGO_MANIFEST_DIR"),"/","docs/unity_engine/rendering/intparameter/IntParameter.md"))]
17    #[::unity::class(namespace = "UnityEngine.Rendering", name = "IntParameter")]
18    #[parent(crate::unity_engine::rendering::volumeparameter_1::VolumeParameter_1<i32>)]
19    pub struct IntParameter {}
20}
21
22#[cfg(feature = "unity_engine-rendering-intparameter-types")]
23pub use __types::*;
24
25#[cfg(feature = "unity_engine-rendering-intparameter")]
26pub trait IIntParameterMethods: IIntParameter {
27    #[doc = "`.ctor(i32, bool)` overload"]
28    fn ctor(self, value: impl ::core::convert::Into<i32>, override_state: impl ::core::convert::Into<bool>) -> () {
29        unsafe {
30            let __receiver = <IntParameter as ::unity::FromIlInstance>::from_il_instance(<Self as ::unity::SystemObject>::as_instance(self));
31            ::unity::il2cpp_call!((::unity::module_base()+0x30aaed0usize)as*mut u8,();
32(IntParameter)__receiver,(i32)::core::convert::Into::into(value),(bool)::core::convert::Into::into(override_state))
33        }
34    }
35    #[doc = "`Interp(i32, i32, f32)` overload"]
36    fn interp(self, from: impl ::core::convert::Into<i32>, to: impl ::core::convert::Into<i32>, t: impl ::core::convert::Into<f32>) -> () {
37        unsafe {
38            let __receiver = <IntParameter 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(14usize).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                        14usize,
49                        __vt.len(),
50                        <IntParameter as ::unity::ClassIdentity>::NAME,
51                        "Interp",
52                    )
53                });
54                let __inner: extern "C" fn(IntParameter, i32, i32, f32, ::unity::OptionalMethod) -> () = ::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(
57                    __receiver,
58                    ::core::convert::Into::into(from),
59                    ::core::convert::Into::into(to),
60                    ::core::convert::Into::into(t),
61                    __mi,
62                )
63            }
64        }
65    }
66}
67
68#[cfg(feature = "unity_engine-rendering-intparameter")]
69impl<__T: IIntParameter> IIntParameterMethods for __T {}
70
71#[cfg(feature = "unity_engine-rendering-intparameter")]
72impl IntParameter {
73    pub fn ctor_method_info() -> &'static ::unity::il2cpp::MethodInfo {
74        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[0]
75    }
76
77    pub fn interp_method_info() -> &'static ::unity::il2cpp::MethodInfo {
78        <Self as ::unity::ClassIdentity>::class().raw().get_methods()[1]
79    }
80}
81
82#[cfg(feature = "unity_engine-rendering-intparameter")]
83impl IntParameter {
84    #[doc = "Direct (non-virtual) call to `IntParameter`'s own `Interp`. Bypasses the vtable, so it won't hit an override/patch — use it for base calls."]
85    pub unsafe fn interp(this: impl ::core::convert::Into<::unity::IlInstance>, from: i32, to: i32, t: f32) -> () {
86        let __mi = Self::interp_method_info();
87        let __inner: extern "C" fn(::unity::IlInstance, i32, i32, f32, ::unity::OptionalMethod) -> () = ::core::mem::transmute(__mi.method_ptr);
88        __inner(this.into(), from, to, t, ::core::option::Option::None)
89    }
90}
91
92#[cfg(feature = "unity_engine-rendering-intparameter")]
93impl IntParameter {
94    #[doc = "`.ctor(i32, bool)` — overload selector"]
95    pub fn new(value: i32, override_state: bool) -> Self {
96        let this = <Self as ::unity::FromIlInstance>::instantiate().unwrap_or_else(|| {
97            panic!(
98                "{}
99::{}
100 failed to instantiate",
101                ::core::stringify!(IntParameter),
102                ::core::stringify!(new),
103            )
104        });
105        <Self as IIntParameterMethods>::ctor(this, value, override_state);
106        this
107    }
108}
109
110#[cfg(feature = "unity_engine-rendering-intparameter")]
111#[doc(hidden)]
112pub mod prelude {
113    pub use super::{IIntParameter, IIntParameterMethods, IntParameter};
114    #[cfg(feature = "system-object")]
115    pub use crate::system::object::IObjectMethods;
116    #[cfg(feature = "unity_engine-rendering-volumeparameter")]
117    pub use crate::unity_engine::rendering::volumeparameter::IVolumeParameterMethods;
118    #[cfg(feature = "unity_engine-rendering-volumeparameter_1")]
119    pub use crate::unity_engine::rendering::volumeparameter_1::IVolumeParameter_1Methods;
120    pub use crate::{
121        system::object::IObject,
122        unity_engine::rendering::{volumeparameter::IVolumeParameter, volumeparameter_1::IVolumeParameter_1},
123    };
124}