jMonkeyEngine / jMonkeyEngine/jmonkeyengine
Not calling Mesh.updateCounts() causes negative statistics
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 4.3k
- Forks
- 1.2k
- Avg merge
- 4d 7h
- Merged PRs (30d)
- 14
Description
If the user forgets to call Mesh.updateCounts(), the vertices / triangles value will be -1, thus causing the renderer statistics to be subtracted and eventually become negative. If the stats value is -1 the mesh should be considered invalid and crash with exception.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating Mesh.updateCounts() and the renderer statistics code that consumes vertex and triangle counts. Reproduce a mesh with counts left at -1, then trace where the statistics are decremented. Done means invalid counts are rejected with an exception before they can make renderer statistics negative.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100