All Projects → Tastyep → HitboxBuilder-2D

Tastyep / HitboxBuilder-2D

Licence: MIT license
Building hitboxes has never been easier

Programming Languages

C++
36643 projects - #6 most used programming language
CMake
9771 projects
shell
77523 projects

Projects that are alternatives of or similar to HitboxBuilder-2D

Cdt
C++ library for constrained Delaunay triangulation (CDT)
Stars: ✭ 165 (+685.71%)
Mutual labels:  triangulation
Cgal
The public CGAL repository, see the README below
Stars: ✭ 2,825 (+13352.38%)
Mutual labels:  triangulation
hacker-feud
💥 A single page web game made with Svelte.
Stars: ✭ 61 (+190.48%)
Mutual labels:  game-2d
Manifoldplus
ManifoldPlus: A Robust and Scalable Watertight Manifold Surface Generation Method for Triangle Soups
Stars: ✭ 175 (+733.33%)
Mutual labels:  triangulation
Unity.library.eppz.geometry
2D Geometry for Unity. Suited for everyday polygon hassle. Polygon clipping, polygon winding direction, polygon area, polygon centroid, centroid of multiple polygons, line intersection, point-line distance, segment intersection, polygon-point containment, polygon triangulation, polygon Voronoi diagram, polygon offset, polygon outline, polygon buffer, polygon union, polygon substraction, polygon boolean operations, and more. It is a polygon fest.
Stars: ✭ 198 (+842.86%)
Mutual labels:  triangulation
Delaunator Cpp
A really fast C++ library for Delaunay triangulation of 2D points
Stars: ✭ 244 (+1061.9%)
Mutual labels:  triangulation
Hxgeomalgo
Small collection of computational geometry algorithms in Haxe.
Stars: ✭ 133 (+533.33%)
Mutual labels:  triangulation
Koru
A 2D multiplayer sandbox game.
Stars: ✭ 78 (+271.43%)
Mutual labels:  game-2d
Poly2tri
2D constrained Delaunay triangulation library
Stars: ✭ 214 (+919.05%)
Mutual labels:  triangulation
weaver
A spider tapestry weaver
Stars: ✭ 72 (+242.86%)
Mutual labels:  triangulation
Opensimplelidar
Open Source scanning laser rangefinder
Stars: ✭ 2,206 (+10404.76%)
Mutual labels:  triangulation
Piccante
The hottest High Dynamic Range (HDR) Library
Stars: ✭ 195 (+828.57%)
Mutual labels:  triangulation
Manifold
Convert any Triangle Mesh to Watertight Manifold
Stars: ✭ 251 (+1095.24%)
Mutual labels:  triangulation
Openlidar
Open Hardware scanning triangulation laser rangefinder
Stars: ✭ 166 (+690.48%)
Mutual labels:  triangulation
DAABBCC
Dynamic AABB Tree native extension with Branch and Bound Algorithm for Defold Engine
Stars: ✭ 42 (+100%)
Mutual labels:  collision
Sltk
An OpenCV-based structured light processing toolkit.
Stars: ✭ 151 (+619.05%)
Mutual labels:  triangulation
Map Based Visual Localization
A general framework for map-based visual localization. It contains 1) Map Generation which support traditional features or deeplearning features. 2) Hierarchical-Localizationvisual in visual(points or line) map. 3)Fusion framework with IMU, wheel odom and GPS sensors.
Stars: ✭ 229 (+990.48%)
Mutual labels:  triangulation
SplashGeom
Open-source C++ library for geometry and linear algebra
Stars: ✭ 22 (+4.76%)
Mutual labels:  triangulation
Python-Games
A collection of small python games made by me using pygame and tkinter libraries
Stars: ✭ 121 (+476.19%)
Mutual labels:  game-2d
Tinfour
Delaunay and Constrained Delaunay Triangulations in Java, providing high-performance utilities for modeling surfaces with support for Lidar LAS files, Digital Elevation Models (DEM), finite element analysis, path planning, natural neighbor interpolation, and other applications of Triangulated Irregular Networks (TIN)
Stars: ✭ 119 (+466.67%)
Mutual labels:  triangulation
logo

Introduction

Hitbox Builder is a lightweight C++ library aiming to automatizing the process of generating hitboxes composed by only convex polygons.

It was originally designed for 2D games, but it could also serve different purposes.

License

Hitbox Builder is distributed under the MIT License

Requirements

Features

Below is a representation of each stage of transformation of the data.

logo

Usage

// Initialize the builder.
HitboxBuilder::init();

// Create a hitbox for the given sprite with an accuracy of 70%.
const auto hitbox = HitboxBuilder::make(sprite, 70, false);

const auto& convexPolygons = hitbox.body();
const auto& boundingBox = hitbox.bound();

// Use these data as you like.

Demos

To run the demos, execute the configure script with the option '-t'.

Execute the target HitboxBuilder-tester located in the build directory.

Some test bed commands are:

  • keys to slide between the images.
  • keys to increase/decrease the accuracy of the algorithm.
  • Space key to toggle the display of the sprite.

You can load your own images by adding them to the TestBed/assets/ directory. You will just need to restart the program as they are loaded at the beginning.

Output:
Input Output
silhouette Accuracy gif
Accuracy = 100 Accuracy = 66
Italy 100 Italy 66
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].