Skip to content

Bezier Curve and Elliptical Arc implementations - SVG Path commands

Notifications You must be signed in to change notification settings

MadLittleMods/svg-curve-lib

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SVG Curve Library

Bezier Curve and Elliptical Arc implementations in multiple languages. SVG path commands.

The API is equivalent and we strive for the same syntax across the language implementations.

Versions

  • JavaScript: v0.2.0
  • C++: v0.2.0
    • Arduino/Teensyduino compatible

API

Demos

Testing

JavaScript

Run once: Install the dependencies

npm install

Run whenever: Whenever you want to run the tests

npm run test

C++

The C++ version of SVGCurveLib requires C++11.

We test on the following platforms:

  • Visual Studio (Community 2013) on Windows
  • Arduino (1.6.3)/Teensyduino (1.22)
    • Teensy 3.0/3.1

Visual Studio

Open up test/c++/vs_testbench/vs_testbench.sln and build the project. You can press Ctrl+F5 to keep the console window open to see the results better.

Arduino

Run whenever: Whenever you make a change. This will move the library files into the Arduino Sketch directory (required because Arduino forces files to be in the same directory).

npm run testSetupArduino

Then compile and upload the sketch to your Arduino or Arduino-like platform. Open a Serial Terminal to see the output streamed every 5 seconds. You can use PuTTY as a Serial Terminal to take advantage of the ANSI colored text.

To disable the ANSI escape color codes, open up test/c++/cpp-test-lib/SVGCurveLibTests.h, and change MacchiatoSettings.useAnsiColor to false.

About

Bezier Curve and Elliptical Arc implementations - SVG Path commands

Resources

Stars

Watchers

Forks

Packages

No packages published