/napoleon

Primary LanguageActionScriptMIT LicenseMIT

Note: Development of the parent project, ND2D, has ceased, so it is unlikely that I'll add to Napoelon in the near future. I'm sure something useful will come out of it... I certainly learnt some things about convex hulls, polygon decomposition and triangulation.

If you've used it - thanks. I'll still try to reply to questions and merge any pull requests I recieve.

#Napoleon Extending ND2D with physics and more...

This experiment adds the 2D phyiscs of Nape and some extra 2D object types to the 2D GPU accelerated ND2D framework.

To use it you will need to clone (or fork) this repository and my ND2D fork, which can be found here.

I use FlashDevelop, so that's the format of the example project file.

Try out the current build of the napoleon example/test project here. There's info in the console at the top, but you can close it and use 'n' to skip through the tests if you prefer. (ctrl+shift+enter to show/hide the console)

The project is still early in development, and it's mainly a testbed for experiments and prototypes at the moment, so things are likely to change and break along the way.


#New for ND2D

  • de.nulldesign.nd2d.display.Polygon2D
  • de.nulldesign.nd2d.display.QuadList2D
  • de.nulldesign.nd2d.display.QuadLine2D
  • de.nulldesign.nd2d.geom.PolygonData
  • de.nulldesign.nd2d.material.APolygon2DMaterial
  • de.nulldesign.nd2d.material.Polygon2DColorMaterial
  • de.nulldesign.nd2d.material.Polygon2DTextureMaterial
  • de.nulldesign.nd2d.utils.PolyUtils

#Napoleon

  • mikedotalmond.napoleon.examples.*
  • mikedotalmond.napoleon.forces.PointField
  • mikedotalmond.napoleon.postprocess.PointLight
  • mikedotalmond.napoleon.BitmapToPolygon
  • mikedotalmond.napoleon.INapeNode
  • mikedotalmond.napoleon.NapePolygon2D
  • mikedotalmond.napoleon.NapeQuad2D
  • mikedotalmond.napoleon.NapeScene2D
  • mikedotalmond.napoleon.NapeSprite2D
  • mikedotalmond.napoleon.NapeWorld2D

#TODO

  • Scene transitions (optional) in NapeWorld2D (setActiveScene) ?
  • More (better) demos / example projects
  • More control over Polygon2D vertices
  • setVertexPosition(s) for (Nape)Polygon2D
  • Sprite-sheet support for Polygon2D (needed?)
  • Vertex weighted texture blending for Polygon2DTextureMaterial

#Libraries used


Triangulation

Convex hull creation in de.nulldesign.nd2d.utils.PolyUtils was derived from some code by bit-101