objc2_ar_kit/generated/
AREnvironmentProbeAnchor.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4#[cfg(feature = "objc2")]
5use objc2::__framework_prelude::*;
6#[cfg(feature = "objc2-foundation")]
7use objc2_foundation::*;
8#[cfg(feature = "objc2-metal")]
9use objc2_metal::*;
10
11use crate::*;
12
13#[cfg(feature = "objc2")]
14extern_class!(
15    /// An object representing an environment probe in the world.
16    ///
17    /// Environment probes are used to light virtual geometry by producing environment
18    /// textures from the probe's location in the world.
19    ///
20    /// See also [Apple's documentation](https://developer.apple.com/documentation/arkit/arenvironmentprobeanchor?language=objc)
21    #[unsafe(super(ARAnchor, NSObject))]
22    #[derive(Debug, PartialEq, Eq, Hash)]
23    #[cfg(all(feature = "ARAnchor", feature = "objc2"))]
24    pub struct AREnvironmentProbeAnchor;
25);
26
27#[cfg(all(feature = "ARAnchor", feature = "objc2"))]
28unsafe impl Send for AREnvironmentProbeAnchor {}
29
30#[cfg(all(feature = "ARAnchor", feature = "objc2"))]
31unsafe impl Sync for AREnvironmentProbeAnchor {}
32
33#[cfg(all(feature = "ARAnchor", feature = "objc2", feature = "objc2-foundation"))]
34unsafe impl ARAnchorCopying for AREnvironmentProbeAnchor {}
35
36#[cfg(all(feature = "ARAnchor", feature = "objc2", feature = "objc2-foundation"))]
37unsafe impl NSCoding for AREnvironmentProbeAnchor {}
38
39#[cfg(all(feature = "ARAnchor", feature = "objc2", feature = "objc2-foundation"))]
40unsafe impl NSCopying for AREnvironmentProbeAnchor {}
41
42#[cfg(all(feature = "ARAnchor", feature = "objc2", feature = "objc2-foundation"))]
43unsafe impl CopyingHelper for AREnvironmentProbeAnchor {
44    type Result = Self;
45}
46
47#[cfg(all(feature = "ARAnchor", feature = "objc2"))]
48unsafe impl NSObjectProtocol for AREnvironmentProbeAnchor {}
49
50#[cfg(all(feature = "ARAnchor", feature = "objc2", feature = "objc2-foundation"))]
51unsafe impl NSSecureCoding for AREnvironmentProbeAnchor {}
52
53#[cfg(all(feature = "ARAnchor", feature = "objc2"))]
54impl AREnvironmentProbeAnchor {
55    extern_methods!(
56        #[cfg(feature = "objc2-metal")]
57        /// The environment texture of the probe.
58        ///
59        /// The texture is provided as a cube using MTLTextureTypeCube.
60        #[unsafe(method(environmentTexture))]
61        #[unsafe(method_family = none)]
62        pub unsafe fn environmentTexture(&self)
63            -> Option<Retained<ProtocolObject<dyn MTLTexture>>>;
64    );
65}
66
67/// Methods declared on superclass `ARAnchor`.
68#[cfg(all(feature = "ARAnchor", feature = "objc2"))]
69impl AREnvironmentProbeAnchor {
70    extern_methods!(
71        /// Unavailable
72        #[unsafe(method(init))]
73        #[unsafe(method_family = init)]
74        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
75
76        #[unsafe(method(new))]
77        #[unsafe(method_family = new)]
78        pub unsafe fn new() -> Retained<Self>;
79    );
80}