Skip to main content
100%

Fork of Tweak a Face Assignment by Enze Liu

✓ Published0🌍 Public
HHarshinireddyy19
Last edited Jun 18, 2022
Created on Jun 18, 2022

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 description

The first assignment: Tweak a Face

Start with the blank html project This is a panda face!

  1. use two arcs to make the eyes
  2. use two ellipse to make the eye sockets
  3. use one arc to make the nose
  4. use two circles to implement the flush
  5. use two arcs to implement the mouse
  6. use two arcs to implement the ears
MIT Licensed

Similar vizzes