1use core::ffi::*;
4use core::ptr::NonNull;
5#[cfg(feature = "objc2")]
6use objc2::__framework_prelude::*;
7#[cfg(feature = "objc2-av-foundation")]
8use objc2_av_foundation::*;
9#[cfg(feature = "objc2-core-location")]
10use objc2_core_location::*;
11#[cfg(feature = "objc2-foundation")]
12use objc2_foundation::*;
13
14use crate::*;
15
16#[cfg(feature = "objc2")]
21#[repr(transparent)]
22#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
23pub struct ARFrameSemantics(pub NSUInteger);
24#[cfg(feature = "objc2")]
25bitflags::bitflags! {
26 impl ARFrameSemantics: NSUInteger {
27#[doc(alias = "ARFrameSemanticNone")]
29 const None = 0;
30#[doc(alias = "ARFrameSemanticPersonSegmentation")]
38 const PersonSegmentation = 1<<0;
39#[doc(alias = "ARFrameSemanticPersonSegmentationWithDepth")]
48 const PersonSegmentationWithDepth = (1<<1)|(1<<0);
49#[doc(alias = "ARFrameSemanticBodyDetection")]
57 const BodyDetection = 1<<2;
58#[doc(alias = "ARFrameSemanticSceneDepth")]
64 const SceneDepth = 1<<3;
65#[doc(alias = "ARFrameSemanticSmoothedSceneDepth")]
71 const SmoothedSceneDepth = 1<<4;
72 }
73}
74
75#[cfg(feature = "objc2")]
76unsafe impl Encode for ARFrameSemantics {
77 const ENCODING: Encoding = NSUInteger::ENCODING;
78}
79
80#[cfg(feature = "objc2")]
81unsafe impl RefEncode for ARFrameSemantics {
82 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
83}
84
85#[cfg(feature = "objc2")]
90#[repr(transparent)]
91#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
92pub struct ARWorldAlignment(pub NSInteger);
93#[cfg(feature = "objc2")]
94impl ARWorldAlignment {
95 #[doc(alias = "ARWorldAlignmentGravity")]
97 pub const Gravity: Self = Self(0);
98 #[doc(alias = "ARWorldAlignmentGravityAndHeading")]
101 pub const GravityAndHeading: Self = Self(1);
102 #[doc(alias = "ARWorldAlignmentCamera")]
104 pub const Camera: Self = Self(2);
105}
106
107#[cfg(feature = "objc2")]
108unsafe impl Encode for ARWorldAlignment {
109 const ENCODING: Encoding = NSInteger::ENCODING;
110}
111
112#[cfg(feature = "objc2")]
113unsafe impl RefEncode for ARWorldAlignment {
114 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
115}
116
117#[cfg(feature = "objc2")]
122#[repr(transparent)]
123#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
124pub struct AREnvironmentTexturing(pub NSInteger);
125#[cfg(feature = "objc2")]
126impl AREnvironmentTexturing {
127 #[doc(alias = "AREnvironmentTexturingNone")]
129 pub const None: Self = Self(0);
130 #[doc(alias = "AREnvironmentTexturingManual")]
133 pub const Manual: Self = Self(1);
134 #[doc(alias = "AREnvironmentTexturingAutomatic")]
136 pub const Automatic: Self = Self(2);
137}
138
139#[cfg(feature = "objc2")]
140unsafe impl Encode for AREnvironmentTexturing {
141 const ENCODING: Encoding = NSInteger::ENCODING;
142}
143
144#[cfg(feature = "objc2")]
145unsafe impl RefEncode for AREnvironmentTexturing {
146 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
147}
148
149#[cfg(feature = "objc2")]
154#[repr(transparent)]
155#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
156pub struct ARSceneReconstruction(pub NSUInteger);
157#[cfg(feature = "objc2")]
158bitflags::bitflags! {
159 impl ARSceneReconstruction: NSUInteger {
160#[doc(alias = "ARSceneReconstructionNone")]
162 const None = 0;
163#[doc(alias = "ARSceneReconstructionMesh")]
165 const Mesh = 1<<0;
166#[doc(alias = "ARSceneReconstructionMeshWithClassification")]
168 const MeshWithClassification = (1<<1)|(1<<0);
169 }
170}
171
172#[cfg(feature = "objc2")]
173unsafe impl Encode for ARSceneReconstruction {
174 const ENCODING: Encoding = NSUInteger::ENCODING;
175}
176
177#[cfg(feature = "objc2")]
178unsafe impl RefEncode for ARSceneReconstruction {
179 const ENCODING_REF: Encoding = Encoding::Pointer(&Self::ENCODING);
180}
181
182#[cfg(feature = "objc2")]
183extern_class!(
184 #[unsafe(super(NSObject))]
188 #[derive(Debug, PartialEq, Eq, Hash)]
189 #[cfg(feature = "objc2")]
190 pub struct ARConfiguration;
191);
192
193#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
194extern_conformance!(
195 unsafe impl NSCopying for ARConfiguration {}
196);
197
198#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
199unsafe impl CopyingHelper for ARConfiguration {
200 type Result = Self;
201}
202
203#[cfg(feature = "objc2")]
204extern_conformance!(
205 unsafe impl NSObjectProtocol for ARConfiguration {}
206);
207
208#[cfg(feature = "objc2")]
209impl ARConfiguration {
210 extern_methods!(
211 #[unsafe(method(isSupported))]
213 #[unsafe(method_family = none)]
214 pub unsafe fn isSupported() -> bool;
215
216 #[cfg(all(feature = "ARVideoFormat", feature = "objc2-foundation"))]
217 #[unsafe(method(supportedVideoFormats))]
221 #[unsafe(method_family = none)]
222 pub unsafe fn supportedVideoFormats() -> Retained<NSArray<ARVideoFormat>>;
223
224 #[cfg(feature = "ARVideoFormat")]
225 #[unsafe(method(videoFormat))]
227 #[unsafe(method_family = none)]
228 pub unsafe fn videoFormat(&self) -> Retained<ARVideoFormat>;
229
230 #[cfg(feature = "ARVideoFormat")]
231 #[unsafe(method(setVideoFormat:))]
233 #[unsafe(method_family = none)]
234 pub unsafe fn setVideoFormat(&self, video_format: &ARVideoFormat);
235
236 #[unsafe(method(worldAlignment))]
240 #[unsafe(method_family = none)]
241 pub unsafe fn worldAlignment(&self) -> ARWorldAlignment;
242
243 #[unsafe(method(setWorldAlignment:))]
245 #[unsafe(method_family = none)]
246 pub unsafe fn setWorldAlignment(&self, world_alignment: ARWorldAlignment);
247
248 #[unsafe(method(isLightEstimationEnabled))]
252 #[unsafe(method_family = none)]
253 pub unsafe fn isLightEstimationEnabled(&self) -> bool;
254
255 #[unsafe(method(setLightEstimationEnabled:))]
257 #[unsafe(method_family = none)]
258 pub unsafe fn setLightEstimationEnabled(&self, light_estimation_enabled: bool);
259
260 #[unsafe(method(providesAudioData))]
264 #[unsafe(method_family = none)]
265 pub unsafe fn providesAudioData(&self) -> bool;
266
267 #[unsafe(method(setProvidesAudioData:))]
269 #[unsafe(method_family = none)]
270 pub unsafe fn setProvidesAudioData(&self, provides_audio_data: bool);
271
272 #[unsafe(method(frameSemantics))]
283 #[unsafe(method_family = none)]
284 pub unsafe fn frameSemantics(&self) -> ARFrameSemantics;
285
286 #[unsafe(method(setFrameSemantics:))]
288 #[unsafe(method_family = none)]
289 pub unsafe fn setFrameSemantics(&self, frame_semantics: ARFrameSemantics);
290
291 #[unsafe(method(supportsFrameSemantics:))]
301 #[unsafe(method_family = none)]
302 pub unsafe fn supportsFrameSemantics(frame_semantics: ARFrameSemantics) -> bool;
303
304 #[cfg(feature = "objc2-av-foundation")]
305 #[unsafe(method(configurableCaptureDeviceForPrimaryCamera))]
309 #[unsafe(method_family = none)]
310 pub unsafe fn configurableCaptureDeviceForPrimaryCamera(
311 ) -> Option<Retained<AVCaptureDevice>>;
312
313 #[cfg(feature = "ARVideoFormat")]
314 #[unsafe(method(recommendedVideoFormatFor4KResolution))]
318 #[unsafe(method_family = none)]
319 pub unsafe fn recommendedVideoFormatFor4KResolution() -> Option<Retained<ARVideoFormat>>;
320
321 #[cfg(feature = "ARVideoFormat")]
322 #[unsafe(method(recommendedVideoFormatForHighResolutionFrameCapturing))]
330 #[unsafe(method_family = none)]
331 pub unsafe fn recommendedVideoFormatForHighResolutionFrameCapturing(
332 ) -> Option<Retained<ARVideoFormat>>;
333
334 #[unsafe(method(videoHDRAllowed))]
337 #[unsafe(method_family = none)]
338 pub unsafe fn videoHDRAllowed(&self) -> bool;
339
340 #[unsafe(method(setVideoHDRAllowed:))]
342 #[unsafe(method_family = none)]
343 pub unsafe fn setVideoHDRAllowed(&self, video_hdr_allowed: bool);
344
345 #[unsafe(method(init))]
347 #[unsafe(method_family = init)]
348 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
349
350 #[unsafe(method(new))]
351 #[unsafe(method_family = new)]
352 pub unsafe fn new() -> Retained<Self>;
353 );
354}
355
356#[cfg(feature = "objc2")]
357extern_class!(
358 #[unsafe(super(ARConfiguration, NSObject))]
367 #[derive(Debug, PartialEq, Eq, Hash)]
368 #[cfg(feature = "objc2")]
369 pub struct ARWorldTrackingConfiguration;
370);
371
372#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
373extern_conformance!(
374 unsafe impl NSCopying for ARWorldTrackingConfiguration {}
375);
376
377#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
378unsafe impl CopyingHelper for ARWorldTrackingConfiguration {
379 type Result = Self;
380}
381
382#[cfg(feature = "objc2")]
383extern_conformance!(
384 unsafe impl NSObjectProtocol for ARWorldTrackingConfiguration {}
385);
386
387#[cfg(feature = "objc2")]
388impl ARWorldTrackingConfiguration {
389 extern_methods!(
390 #[unsafe(method(isAutoFocusEnabled))]
394 #[unsafe(method_family = none)]
395 pub unsafe fn isAutoFocusEnabled(&self) -> bool;
396
397 #[unsafe(method(setAutoFocusEnabled:))]
399 #[unsafe(method_family = none)]
400 pub unsafe fn setAutoFocusEnabled(&self, auto_focus_enabled: bool);
401
402 #[unsafe(method(environmentTexturing))]
408 #[unsafe(method_family = none)]
409 pub unsafe fn environmentTexturing(&self) -> AREnvironmentTexturing;
410
411 #[unsafe(method(setEnvironmentTexturing:))]
413 #[unsafe(method_family = none)]
414 pub unsafe fn setEnvironmentTexturing(&self, environment_texturing: AREnvironmentTexturing);
415
416 #[unsafe(method(wantsHDREnvironmentTextures))]
418 #[unsafe(method_family = none)]
419 pub unsafe fn wantsHDREnvironmentTextures(&self) -> bool;
420
421 #[unsafe(method(setWantsHDREnvironmentTextures:))]
423 #[unsafe(method_family = none)]
424 pub unsafe fn setWantsHDREnvironmentTextures(&self, wants_hdr_environment_textures: bool);
425
426 #[cfg(feature = "ARPlaneDetectionTypes")]
427 #[unsafe(method(planeDetection))]
432 #[unsafe(method_family = none)]
433 pub unsafe fn planeDetection(&self) -> ARPlaneDetection;
434
435 #[cfg(feature = "ARPlaneDetectionTypes")]
436 #[unsafe(method(setPlaneDetection:))]
438 #[unsafe(method_family = none)]
439 pub unsafe fn setPlaneDetection(&self, plane_detection: ARPlaneDetection);
440
441 #[cfg(feature = "ARWorldMap")]
442 #[unsafe(method(initialWorldMap))]
449 #[unsafe(method_family = none)]
450 pub unsafe fn initialWorldMap(&self) -> Option<Retained<ARWorldMap>>;
451
452 #[cfg(feature = "ARWorldMap")]
453 #[unsafe(method(setInitialWorldMap:))]
455 #[unsafe(method_family = none)]
456 pub unsafe fn setInitialWorldMap(&self, initial_world_map: Option<&ARWorldMap>);
457
458 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
459 #[unsafe(method(detectionImages))]
463 #[unsafe(method_family = none)]
464 pub unsafe fn detectionImages(&self) -> Retained<NSSet<ARReferenceImage>>;
465
466 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
467 #[unsafe(method(setDetectionImages:))]
471 #[unsafe(method_family = none)]
472 pub unsafe fn setDetectionImages(&self, detection_images: Option<&NSSet<ARReferenceImage>>);
473
474 #[unsafe(method(automaticImageScaleEstimationEnabled))]
481 #[unsafe(method_family = none)]
482 pub unsafe fn automaticImageScaleEstimationEnabled(&self) -> bool;
483
484 #[unsafe(method(setAutomaticImageScaleEstimationEnabled:))]
486 #[unsafe(method_family = none)]
487 pub unsafe fn setAutomaticImageScaleEstimationEnabled(
488 &self,
489 automatic_image_scale_estimation_enabled: bool,
490 );
491
492 #[unsafe(method(maximumNumberOfTrackedImages))]
498 #[unsafe(method_family = none)]
499 pub unsafe fn maximumNumberOfTrackedImages(&self) -> NSInteger;
500
501 #[unsafe(method(setMaximumNumberOfTrackedImages:))]
503 #[unsafe(method_family = none)]
504 pub unsafe fn setMaximumNumberOfTrackedImages(
505 &self,
506 maximum_number_of_tracked_images: NSInteger,
507 );
508
509 #[cfg(all(feature = "ARReferenceObject", feature = "objc2-foundation"))]
510 #[unsafe(method(detectionObjects))]
515 #[unsafe(method_family = none)]
516 pub unsafe fn detectionObjects(&self) -> Retained<NSSet<ARReferenceObject>>;
517
518 #[cfg(all(feature = "ARReferenceObject", feature = "objc2-foundation"))]
519 #[unsafe(method(setDetectionObjects:))]
523 #[unsafe(method_family = none)]
524 pub unsafe fn setDetectionObjects(&self, detection_objects: &NSSet<ARReferenceObject>);
525
526 #[unsafe(method(isCollaborationEnabled))]
533 #[unsafe(method_family = none)]
534 pub unsafe fn isCollaborationEnabled(&self) -> bool;
535
536 #[unsafe(method(setCollaborationEnabled:))]
538 #[unsafe(method_family = none)]
539 pub unsafe fn setCollaborationEnabled(&self, collaboration_enabled: bool);
540
541 #[unsafe(method(supportsUserFaceTracking))]
543 #[unsafe(method_family = none)]
544 pub unsafe fn supportsUserFaceTracking() -> bool;
545
546 #[unsafe(method(userFaceTrackingEnabled))]
555 #[unsafe(method_family = none)]
556 pub unsafe fn userFaceTrackingEnabled(&self) -> bool;
557
558 #[unsafe(method(setUserFaceTrackingEnabled:))]
560 #[unsafe(method_family = none)]
561 pub unsafe fn setUserFaceTrackingEnabled(&self, user_face_tracking_enabled: bool);
562
563 #[unsafe(method(appClipCodeTrackingEnabled))]
565 #[unsafe(method_family = none)]
566 pub unsafe fn appClipCodeTrackingEnabled(&self) -> bool;
567
568 #[unsafe(method(setAppClipCodeTrackingEnabled:))]
570 #[unsafe(method_family = none)]
571 pub unsafe fn setAppClipCodeTrackingEnabled(&self, app_clip_code_tracking_enabled: bool);
572
573 #[unsafe(method(supportsAppClipCodeTracking))]
575 #[unsafe(method_family = none)]
576 pub unsafe fn supportsAppClipCodeTracking() -> bool;
577
578 #[unsafe(method(supportsSceneReconstruction:))]
580 #[unsafe(method_family = none)]
581 pub unsafe fn supportsSceneReconstruction(
582 scene_reconstruction: ARSceneReconstruction,
583 ) -> bool;
584
585 #[unsafe(method(sceneReconstruction))]
592 #[unsafe(method_family = none)]
593 pub unsafe fn sceneReconstruction(&self) -> ARSceneReconstruction;
594
595 #[unsafe(method(setSceneReconstruction:))]
597 #[unsafe(method_family = none)]
598 pub unsafe fn setSceneReconstruction(&self, scene_reconstruction: ARSceneReconstruction);
599
600 #[unsafe(method(init))]
601 #[unsafe(method_family = init)]
602 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
603
604 #[unsafe(method(new))]
605 #[unsafe(method_family = new)]
606 pub unsafe fn new() -> Retained<Self>;
607 );
608}
609
610#[cfg(feature = "objc2")]
611extern_class!(
612 #[unsafe(super(ARConfiguration, NSObject))]
619 #[derive(Debug, PartialEq, Eq, Hash)]
620 #[cfg(feature = "objc2")]
621 pub struct AROrientationTrackingConfiguration;
622);
623
624#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
625extern_conformance!(
626 unsafe impl NSCopying for AROrientationTrackingConfiguration {}
627);
628
629#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
630unsafe impl CopyingHelper for AROrientationTrackingConfiguration {
631 type Result = Self;
632}
633
634#[cfg(feature = "objc2")]
635extern_conformance!(
636 unsafe impl NSObjectProtocol for AROrientationTrackingConfiguration {}
637);
638
639#[cfg(feature = "objc2")]
640impl AROrientationTrackingConfiguration {
641 extern_methods!(
642 #[unsafe(method(isAutoFocusEnabled))]
646 #[unsafe(method_family = none)]
647 pub unsafe fn isAutoFocusEnabled(&self) -> bool;
648
649 #[unsafe(method(setAutoFocusEnabled:))]
651 #[unsafe(method_family = none)]
652 pub unsafe fn setAutoFocusEnabled(&self, auto_focus_enabled: bool);
653
654 #[unsafe(method(init))]
655 #[unsafe(method_family = init)]
656 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
657
658 #[unsafe(method(new))]
659 #[unsafe(method_family = new)]
660 pub unsafe fn new() -> Retained<Self>;
661 );
662}
663
664#[cfg(feature = "objc2")]
665extern_class!(
666 #[unsafe(super(ARConfiguration, NSObject))]
675 #[derive(Debug, PartialEq, Eq, Hash)]
676 #[cfg(feature = "objc2")]
677 pub struct ARFaceTrackingConfiguration;
678);
679
680#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
681extern_conformance!(
682 unsafe impl NSCopying for ARFaceTrackingConfiguration {}
683);
684
685#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
686unsafe impl CopyingHelper for ARFaceTrackingConfiguration {
687 type Result = Self;
688}
689
690#[cfg(feature = "objc2")]
691extern_conformance!(
692 unsafe impl NSObjectProtocol for ARFaceTrackingConfiguration {}
693);
694
695#[cfg(feature = "objc2")]
696impl ARFaceTrackingConfiguration {
697 extern_methods!(
698 #[unsafe(method(supportedNumberOfTrackedFaces))]
700 #[unsafe(method_family = none)]
701 pub unsafe fn supportedNumberOfTrackedFaces() -> NSInteger;
702
703 #[unsafe(method(maximumNumberOfTrackedFaces))]
709 #[unsafe(method_family = none)]
710 pub unsafe fn maximumNumberOfTrackedFaces(&self) -> NSInteger;
711
712 #[unsafe(method(setMaximumNumberOfTrackedFaces:))]
714 #[unsafe(method_family = none)]
715 pub unsafe fn setMaximumNumberOfTrackedFaces(
716 &self,
717 maximum_number_of_tracked_faces: NSInteger,
718 );
719
720 #[unsafe(method(supportsWorldTracking))]
722 #[unsafe(method_family = none)]
723 pub unsafe fn supportsWorldTracking() -> bool;
724
725 #[unsafe(method(isWorldTrackingEnabled))]
731 #[unsafe(method_family = none)]
732 pub unsafe fn isWorldTrackingEnabled(&self) -> bool;
733
734 #[unsafe(method(setWorldTrackingEnabled:))]
736 #[unsafe(method_family = none)]
737 pub unsafe fn setWorldTrackingEnabled(&self, world_tracking_enabled: bool);
738
739 #[unsafe(method(init))]
740 #[unsafe(method_family = init)]
741 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
742
743 #[unsafe(method(new))]
744 #[unsafe(method_family = new)]
745 pub unsafe fn new() -> Retained<Self>;
746 );
747}
748
749#[cfg(feature = "objc2")]
750extern_class!(
751 #[unsafe(super(ARConfiguration, NSObject))]
758 #[derive(Debug, PartialEq, Eq, Hash)]
759 #[cfg(feature = "objc2")]
760 pub struct ARImageTrackingConfiguration;
761);
762
763#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
764extern_conformance!(
765 unsafe impl NSCopying for ARImageTrackingConfiguration {}
766);
767
768#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
769unsafe impl CopyingHelper for ARImageTrackingConfiguration {
770 type Result = Self;
771}
772
773#[cfg(feature = "objc2")]
774extern_conformance!(
775 unsafe impl NSObjectProtocol for ARImageTrackingConfiguration {}
776);
777
778#[cfg(feature = "objc2")]
779impl ARImageTrackingConfiguration {
780 extern_methods!(
781 #[unsafe(method(isAutoFocusEnabled))]
785 #[unsafe(method_family = none)]
786 pub unsafe fn isAutoFocusEnabled(&self) -> bool;
787
788 #[unsafe(method(setAutoFocusEnabled:))]
790 #[unsafe(method_family = none)]
791 pub unsafe fn setAutoFocusEnabled(&self, auto_focus_enabled: bool);
792
793 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
794 #[unsafe(method(trackingImages))]
796 #[unsafe(method_family = none)]
797 pub unsafe fn trackingImages(&self) -> Retained<NSSet<ARReferenceImage>>;
798
799 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
800 #[unsafe(method(setTrackingImages:))]
804 #[unsafe(method_family = none)]
805 pub unsafe fn setTrackingImages(&self, tracking_images: &NSSet<ARReferenceImage>);
806
807 #[unsafe(method(maximumNumberOfTrackedImages))]
813 #[unsafe(method_family = none)]
814 pub unsafe fn maximumNumberOfTrackedImages(&self) -> NSInteger;
815
816 #[unsafe(method(setMaximumNumberOfTrackedImages:))]
818 #[unsafe(method_family = none)]
819 pub unsafe fn setMaximumNumberOfTrackedImages(
820 &self,
821 maximum_number_of_tracked_images: NSInteger,
822 );
823
824 #[unsafe(method(init))]
825 #[unsafe(method_family = init)]
826 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
827
828 #[unsafe(method(new))]
829 #[unsafe(method_family = new)]
830 pub unsafe fn new() -> Retained<Self>;
831 );
832}
833
834#[cfg(feature = "objc2")]
835extern_class!(
836 #[unsafe(super(ARConfiguration, NSObject))]
845 #[derive(Debug, PartialEq, Eq, Hash)]
846 #[cfg(feature = "objc2")]
847 pub struct ARObjectScanningConfiguration;
848);
849
850#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
851extern_conformance!(
852 unsafe impl NSCopying for ARObjectScanningConfiguration {}
853);
854
855#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
856unsafe impl CopyingHelper for ARObjectScanningConfiguration {
857 type Result = Self;
858}
859
860#[cfg(feature = "objc2")]
861extern_conformance!(
862 unsafe impl NSObjectProtocol for ARObjectScanningConfiguration {}
863);
864
865#[cfg(feature = "objc2")]
866impl ARObjectScanningConfiguration {
867 extern_methods!(
868 #[unsafe(method(isAutoFocusEnabled))]
872 #[unsafe(method_family = none)]
873 pub unsafe fn isAutoFocusEnabled(&self) -> bool;
874
875 #[unsafe(method(setAutoFocusEnabled:))]
877 #[unsafe(method_family = none)]
878 pub unsafe fn setAutoFocusEnabled(&self, auto_focus_enabled: bool);
879
880 #[cfg(feature = "ARPlaneDetectionTypes")]
881 #[unsafe(method(planeDetection))]
886 #[unsafe(method_family = none)]
887 pub unsafe fn planeDetection(&self) -> ARPlaneDetection;
888
889 #[cfg(feature = "ARPlaneDetectionTypes")]
890 #[unsafe(method(setPlaneDetection:))]
892 #[unsafe(method_family = none)]
893 pub unsafe fn setPlaneDetection(&self, plane_detection: ARPlaneDetection);
894
895 #[unsafe(method(init))]
896 #[unsafe(method_family = init)]
897 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
898
899 #[unsafe(method(new))]
900 #[unsafe(method_family = new)]
901 pub unsafe fn new() -> Retained<Self>;
902 );
903}
904
905#[cfg(feature = "objc2")]
906extern_class!(
907 #[unsafe(super(ARConfiguration, NSObject))]
919 #[derive(Debug, PartialEq, Eq, Hash)]
920 #[cfg(feature = "objc2")]
921 pub struct ARBodyTrackingConfiguration;
922);
923
924#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
925extern_conformance!(
926 unsafe impl NSCopying for ARBodyTrackingConfiguration {}
927);
928
929#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
930unsafe impl CopyingHelper for ARBodyTrackingConfiguration {
931 type Result = Self;
932}
933
934#[cfg(feature = "objc2")]
935extern_conformance!(
936 unsafe impl NSObjectProtocol for ARBodyTrackingConfiguration {}
937);
938
939#[cfg(feature = "objc2")]
940impl ARBodyTrackingConfiguration {
941 extern_methods!(
942 #[unsafe(method(isAutoFocusEnabled))]
946 #[unsafe(method_family = none)]
947 pub unsafe fn isAutoFocusEnabled(&self) -> bool;
948
949 #[unsafe(method(setAutoFocusEnabled:))]
951 #[unsafe(method_family = none)]
952 pub unsafe fn setAutoFocusEnabled(&self, auto_focus_enabled: bool);
953
954 #[cfg(feature = "ARWorldMap")]
955 #[unsafe(method(initialWorldMap))]
962 #[unsafe(method_family = none)]
963 pub unsafe fn initialWorldMap(&self) -> Option<Retained<ARWorldMap>>;
964
965 #[cfg(feature = "ARWorldMap")]
966 #[unsafe(method(setInitialWorldMap:))]
968 #[unsafe(method_family = none)]
969 pub unsafe fn setInitialWorldMap(&self, initial_world_map: Option<&ARWorldMap>);
970
971 #[unsafe(method(environmentTexturing))]
977 #[unsafe(method_family = none)]
978 pub unsafe fn environmentTexturing(&self) -> AREnvironmentTexturing;
979
980 #[unsafe(method(setEnvironmentTexturing:))]
982 #[unsafe(method_family = none)]
983 pub unsafe fn setEnvironmentTexturing(&self, environment_texturing: AREnvironmentTexturing);
984
985 #[unsafe(method(wantsHDREnvironmentTextures))]
987 #[unsafe(method_family = none)]
988 pub unsafe fn wantsHDREnvironmentTextures(&self) -> bool;
989
990 #[unsafe(method(setWantsHDREnvironmentTextures:))]
992 #[unsafe(method_family = none)]
993 pub unsafe fn setWantsHDREnvironmentTextures(&self, wants_hdr_environment_textures: bool);
994
995 #[cfg(feature = "ARPlaneDetectionTypes")]
996 #[unsafe(method(planeDetection))]
1001 #[unsafe(method_family = none)]
1002 pub unsafe fn planeDetection(&self) -> ARPlaneDetection;
1003
1004 #[cfg(feature = "ARPlaneDetectionTypes")]
1005 #[unsafe(method(setPlaneDetection:))]
1007 #[unsafe(method_family = none)]
1008 pub unsafe fn setPlaneDetection(&self, plane_detection: ARPlaneDetection);
1009
1010 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
1011 #[unsafe(method(detectionImages))]
1015 #[unsafe(method_family = none)]
1016 pub unsafe fn detectionImages(&self) -> Retained<NSSet<ARReferenceImage>>;
1017
1018 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
1019 #[unsafe(method(setDetectionImages:))]
1023 #[unsafe(method_family = none)]
1024 pub unsafe fn setDetectionImages(&self, detection_images: &NSSet<ARReferenceImage>);
1025
1026 #[unsafe(method(automaticImageScaleEstimationEnabled))]
1033 #[unsafe(method_family = none)]
1034 pub unsafe fn automaticImageScaleEstimationEnabled(&self) -> bool;
1035
1036 #[unsafe(method(setAutomaticImageScaleEstimationEnabled:))]
1038 #[unsafe(method_family = none)]
1039 pub unsafe fn setAutomaticImageScaleEstimationEnabled(
1040 &self,
1041 automatic_image_scale_estimation_enabled: bool,
1042 );
1043
1044 #[unsafe(method(automaticSkeletonScaleEstimationEnabled))]
1051 #[unsafe(method_family = none)]
1052 pub unsafe fn automaticSkeletonScaleEstimationEnabled(&self) -> bool;
1053
1054 #[unsafe(method(setAutomaticSkeletonScaleEstimationEnabled:))]
1056 #[unsafe(method_family = none)]
1057 pub unsafe fn setAutomaticSkeletonScaleEstimationEnabled(
1058 &self,
1059 automatic_skeleton_scale_estimation_enabled: bool,
1060 );
1061
1062 #[unsafe(method(maximumNumberOfTrackedImages))]
1068 #[unsafe(method_family = none)]
1069 pub unsafe fn maximumNumberOfTrackedImages(&self) -> NSInteger;
1070
1071 #[unsafe(method(setMaximumNumberOfTrackedImages:))]
1073 #[unsafe(method_family = none)]
1074 pub unsafe fn setMaximumNumberOfTrackedImages(
1075 &self,
1076 maximum_number_of_tracked_images: NSInteger,
1077 );
1078
1079 #[unsafe(method(appClipCodeTrackingEnabled))]
1081 #[unsafe(method_family = none)]
1082 pub unsafe fn appClipCodeTrackingEnabled(&self) -> bool;
1083
1084 #[unsafe(method(setAppClipCodeTrackingEnabled:))]
1086 #[unsafe(method_family = none)]
1087 pub unsafe fn setAppClipCodeTrackingEnabled(&self, app_clip_code_tracking_enabled: bool);
1088
1089 #[unsafe(method(supportsAppClipCodeTracking))]
1091 #[unsafe(method_family = none)]
1092 pub unsafe fn supportsAppClipCodeTracking() -> bool;
1093
1094 #[unsafe(method(init))]
1095 #[unsafe(method_family = init)]
1096 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
1097
1098 #[unsafe(method(new))]
1099 #[unsafe(method_family = new)]
1100 pub unsafe fn new() -> Retained<Self>;
1101 );
1102}
1103
1104#[cfg(feature = "objc2")]
1105extern_class!(
1106 #[unsafe(super(ARConfiguration, NSObject))]
1114 #[derive(Debug, PartialEq, Eq, Hash)]
1115 #[cfg(feature = "objc2")]
1116 pub struct ARPositionalTrackingConfiguration;
1117);
1118
1119#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
1120extern_conformance!(
1121 unsafe impl NSCopying for ARPositionalTrackingConfiguration {}
1122);
1123
1124#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
1125unsafe impl CopyingHelper for ARPositionalTrackingConfiguration {
1126 type Result = Self;
1127}
1128
1129#[cfg(feature = "objc2")]
1130extern_conformance!(
1131 unsafe impl NSObjectProtocol for ARPositionalTrackingConfiguration {}
1132);
1133
1134#[cfg(feature = "objc2")]
1135impl ARPositionalTrackingConfiguration {
1136 extern_methods!(
1137 #[cfg(feature = "ARPlaneDetectionTypes")]
1138 #[unsafe(method(planeDetection))]
1143 #[unsafe(method_family = none)]
1144 pub unsafe fn planeDetection(&self) -> ARPlaneDetection;
1145
1146 #[cfg(feature = "ARPlaneDetectionTypes")]
1147 #[unsafe(method(setPlaneDetection:))]
1149 #[unsafe(method_family = none)]
1150 pub unsafe fn setPlaneDetection(&self, plane_detection: ARPlaneDetection);
1151
1152 #[cfg(feature = "ARWorldMap")]
1153 #[unsafe(method(initialWorldMap))]
1160 #[unsafe(method_family = none)]
1161 pub unsafe fn initialWorldMap(&self) -> Option<Retained<ARWorldMap>>;
1162
1163 #[cfg(feature = "ARWorldMap")]
1164 #[unsafe(method(setInitialWorldMap:))]
1166 #[unsafe(method_family = none)]
1167 pub unsafe fn setInitialWorldMap(&self, initial_world_map: Option<&ARWorldMap>);
1168
1169 #[unsafe(method(init))]
1170 #[unsafe(method_family = init)]
1171 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
1172
1173 #[unsafe(method(new))]
1174 #[unsafe(method_family = new)]
1175 pub unsafe fn new() -> Retained<Self>;
1176 );
1177}
1178
1179#[cfg(feature = "objc2")]
1180extern_class!(
1181 #[unsafe(super(ARConfiguration, NSObject))]
1188 #[derive(Debug, PartialEq, Eq, Hash)]
1189 #[cfg(feature = "objc2")]
1190 pub struct ARGeoTrackingConfiguration;
1191);
1192
1193#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
1194extern_conformance!(
1195 unsafe impl NSCopying for ARGeoTrackingConfiguration {}
1196);
1197
1198#[cfg(all(feature = "objc2", feature = "objc2-foundation"))]
1199unsafe impl CopyingHelper for ARGeoTrackingConfiguration {
1200 type Result = Self;
1201}
1202
1203#[cfg(feature = "objc2")]
1204extern_conformance!(
1205 unsafe impl NSObjectProtocol for ARGeoTrackingConfiguration {}
1206);
1207
1208#[cfg(feature = "objc2")]
1209impl ARGeoTrackingConfiguration {
1210 extern_methods!(
1211 #[unsafe(method(worldAlignment))]
1213 #[unsafe(method_family = none)]
1214 pub unsafe fn worldAlignment(&self) -> ARWorldAlignment;
1215
1216 #[unsafe(method(setWorldAlignment:))]
1218 #[unsafe(method_family = none)]
1219 pub unsafe fn setWorldAlignment(&self, world_alignment: ARWorldAlignment);
1220
1221 #[unsafe(method(environmentTexturing))]
1227 #[unsafe(method_family = none)]
1228 pub unsafe fn environmentTexturing(&self) -> AREnvironmentTexturing;
1229
1230 #[unsafe(method(setEnvironmentTexturing:))]
1232 #[unsafe(method_family = none)]
1233 pub unsafe fn setEnvironmentTexturing(&self, environment_texturing: AREnvironmentTexturing);
1234
1235 #[unsafe(method(wantsHDREnvironmentTextures))]
1237 #[unsafe(method_family = none)]
1238 pub unsafe fn wantsHDREnvironmentTextures(&self) -> bool;
1239
1240 #[unsafe(method(setWantsHDREnvironmentTextures:))]
1242 #[unsafe(method_family = none)]
1243 pub unsafe fn setWantsHDREnvironmentTextures(&self, wants_hdr_environment_textures: bool);
1244
1245 #[cfg(feature = "ARPlaneDetectionTypes")]
1246 #[unsafe(method(planeDetection))]
1251 #[unsafe(method_family = none)]
1252 pub unsafe fn planeDetection(&self) -> ARPlaneDetection;
1253
1254 #[cfg(feature = "ARPlaneDetectionTypes")]
1255 #[unsafe(method(setPlaneDetection:))]
1257 #[unsafe(method_family = none)]
1258 pub unsafe fn setPlaneDetection(&self, plane_detection: ARPlaneDetection);
1259
1260 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
1261 #[unsafe(method(detectionImages))]
1265 #[unsafe(method_family = none)]
1266 pub unsafe fn detectionImages(&self) -> Retained<NSSet<ARReferenceImage>>;
1267
1268 #[cfg(all(feature = "ARReferenceImage", feature = "objc2-foundation"))]
1269 #[unsafe(method(setDetectionImages:))]
1273 #[unsafe(method_family = none)]
1274 pub unsafe fn setDetectionImages(&self, detection_images: Option<&NSSet<ARReferenceImage>>);
1275
1276 #[unsafe(method(automaticImageScaleEstimationEnabled))]
1283 #[unsafe(method_family = none)]
1284 pub unsafe fn automaticImageScaleEstimationEnabled(&self) -> bool;
1285
1286 #[unsafe(method(setAutomaticImageScaleEstimationEnabled:))]
1288 #[unsafe(method_family = none)]
1289 pub unsafe fn setAutomaticImageScaleEstimationEnabled(
1290 &self,
1291 automatic_image_scale_estimation_enabled: bool,
1292 );
1293
1294 #[unsafe(method(maximumNumberOfTrackedImages))]
1300 #[unsafe(method_family = none)]
1301 pub unsafe fn maximumNumberOfTrackedImages(&self) -> NSInteger;
1302
1303 #[unsafe(method(setMaximumNumberOfTrackedImages:))]
1305 #[unsafe(method_family = none)]
1306 pub unsafe fn setMaximumNumberOfTrackedImages(
1307 &self,
1308 maximum_number_of_tracked_images: NSInteger,
1309 );
1310
1311 #[cfg(all(feature = "ARReferenceObject", feature = "objc2-foundation"))]
1312 #[unsafe(method(detectionObjects))]
1317 #[unsafe(method_family = none)]
1318 pub unsafe fn detectionObjects(&self) -> Retained<NSSet<ARReferenceObject>>;
1319
1320 #[cfg(all(feature = "ARReferenceObject", feature = "objc2-foundation"))]
1321 #[unsafe(method(setDetectionObjects:))]
1325 #[unsafe(method_family = none)]
1326 pub unsafe fn setDetectionObjects(&self, detection_objects: &NSSet<ARReferenceObject>);
1327
1328 #[unsafe(method(appClipCodeTrackingEnabled))]
1330 #[unsafe(method_family = none)]
1331 pub unsafe fn appClipCodeTrackingEnabled(&self) -> bool;
1332
1333 #[unsafe(method(setAppClipCodeTrackingEnabled:))]
1335 #[unsafe(method_family = none)]
1336 pub unsafe fn setAppClipCodeTrackingEnabled(&self, app_clip_code_tracking_enabled: bool);
1337
1338 #[unsafe(method(supportsAppClipCodeTracking))]
1340 #[unsafe(method_family = none)]
1341 pub unsafe fn supportsAppClipCodeTracking() -> bool;
1342
1343 #[cfg(all(feature = "block2", feature = "objc2-foundation"))]
1344 #[unsafe(method(checkAvailabilityWithCompletionHandler:))]
1354 #[unsafe(method_family = none)]
1355 pub unsafe fn checkAvailabilityWithCompletionHandler(
1356 completion_handler: &block2::DynBlock<dyn Fn(Bool, *mut NSError)>,
1357 );
1358
1359 #[cfg(all(
1360 feature = "block2",
1361 feature = "objc2-core-location",
1362 feature = "objc2-foundation"
1363 ))]
1364 #[unsafe(method(checkAvailabilityAtCoordinate:completionHandler:))]
1372 #[unsafe(method_family = none)]
1373 pub unsafe fn checkAvailabilityAtCoordinate_completionHandler(
1374 coordinate: CLLocationCoordinate2D,
1375 completion_handler: &block2::DynBlock<dyn Fn(Bool, *mut NSError)>,
1376 );
1377
1378 #[unsafe(method(init))]
1379 #[unsafe(method_family = init)]
1380 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
1381
1382 #[unsafe(method(new))]
1383 #[unsafe(method_family = new)]
1384 pub unsafe fn new() -> Retained<Self>;
1385 );
1386}