Skip to content

Instantly share code, notes, and snippets.

View sherbondy's full-sized avatar

Ethan Sherbondy sherbondy

View GitHub Profile
@greenstevester
greenstevester / how-to-setup-ollama-on-a-macmini.md
Last active April 11, 2026 20:53
April 2026 TLDR setup for Ollama + Gemma 4 12B on a Mac mini (Apple Silicon) — auto-start, preload, and keep-alive

April 2026 TLDR setup for Ollama + Gemma 4 on a Mac mini (Apple Silicon) — auto-start, preload, and keep-alive

April 2026 TLDR Setup for Ollama + Gemma 4 on a Mac mini (Apple Silicon)

Prerequisites

  • Mac mini with Apple Silicon (M1/M2/M3/M4/M5)
  • At least 16GB unified memory for Gemma 4 (default 8B)
  • macOS with Homebrew installed
@Matt54
Matt54 / ImmersiveLaserPenMeasurementView.swift
Created October 27, 2025 03:20
Logitech Muse Laser Pen Scene Measurement (RealityKit & ARKit)
import ARKit
import CoreHaptics
import GameController
import RealityKit
import SwiftUI
struct ImmersiveLaserPenMeasurementView: View {
@State private var stylusManager = StylusLaserPenManager()
var body: some View {
@Matt54
Matt54 / AppModel.swift
Created October 24, 2025 03:05
Logitech Muse for Apple Vision Pro Tracking, Action Buttons, and Haptics in RealityKit
import SwiftUI
@MainActor
@Observable
class AppModel {
let immersiveSpaceID = "ImmersiveSpace"
enum ImmersiveSpaceState {
case closed
case inTransition
case open
@Matt54
Matt54 / EasingCurve.swift
Created October 2, 2025 04:22
RealityKit SDF Falling Sand Animation (Metal + LowLevelMesh + Marching Cubes)
import Foundation
enum EasingCurve {
case linear
case easeIn(Float)
case easeOut(Float)
case easeInOut(Float)
func apply(_ t: Float) -> Float {
let t = max(0, min(1, t))
@Matt54
Matt54 / SDFPrimitives.metal
Created August 13, 2025 03:45
LowLevelMesh shape shifting with Marching Cubes and SDF interpolation
#include <metal_stdlib>
using namespace metal;
#define SDFShapeTypeSphere 0u
#define SDFShapeTypeBox 1u
#define SDFShapeTypeTorus 2u
#define SDFShapeTypeRoundedBox 3u
#define SDFShapeTypeBoxFrame 4u
#define SDFShapeTypeLink 5u
#define SDFShapeTypeOctahedron 6u

visionOS 26 Beta 5 to Beta 6 Changelog (Made with Claude)

Issues Resolved (Moved from Known Issues to Resolved Issues)

EyeSight

  • Fixed: EyeSight not displaying content even when observer is present (155800405)

Foundation Models Framework

  • Fixed: Model requests erroneously throwing guardrailViolation when model assets not fully downloaded (156223847)
@Matt54
Matt54 / HeightMapParams.h
Last active June 18, 2025 12:19
RealityKit HeightMap Image to Terrain with LowLevelMesh and LowLevelTexture
#ifndef HeightMapParams_h
#define HeightMapParams_h
struct HeightMapParams {
simd_float2 size;
simd_uint2 dimensions;
};
#endif /* HeightMapParams_h */
if (new URLSearchParams(window.location.search).get('portal')) {
// <create start portal>
// Create portal group to contain all portal elements
const startPortalGroup = new THREE.Group();
startPortalGroup.position.set(SPAWN_POINT_X, SPAWN_POINT_Y, SPAWN_POINT_Z);
startPortalGroup.rotation.x = 0.35;
startPortalGroup.rotation.y = 0;
// Create portal effect
@ZekeSnider
ZekeSnider / ModelMonitor.swift
Created January 14, 2025 07:05
SwiftData Model Monitor
import Foundation
import SwiftData
import WidgetKit
import os
@ModelActor final actor DataMonitor {
private var logger: Logger {
Loggable.getLogger(Self.self)
}
@Matt54
Matt54 / DiscoBallRealityView.swift
Created June 22, 2024 23:14
A rotating disco ball RealityView created from a LowLevelMesh
import RealityKit
import SwiftUI
struct DiscoBallRealityView: View {
@State private var currentEntity: Entity?
@State private var morphFactor: Float = 0.0
@State private var frameDuration: TimeInterval = 0.0
@State private var lastUpdateTime = CACurrentMediaTime()
static let animationFrameDuration: TimeInterval = 1.0 / 120.0