Skip to content

[models] Built-in 3D models are missing vertex normals #4808

Open
@fasterik

Description

@fasterik

While experimenting with the 3D API and shaders, I discovered that my lighting only works with DrawCube and DrawPlane. Doing a Ctrl+F in rmodels.c confirms that these are the only only functions in that file that call rlNormal3f. It appears that other 3D primitives will reuse the last normal output by a previous draw call. I believe the following functions need to be modified to output vertex normals:

  • DrawCircle3D
  • DrawTriangle3D
  • DrawTriangleStrip3D
  • DrawSphereEx
  • DrawCylinder
  • DrawCylinderEx
  • DrawCapsule

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementThis is an improvement of some feature

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions