Vector graphics has important applications in gaming, computer GUIs, data visualisation and computer art. In this topic we will use Python to create SVG files. This is the format used by Inkscape, so students can use Inkscape to open, edit or print their creations. Also, with modern HTML, SVG can also be added to a web page. The basics vector graphics primitives transfer across to other system, for example the HTML5 canvas is similar to SVG.

Learning objectives

  • The basics of SVG and vector graphics
  • Usingthe Python SVG library

Content

Workbook and teachers' notes show how to set up Python to create SVG files, and shows how to draw basic shapes with different fill and line styles.

Subscribe

Sign up for Schoolcoders membership to access all our resources for an annual subscription of just £40 for a single school (a discount of 60% of the full price of £100). Membership allows you to download all existing resources, and any new resources, for one year.