// Family Room Furniture include use use $content_selected="none"; // [all,footstool,small_round_table, large_round_table, wing_back_chair, entertainment_cabinet, nesting_tables_1, nesting_tables_2, nesting_tables_3, receiver, tv, half_oval_cabinet, subwoofer, torchiere, frames, couch, couch_end_double, couch_corner, couch_double, couch_end_single] contents() { item("footstool") footstool(); item("small_round_table") rotate(-90) small_round_table(); item("large_round_table") large_round_table(); item("wing_back_chair", distance=180, z=25) wingbackchair(); item("entertainment_cabinet") entcabinet(); item("nesting_tables", zrot=60) nestingtables(); item("nesting_tables_1", png=false) nestingtable_1(); item("nesting_tables_2", png=false) nestingtable_2(); item("nesting_tables_3", png=false) nestingtable_3(); item("receiver") receiver(); item("tv") tv(); item("half_oval_cabinet", distance=120) halfovalcabinet(); item("subwoofer") subwoofer(); item("torchiere") torchiere(); item("torchiere-base", png=false) torchiere_base(); item("torchiere-shaft", png=false) torchiere_shaft(); item("torchiere-top", png=false) torchiere_top(); item("frames") frames(); item("couch_end_double", png=false) couch_end_double(end="L"); item("couch_double", png=false) couch_double(); item("couch_corner", png=false) couch_corner(); item("couch_end_single", png=false) couch_end_single(end="R", w=23*inch); item("couch") couch(); } // Small round table module small_round_table() { color("SaddleBrown") roundtable(t=1*inch, h=25.5*inch, d=24*inch, oh=1.75*inch, skirt=5.5*inch, nleg=4, leg=2*inch, leg_inset=1.25*inch, leg_type="square", drawer_h = 4*inch, drawer_z = 0.75*inch, drawer_knob = 1*inch, drawers=[ [ 45, 0, 13*inch ] ] ); } // large round table module large_round_table() { color("SaddleBrown") roundtable(t=1*inch, h=19.5*inch, d=40*inch, oh=1.75*inch, skirt=5.5*inch, nleg=4, leg=2*inch, leg_inset=1.25*inch, leg_type="square", drawer_h = 4*inch, drawer_z = 0.75*inch, drawer_knob = 1*inch, drawers=[ [ 45, -6.5*inch, 12*inch ], [ 45, 6.5*inch, 12*inch ], [ 135, -6.5*inch, 12*inch ], [ 135, 6.5*inch, 12*inch ], [ 225, -6.5*inch, 12*inch ], [ 225, 6.5*inch, 12*inch ], [ 315, -6.5*inch, 12*inch ], [ 315, 6.5*inch, 12*inch ] ] ); } // | d | // |-----------------| // | || <=bd2 // |----sd---|--bd1--| // ct // /--/ // // ..._ --- --- // ; / | | | // ; / | | | // ; / | |bh | // --- .........:../ | | | h // ct| : : / | | | // --- :---------:/ | --- | // | | |sh | // | | | | // +-----------------+ --- --- couch_color = "steelblue"; couch_h = 33.5*inch; couch_d = 36*inch; couch_seat_h = 10*inch; // approx, actually higher at front and lower at back couch_seat_d = 25*inch; couch_back_d1 = couch_d - couch_seat_d; // at base couch_back_d2 = 3*inch; // at top couch_cushion_t = 8*inch; couch_back_h = couch_h - couch_seat_h; back_cushion_h = sqrt(pow(couch_back_h,2) + pow(couch_back_d1-couch_back_d2, 2)); back_angle = atan2(couch_back_h, couch_back_d1-couch_back_d2); top_r = 3*inch; bot_r = 1*inch; corner_r = 3*inch; module couch() { gap = 0.5*inch; couch_end_double(end="L"); translate([23.5+63/2+gap,0,0]) couch_double(); translate([23.5+63+gap*2, -7, 0]) couch_corner(); translate([23.5+63+7+gap*2, -(23/2+7+gap), 0]) rotate([0,0,-90]) couch_end_single(end="R", w=23*inch); } module couch_base(w) { jcube([w, couch_d, couch_seat_h], j=[0,1,1]); translate([0, couch_d, couch_seat_h]) rotate([0,0,180]) translate([-w/2,0,0]) linear_extrude(height=couch_back_h, scale=[1, couch_back_d2/couch_back_d1]) { square([w, couch_back_d1]); } } module couch_cushions(w) { translate([0, couch_seat_d/2, couch_seat_h]) cushion(l = w, w = couch_seat_d, t = couch_cushion_t, bot_r=bot_r, top_r=top_r, corner_r=corner_r); translate([0, couch_seat_d, couch_seat_h]) rotate([back_angle, 0, 0]) translate([0, back_cushion_h/2, 0]) cushion(l=w, w=back_cushion_h, t=couch_cushion_t, bot_r=bot_r, top_r=top_r, corner_r=corner_r); } module couch_double() { w = 63*inch; color(couch_color) { couch_base(w); for (x = [-w/4, w/4]) translate([x, 0, 0]) { couch_cushions(w/2); } } } module couch_single(w) { color(couch_color) { couch_base(w); couch_cushions(w); } } module couch_end_single(end, w) { arm_w = 10*inch; arm_cushion_w = 13*inch; arm_cushion_t = 5*inch; arm_h1 = 22*inch; arm_h2 = couch_h - arm_cushion_t; arm_d = 25*inch; sign = sign(end); dx = (w + arm_w)/2 * sign; couch_single(w); color(couch_color) translate([dx,0,0]) { rotate([90, 0, 90]) linear_extrude(arm_w, center=true) { polygon([ [0,0], [0, arm_h1], [arm_d, arm_h1], [couch_d, arm_h2], [couch_d, 0] ]); } translate([(arm_cushion_w - arm_w)/2*sign,0,0]) { translate([0, arm_d/2, arm_h1]) cushion(l = arm_cushion_w, w=arm_d, t=arm_cushion_t, bot_r=1*inch, top_r=2*inch, corner_r=2*inch); a = atan2(arm_h2 - arm_h1, couch_d - arm_d); arm_back_cushion_h = sqrt(pow(arm_h2-arm_h1,2) + pow(couch_d-arm_d, 2)); translate([0, arm_d, arm_h1]) rotate([a,0,0]) translate([0, arm_back_cushion_h/2, 0]) cushion(l = arm_cushion_w, w=arm_back_cushion_h, t=arm_cushion_t, bot_r=1*inch, top_r=2*inch, corner_r=2*inch); } } } module couch_end_double(end) { single_w = 23.5*inch; end_w = 23*inch; translate([-sign(end)*single_w/2, 0, 0]) couch_single(w = single_w); translate([sign(end)*end_w/2, 0, 0]) couch_end_single(end=end, w=end_w); } module couch_corner() { inner_r = 7*inch; color(couch_color) { rotate_extrude(angle=90) { translate([inner_r,0]) polygon([ [0,0], [0, couch_seat_h], [couch_seat_d, couch_seat_h], [couch_d - couch_back_d2, couch_h], [couch_d, couch_h], [couch_d, 0] ]); } rotate([0,0,-45]) translate([0,4.95*inch,0]) jcube([10*inch, 10*inch, couch_seat_h], j=[0,1,1]); // Fudge a non-rectangular base cushion by unioning several rectangular // ones. (This looks really strange if you take off the back cushion.) // Doing this really right would involve something like was done for the // back cushion - rotationally extruding the bulk, and then finishing // off the corners. And, having done that for the back, if I were to // do this again I might do it... but I did this first, and it works. // // Coming back to this later: cushion still can't do it in one call, // because cushion wants four sides and this needs at least five. // (And cushion doesn't generalize easily, for several reasons.) // Some other odd-shaped cushions use pipe_polygon, but that won't give // you different radii on the top and bottom corners. // w = 13*inch; for (q = [ [0, w/2, -1.6*inch], [-16, w/2, 0], [-45,0, -2*inch], [-74, -w/2, 0], [-90, -w/2, -1.6*inch] ]) { rotate([0,0,q[0]]) translate([q[1], couch_seat_d/2 + inner_r + q[2], couch_seat_h]) cushion(l=w, w=couch_seat_d, t=couch_cushion_t, bot_r=bot_r, top_r=top_r, corner_r=corner_r); } // Build the back cushion by rotationally extruding the bulk, and // then carefully unioning in a couple of side pieces. for (q = [ [0, 6*inch, 3*inch], [-90, 6*inch, -3*inch] ]) { rotate([0,0,q[0]]) { translate([q[2], couch_seat_d + inner_r - 0.15, couch_seat_h]) rotate([back_angle, 0, 0]) translate([0, back_cushion_h/2, 0]) cushion(l=q[1], w=back_cushion_h, t=couch_cushion_t, bot_r=bot_r, top_r=top_r, corner_r=corner_r); } } translate([0,0,couch_seat_h]) rotate([0,0,5]) rotate_extrude(angle=80) { translate([inner_r + couch_seat_d, 0]) rotate(back_angle) { hull() { translate([back_cushion_h - bot_r, bot_r]) circle(bot_r); translate([back_cushion_h - top_r, couch_cushion_t-top_r]) circle(top_r); translate([bot_r, bot_r]) circle(bot_r); translate([top_r, couch_cushion_t-top_r]) circle(top_r); } } } } } function sign(end) = (end[0] == "L" || end[0] == "l") ? -1 : 1; module wingbackchair() { leg = adjust(2*inch); // NEEDSWORK w = 26.5*inch; d = 25.5*inch; h = 36.5*inch; leg_h = 9*inch; seat_h = 5.5*inch; wing_t = 2.5*inch; back_t1 = 4*inch; back_t2 = 2*inch; back_t = back_t1 + back_t2; seat_t = 3.5*inch; seat_d = d - back_t; back_h1 = 27.5*inch; back_h2 = 25.5*inch; c = "lightsteelblue"; color(c) { // Base translate([0, 0, leg_h]) jcube([w, d, seat_h], j=[0,1,1]); // Legs for (x = [-(w/2-leg/2), w/2-leg/2]) { for (y = [leg/2, d-leg/2]) { translate([x,y,0]) jcube([leg, leg, leg_h], j=[0,0,1]); } } // Back translate([0, seat_d, leg_h + seat_h]) { rotate([-asin(6*inch/back_h1), 0, 0]) { jcube([w-8*inch, back_t2, back_h2], j=[0,1,1]); translate([0,back_t2,0]) jcube([w, back_t1, back_h2+4*inch], j=[0,1,1]); c = w-7*inch; translate([0,back_t,back_h2]) rotate([0,-90,90]) clip(o=[0, -c/2, 0], v=[0,1,0]) clip(o=[0, c/2, 0], v=[0,-1,0]) clip() rounded_segment(t = back_t*2, c=c, r2=back_h1-back_h2); clip(v=[0,-1,0],o=[0, back_t, 0]) { for (x=[-1,1]) { translate([x*(w/2-4*inch), back_t2, 0]) { cylinder(r=back_t2, h=back_h2); translate([0,4.5*inch,back_h2]) { rotate([90,0,-90]) rotate_extrude(angle=90) translate([4.5*inch,0,0]) circle(back_t2); translate([x*4*inch,1,6*inch]) rotate([116,0,0]) clip(v=[-x,0,0]) cylinder(r=wing_t, h=6*inch); } } } } } } // Seat cushion x1 = w/2 - seat_t/2; x2 = w/2-4.25*inch; y1 = -0.5*inch; y2 = 2*inch; y3 = seat_d - 2.5*inch; translate([0, seat_t/2, leg_h + seat_h + seat_t/2]) pipe_polygon(r=seat_t/2, fill=true, [ [-x1, y1], [-x1, y2], [-x2, y2], [-x2, y3], [x2, y3], [x2, y2], [x1, y2], [x1, y1] ]); // Sides for (x=[-1, 1]) { translate([x*w/2, d, leg_h+seat_h]) { rotate([90, 0, -90]) clip(v=[0,0,x]) { pipe_polygon(r=wing_t, fill=true, open=true, [ [3*inch, 0], [18*inch, 0], [18*inch, 8.5*inch], [4*inch, 8.5*inch], [3.5*inch, 17*inch], [4*inch, 26*inch], [-3.8*inch, 28*inch] ]); } // Arms translate([x*0*inch, -20.75*inch, 8.75*inch]) rotate([-86.5,0,4*x]) cylinder(d2=wing_t*1.3, d1=wing_t*2, h=16*inch); } } } // Measuring sticks $measure=false; %translate([0, 31, 0]) measuringstick(46*inch); %translate([w/2, 32, 0]) measuringstick(46*inch); %translate([w/2, 19, 0]) measuringstick(41.5*inch); %translate([w/2, 19*inch, 42*inch]) rotate([-73,0,0]) measuringstick(13*inch); %translate([w/2, 5*inch, 14*inch]) rotate([-90,0,0]) measuringstick(20*inch); } module entcabinet() { base_h = 5*inch; w = 37*inch; d = 21*inch; h = 26*inch; oh_f = 1.5*inch; oh_lr = 0.5*inch; top_t = 1.5*inch; door_gutter = 0.5*inch; door_margin_x = 2*inch; door_margin_z = 1*inch; dw = w/2 - door_margin_x - door_gutter/2; dh = h-base_h-top_t-door_margin_z*2; foot_lr = 1.25*inch; foot_f = 1.5*inch; foot_t = 3*inch; c1 = "SaddleBrown"; c2 = "BurlyWood"; cknob = "#864"; color(c1) { translate([0, 0, base_h]) jcube([w, d, h - base_h], j=[0,1,1]); translate([0, -oh_f, h - top_t]) jcube([w+oh_lr*2, d+oh_f, top_t], j=[0,1,1]); mirrordup([1,0,0]) { translate([0,foot_t-foot_f,0]) rotate([90,0,0]) linear_extrude(height=foot_t) polygon([ [0, 1*inch], [2*inch, 1*inch], [w/2-5*inch, 2*inch], [w/2-4*inch, 0], [w/2+1*inch, 0], [w/2+foot_lr, base_h], [0, base_h] ]); translate([w/2, 0, 0]) jcube([foot_t, d, base_h], j=[-1,1,1]); } translate([0, d, 0]) jcube([w, foot_t, base_h], j=[0,-1,1]); } mirrordup([1,0,0]) { translate([door_gutter/2, 0, base_h+door_margin_z]) { $no_cabinet_door_support = true; color(c1) difference() { translate([dw/2,0,0]) cabinetdoor(w=dw, h=dh); translate([2*inch, -1, 2*inch]) inset([dw-4*inch, cabinetdoor_thick/2+1, dh-4*inch]); } color(c2) translate([dw/2, 0, dh/2]) scale([1, 1, 5.5/3.5]) rotate([90,0,0]) cylinder(r=3*inch, h=adjustxyvis(0)); color(cknob) translate([1*inch, -cabinetdoor_thick, dh/2]) sphere(1*inch); } } } nestingtable_color = "SaddleBrown"; module nestingtables() { translate([0, -23*inch, 0]) nestingtable_1(); translate([0, -6*inch, 0]) nestingtable_2(); translate([0, 10*inch, 0]) nestingtable_3(); } module nestingtable_1() { color(nestingtable_color) nesting_table(w=20*inch, d=14*inch, h=23.5*inch); } module nestingtable_2() { color(nestingtable_color) nesting_table(w=16.5*inch, d=12.5*inch, h=20.5*inch); } module nestingtable_3() { color(nestingtable_color) nesting_table(w=13*inch, d=11*inch, h=17.5*inch); } module nesting_table(w, d, h) { top_t = 2.5*inch; // actual 2 7/8" leg = 1.5*inch; cross_h = 6.5*inch; // to vertical center translate([0,0,h]) difference() { jcube([w, d, top_t], j=[0,1,-1]); for (y = [0, d]) { translate([0, y, -1*inch]) rotate([0,90,0]) cylinder(r=0.5*inch, h=w, center=true); } for (x = [-w/2, w/2]) { translate([x, d, -1*inch]) rotate([90,0,0]) cylinder(r=0.5*inch, h=d); } } for (x = [-w/2+leg/2, w/2-leg/2]) { for (y = [leg/2, d-leg/2]) { translate([x,y,0]) jcube([leg, leg, h-top_t], j=[0,0,1]); } translate([x, 0, cross_h]) jcube([leg, d, leg], j=[0,1,0]); } translate([0, leg/2, cross_h]) jcube([w, leg, leg], j=[0,0,0]); } module receiver() { color("DimGray") difference() { jcube([17*inch, 11*inch, 6*inch]); translate([5*inch, adjustxyvis(0), 3*inch]) jcube([7*inch, 2, 2.25*inch], j=[1,-1,1]); } color("black") translate([15*inch, 0, 4.25*inch]) rotate([90,0,0]) cylinder(d=1.75*inch, h=0.75*inch); // Actual ~0.5 inch diameter // Left actual inset ~2.5" to center color("black") translate([2*inch, 0, 3.75*inch]) rotate([90,0,0]) cylinder(d=1*inch, h=0.5*inch); color("black") translate([3.75*inch, 0, 3.75*inch]) rotate([90,0,0]) cylinder(d=1*inch, h=0.5*inch); } module tv() { w = 50*inch; h = 31*inch; t = 3.5*inch; t2 = 2.5*inch; // mount behind TV bevx = 1.5*inch; bevy = 2*inch; color("DarkSlateGray") { difference() { rotate([90,0,180]) linear_extrude(scale=[(w-2*bevx)/w, (h-bevy)/h], height=t) translate([-25*inch,0]) square([w, h]); translate([0, -1, 3*inch]) jcube([45.5*inch, adjustzvis(0)+1, 26*inch], j=[0,1,1]); } translate([0, t, 0]) jcube([w-bevx*2, t2, h-bevy], j=[0,1,1]); } } module halfovalcabinet() { d = 26*inch; r = d/2; d2 = 18.25*inch - r; h = 25.5*inch; dw = 18*inch; // fudge down for sep from legs dt = 0.5*inch; dh = 4.75*inch; knob = 1*inch; top_t = 1*inch; // actual 0.75 oh = 1*inch; oh_b = 0.5*inch; leg = 2*inch; leg_inset = 0.5*inch; base_z = 6*inch; dz = [7.5*inch, 13.25*inch, 19*inch]; a = 45*degree; color("SaddleBrown") { translate([0, 0, base_z]) { clip(v=[0,-1,0]) cylinder(d=d-oh*2, h=h-base_z); jcube([d-oh*2, d2-oh_b, h-base_z], j=[0,1,1]); } translate([0, 0, h-top_t]) { clip(v=[0,-1,0]) cylinder(d=d, h=top_t); jcube([d, d2, top_t], j=[0,1,1]); } for (x=[-1, 1]) { translate([x*(d/2-leg_inset), d2-oh_b/2, 0]) jcube([leg, leg, h-oh], j=[-x,-1,1]); rotate([0,0,-x*a]) translate([x*(d/2-leg_inset), 0, 0]) jcube([leg, leg, h-oh], j=[-x,0,1]); } for (z=dz) translate([0, 0, z]) { w_deg = rad2deg(dw/r); rotate([0,0,-90]) { rotate([0,0,-w_deg/2]) rotate_extrude(angle=w_deg) translate([r-oh-1,0,0]) square([dt+1, dh]); translate([r-oh+dt, 0, dh/2]) sphere(d=knob); } } } } module subwoofer() { w = 12*inch; d = 12*inch; h = 12*inch; leg_h = 2*inch; leg_r = 1*inch; horn_diam = 5*inch; horn_r = horn_diam / 2; color("DarkSlateGray") { translate([0, 0, leg_h]) difference() { jcube([w, d, h], j=[0,0,1]); translate([0,-d/2,4.5*inch + horn_r]) { rotate([-90,0,0]) rotate_extrude() { difference() { translate([0,-1]) square([horn_r, horn_r+1]); translate([horn_r, horn_r]) circle(r=horn_r); } } } } for (a = [0, 90, 180, 270]) { rotate([0, 0, a]) linear_extrude(height=leg_h) { translate([w/2, d/2]) { translate([-leg_r, -leg_r]) { circle(r=leg_r); square(leg_r); } } } } } } module frames() { color("BurlyWood") difference() { jcube([19.5*inch, 23.5*inch, 1*inch], j=[0,0,1]); translate([0, 0, 0.6*inch]) jcube([15.5*inch, 19.5*inch, 1*inch], j=[0,0,1]); } } // Torchiere is in three parts (base, top, and shaft+aux light) so that // the shaft can be printed in XY rather than Z. Aux light stalk is // intended to be heated and twisted after printing, to point aux light // downish. Note that top almost certainly needs a raft. module torchiere() { translate([0,0,65.5*inch]) torchiere_top(); rotate([-90,0,0]) torchiere_shaft(assembled=true); torchiere_base(); } module torchiere_base() { color("silver") difference() { cylinder(r=5.5*inch, h=1.5*inch); translate([0,0,-1]) cylinder(d=2.5*inch, h=1.5*inch+2); } } module torchiere_shaft(assembled=false) { color("silver") rotate([90,22.5,0]) cylinder(d=2.25*inch, h=68.5*inch, $fn=8); translate([0, -48*inch, 0]) { rotate([0,0,45]) { color("silver") rotate([90,22.5,0]) cylinder(d=2.25*inch, h=10*inch, $fn=8); rot = assembled ? [0,90,0] : [0,0,0]; rotate(rot) translate([0, -10*inch, -2.25*inch*cos(22.5)/2]) { color("silver") cylinder(d=3*inch, h=3*inch); color("white") translate([0, 0, 3*inch]) { difference() { cylinder(d1=3*inch, d2=6*inch, h=5*inch); translate([0,0,2*inch]) cylinder(d1=3*inch, d2=6*inch, h=5*inch); } translate([0,0,3*inch]) sphere(d=2.5*inch); } } } } } module torchiere_top() { difference() { union() { color("silver") cylinder(d1=3*inch, d2=4.5*inch, h=3.5*inch); color("white") translate([0, 0, 3.5*inch]) difference() { cylinder(d1=4.5*inch, d2=13, h=4.5*inch); translate([0, 0, 2*inch]) cylinder(d1=4.5*inch, d2=13, h=4.5*inch); } } translate([0, 0, -1]) cylinder(d=2.5*inch, h=5*inch+1); } color("white") translate([0, 0, 6*inch]) sphere(d=2.5*inch); } module footstool() { w = 17*inch; d = 11*inch; t = 3*inch; // cushion leg_inset = 2*inch; leg_d1 = 2*inch; leg_d2 = 2.5*inch; leg_h = 2*inch; base_t = 1*inch; translate([0, 0, leg_h]) { color("BurlyWood") jcube([w, d, base_t], j=[0,0,1]); color("LightSteelBlue") translate([0, 0, base_t]) cushion(l=w, w=d, t=t, bot_r=1*inch, top_r=1*inch, corner_r=2*inch); } for (x = [-1, 1]) { for (y = [-1, 1]) { translate([x*(w/2-leg_inset), y*(d/2-leg_inset), 0]) color("SaddleBrown") cylinder(d1=leg_d1, d2=leg_d2, h=leg_h); } } }