Flat, round, designer-friendly pseudo-3D engine for canvas & SVG
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

๐Ÿ›  change to Cylinder.frontFace

similar to box, fallback to backface for rear face

+3 -4
+3 -4
js/cylinder.js
··· 93 93 var Cylinder = Shape.subclass({ 94 94 diameter: 1, 95 95 length: 1, 96 - frontBaseColor: undefined, 97 - rearBaseColor: undefined, 96 + frontFace: undefined, 98 97 fill: true, 99 98 }); 100 99 ··· 121 120 color: this.color, 122 121 stroke: this.stroke, 123 122 fill: this.fill, 124 - backface: this.frontBaseColor || baseColor, 123 + backface: this.frontFace || baseColor, 125 124 visible: this.visible, 126 125 }); 127 126 // back outside base 128 127 this.rearBase = this.group.rearBase = this.frontBase.copy({ 129 128 translate: { z: -baseZ }, 130 129 rotate: { y: 0 }, 131 - backface: this.rearBaseColor || baseColor, 130 + backface: baseColor, 132 131 }); 133 132 }; 134 133