Very basic profiler, supports drawing using either Raylib-nelua or tico-nelua. Inspired by JProf
There is no external dependencies unless when drawing is enabled, which will use an drawing implementation specified by
NPROF.draw_impl
, which must be either "raylib"
or "tico"
; the external dependency is the specified implementation:
NPROF.draw_impl
is"raylib"
: Raylib-neluaNPROF.draw_impl
is"tico"
: tico-nelua
PROF
: to use nprof, you must definePROF
with-D PROF
option.NPROF
:use_colors
:false
by default; whenfalse
,WHITE
color is used to draw elements, otherwise it'll use different colors.scale
:{x=1, y=24}
by default; for y axis, the element's rectangle height is defined as scale.y; for x axis, an element's rectangle width is defined as the absolute of the scale.x when negative, otherwise, when positive, is defined as the screen width*
scale.x.draw_list
:true
by default; it will draw a list on upper-left corner whentrue
.draw_rects
:true
by default; it will draw stack of rects on the bottom of screen whentrue
.draw_impl
:false
by default; it must be either"raylib"
or"tico"
, it specifies what drawing implementation should be used.
TEST
: runs a basic test, only useful for nprof development.
NOTE: When both NPROF.draw_list
and NPROF.draw_rects
are false, no drawing implementation is required
Check the Rotor raylib example