Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Generic 2D graphics library for C++14

NotificationsYou must be signed in to change notification settings

jamboree/niji

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

60 Commits
 
 
 
 
 
 

Repository files navigation

Generic 2D graphics library for C++14.

Introduction

Niji is a generic library for 2D graphical path manipulation, it provides containers, generators (graphics), adaptors (views) and algorithms for path, in a sense like STL/Boost.Range.

On the other hand, niji doesn't have the ability to render these paths on its own, you can think it as a generic front-end for arbitrary graphic engines which can do the real rendering.

Overview

Niji can be divided into these submodules:

  • core - path fundamentals.
  • container - various path containers, e.g.path,group, etc.
  • graphic - common graphics, e.g.ellipse,round_rect, etc.
  • geometry - adapted geometry path for Boost.Geometry.
  • view - various path adaptors, e.g.inverse,transform,stroke, etc.
  • make - convenient path makers.
  • algorithm - path algorithms, e.g.bounds,length, etc.
  • support - traits, basic geometries, math...
  • sink - predefined backends, e.g. Skia, Direct2D, etc.

Quick Example

The following example shows how to output the path of a dashed ellipse:

usingnamespaceniji;render(ellipse<double>({100,100},50) | views::dash<double>({6,2}), sink);
  • all components reside in namespaceniji.
  • render(path, sink) sends the path commands to sink.
  • ellipse<T> is a predefined path generator.
  • views::dash<T>(pattern) returns a path adaptor that generates dash lines.
  • sink is something that handles the path commands.

Documentation

Dependencies

License

Copyright (c) 2014-2018 JamboreeDistributed under the Boost Software License, Version 1.0. (See accompanyingfile LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

Releases

No releases published

Packages

No packages published

Languages


[8]ページ先頭

©2009-2025 Movatter.jp