Paket model.glb + scene.json + textures (renderer-neutral, doc/RENDER-SZENE.md): Kamera der 3D-Ansicht, Sonne aus dem Sonnenstand, PBR-Materialtabelle mit Glas und ambientCG-Karten (Box-Projektion ohne UVs). scripts/blender/render_dossier.py (Cycles, Himmel mit Sonne, Denoiser, GPU/Metal wenn vorhanden). Dialog "Rendering mit Blender" (Befehl rendering, Menue Ansicht, Pfad in den Einstellungen), Fortschritt, Abbrechen, Speichern; Tauri blender.rs + Capabilities, Electron electron-blender.cjs, Browser: ZIP. CLI: render --out bild.png [--view --when --samples --size --cpu --blender]. Nicht in der Tauri-App/auf dem Mac geprueft.
29 lines
980 B
TypeScript
29 lines
980 B
TypeScript
// [211] Rendering mit Blender — öffnet den Dialog (in App montiert) und endet sofort; Muster `presentation`.
|
|
|
|
import { openRenderDialog } from "../../state/renderDialogHook";
|
|
import type { Command, CommandResult, CommandState } from "../types";
|
|
|
|
const IDLE: CommandState = { phase: "idle", lastPoint: null };
|
|
|
|
function open(): [CommandState, CommandResult] {
|
|
openRenderDialog();
|
|
return [{ ...IDLE }, { draft: null, done: true }];
|
|
}
|
|
|
|
export const renderingCommand: Command = {
|
|
name: "rendering",
|
|
labelKey: "cmd.rendering.label",
|
|
prompt: () => "cmd.rendering.prompt",
|
|
accepts: () => [],
|
|
options: () => [],
|
|
init: () => ({ ...IDLE }),
|
|
autoRun: (): CommandResult => {
|
|
openRenderDialog();
|
|
return { draft: null, done: true };
|
|
},
|
|
onInput: () => open(),
|
|
onMove: (state): [CommandState, CommandResult] => [state, { draft: null }],
|
|
onConfirm: () => open(),
|
|
onCancel: (): [CommandState, CommandResult] => [{ ...IDLE }, { draft: null, done: true }],
|
|
};
|