Skip to content

Instantly share code, notes, and snippets.

View AKosmachyov's full-sized avatar
👋

Aliaksandr Kasmachou AKosmachyov

👋
View GitHub Profile
@AKosmachyov
AKosmachyov / Readme.md
Created April 5, 2025 19:02
SceneKit Orbit Control

SCNOrbitControl

SCNOrbitControl is a lightweight and flexible alternative to SCNView.allowsCameraControl, allowing you to define a custom camera orbit behavior around any node in your SceneKit scene. Perfect for apps with multiple focusable 3D objects.

✨ Features

  • 🎯 Set your own target node — no more relying on the scene center.
  • 🎥 Compatible with SCNCameraController via defaultCameraController.
  • 🧠 Keeps your camera logic decoupled from the view.
  • 👆 Simple gesture setup for pan and zoom.