iter-png-2/claude-opus-4-5 / tier-2-offset-handle-mug
success tier 2
bare (claude opus 4.5)
render
// Mug parameters
outer_diameter = 80;
inner_diameter = 70;
mug_height = 90;
bottom_thickness = 6;
wall_thickness = 5;
// Handle parameters
handle_inner_height = 30;
handle_inner_width = 25;
handle_thickness = 12;
// Derived values
outer_radius = outer_diameter / 2;
inner_radius = inner_diameter / 2;
// Handle position (centered vertically)
handle_center_z = mug_height / 2;
module mug_body() {
difference() {
// Outer cylinder
cylinder(h = mug_height, r = outer_radius, $fn = 100);
// Inner cavity (hollow part for liquid)
translate([0, 0, bottom_thickness])
cylinder(h = mug_height - bottom_thickness + 1, r = inner_radius, $fn = 100);
}
}
module handle() {
// Handle creates a D-shape with specified inner dimensions
// Inner space: 30mm height x 25mm width
// Start position slightly inside the mug wall for solid connection
start_x = outer_radius - 3;
translate([start_x, 0, handle_center_z]) {
// Top horizontal bar
translate([0, 0, handle_inner_height/2 + handle_thickness/2])
rotate([0, 90, 0])
cylinder(h = handle_inner_width + 3, r = handle_thickness/2, $fn = 30);
// Bottom horizontal bar
translate([0, 0, -handle_inner_height/2 - handle_thickness/2])
rotate([0, 90, 0])
cylinder(h = handle_inner_width + 3, r = handle_thickness/2, $fn = 30);
// Outer curved part (semi-circle connecting top and bottom)
translate([handle_inner_width + 3, 0, 0])
rotate([0, 0, -90])
rotate_extrude(angle = 180, $fn = 60)
translate([handle_inner_height/2 + handle_thickness/2, 0, 0])
circle(r = handle_thickness/2, $fn = 30);
// Smooth joint spheres at corners
translate([handle_inner_width + 3, 0, handle_inner_height/2 + handle_thickness/2])
sphere(r = handle_thickness/2, $fn = 30);
translate([handle_inner_width + 3, 0, -handle_inner_height/2 - handle_thickness/2])
sphere(r = handle_thickness/2, $fn = 30);
}
// Additional connection blocks to ensure solid attachment to mug body
translate([outer_radius - 5, -handle_thickness/2, handle_center_z - handle_inner_height/2 - handle_thickness])
cube([8, handle_thickness, handle_thickness]);
translate([outer_radius - 5, -handle_thickness/2, handle_center_z + handle_inner_height/2])
cube([8, handle_thickness, handle_thickness]);
}
// Final mug assembly
union() {
mug_body();
handle();
} パラメータ (8) —
スライダを動かすと openscad-wasm で再レンダリング
iteration chain
各 iteration step は独立した benchmark run です。parentRunId で前段にリンクします。
← parent
iter-png-1/claude-opus-4-5 success → children (1)
prompt
OpenSCAD で、向きが指定されたマグカップを作ってください。 本体: - 外径 80mm、内径 70mm(肉厚 5mm)、高さ 90mm の円筒形マグ - 底面の厚みは 6mm - 内側は飲み物を入れられるよう中空 取手(handle): - マグの **+X 軸方向の側面のみ** に付ける(他の方向には付けない) - 取手は D 字形状(外側が半円、本体側が直線)で、本体外周にしっかり接続する - 取手の内側の空間は高さ 30mm × 幅 25mm(指 3 本ぐらい入る) - 取手はマグの高さ方向の中央付近に付ける - 本体と取手は確実に union され、マニフォールド(隙間や宙吊りなし)を保つ 完成したコード全体を ```openscad ... ``` のフェンスで囲んで出力してください。コードのみで、追加の説明は不要です。