vibe-openscad

bare/gemini-2.5-flash / tier-1-mug

success tier 1

bare (gemini 2.5 flash)

render
bare render of tier-1-mug
loading STL…
success 27.5s · 142/609t · $0.0016
SCAD (56 lines)
// 定数定義
D_outer = 80;    // 外径
H_cup = 100;     // 高さ
thickness_wall = 4; // 肉厚
thickness_bottom = 6; // 底面の厚み

R_handle_tube = 12; // 取手のチューブの半径 (取手自体の半径)
D_finger_hole = 40; // 指が通る穴の直径 (適当な値、調整可能)

// 半径計算
R_outer = D_outer / 2;
R_inner = R_outer - thickness_wall;
R_finger_hole = D_finger_hole / 2;

// マグカップ本体
module mug_body() {
    difference() {
        // 外側の円筒
        cylinder(h = H_cup, r = R_outer, center = false, $fn = 60);

        // 内側をくり抜く円筒
        translate([0, 0, thickness_bottom]) {
            cylinder(h = H_cup - thickness_bottom, r = R_inner, center = false, $fn = 60);
        }
    }
}

// 取手
module handle() {
    // torusのr1は、チューブ中心が描く円の半径
    // torusのr2は、チューブ自体の半径 (R_handle_tube)
    // r1 = 指が通る穴の半径 + チューブの半径
    handle_torus_r1 = R_finger_hole + R_handle_tube;

    // 取手の中心X座標
    // カップの中心から: カップの外側半径 + 指が通る穴の半径 + チューブの半径
    handle_pos_x = R_outer + R_finger_hole + R_handle_tube;

    // 取手の中心Z座標 (カップの高さの中心)
    handle_pos_z = H_cup / 2;

    // torusはデフォルトでXY平面にリングの中心が来てZ軸に穴が開く。
    // これをY軸周りに90度回転させることで、穴がY軸を向き、リングがX軸方向に飛び出す形にする。
    // その後、所定の位置に平行移動する。
    translate([handle_pos_x, 0, handle_pos_z]) {
        rotate([0, 90, 0]) {
            torus(r = handle_torus_r1, r2 = R_handle_tube, $fn = 60);
        }
    }
}

// 全体を結合
union() {
    mug_body();
    handle();
}
パラメータ (6)
スライダを動かすと openscad-wasm で再レンダリング

meta

runIdbare_gemini-2.5-flash-b817591b4eb4-2026-04-26T19-03-24-157Z
matrixIdbare/gemini-2.5-flash
signatureb817591b4eb49e57…
providergoogle
modelgemini-2.5-flash
harnessbare
statussuccess
duration27.48s (wallclock: load + prompt eval + generation + network)
tokens142 in / 609 out
wallclock tok/s22.2 tok/s (end-to-end)
cost$0.0016
createdAt2026-04-26T19:03:24.157Z
openscadOpenSCAD version 2026.04.27

iteration chain

各 iteration step は独立した benchmark run です。parentRunId で前段にリンクします。

prompt

OpenSCAD で、外径 80mm、高さ 100mm、肉厚 4mm のマグカップを作ってください。
底面の厚みは 6mm とし、内側はくり抜いて飲み物を入れられる形状にしてください。
さらに、側面には外径方向に飛び出す半径 12mm の取手(リング状の取手)を付けてください。
取手はカップの中心高さあたりに付け、外周から十分にはみ出して指を通せる形にしてください。

完成したコード全体を ```openscad ... ``` のフェンスで囲んで出力してください。コードのみで、追加の説明は不要です。