Skip to content

Misleading comment about nuklear math in SDL3 demo? #961

Description

@TomJGooding

The comment about nuklear's math functions in the SDL3 demo could be misleading:

/* SDL can also provide us with math functions, but beware that Nuklear's own
* implementation can be slightly faster at the cost of some precision */
#define NK_INV_SQRT(f) (1.0f / SDL_sqrtf(f))
#define NK_SIN(f) SDL_sinf(f)
#define NK_COS(f) SDL_cosf(f)

The nuklear math functions were tailored for internal use only, since "nuklear only needs sine and cosine to generate circles" as documented in nuklear_math.c.

This comment might suggest that nuklear's implementations are a faster replacement for general purpose math?

See #960 for context.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions