Fork of Tweak a Face Assignment by Enze Liu
✓ Published0🌍 Public
This example shows a panda face constructed from basic geometric shapes, using D3’s `arc` generator to create the eyes, nose, mouth, and ears, and SVG primitives like `circle` and `ellipse` for the face, eye sockets, and blush. The drawing is rendered as an SVG canvas inside a React component, with the D3 arcs positioned via `transform` rotations and translations. The code imports React, ReactDOM, and the `arc` function from D3 v6, and computes each shape’s path with `d3.arc()` before assigning the resulting `d` attribute to SVG `path` elements.
AI-generated descriptionThe first assignment: Tweak a Face
Start with the blank html project This is a panda face!
- use two arcs to make the eyes
- use two ellipse to make the eye sockets
- use one arc to make the nose
- use two circles to implement the flush
- use two arcs to implement the mouse
- use two arcs to implement the ears
MIT Licensed