jMonkeyEngine / jMonkeyEngine/jmonkeyengine

Using AreaUtils to approximate the object's pixels

Open
#1,784 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
4.3k
Forks
1.2k
Avg merge
4d 7h
Merged PRs (30d)
14

Description

I think JME’s util method is wrong. This estimate should be related to cot() of fov. I think it should look something like this:
screenRadius = (boundsRadius * proj.m11 * screenWidth) / (distance * 2); screenArea = screenRadius * screenRadius * PI;

Forum post: https://hub.jmonkeyengine.org/t/does-anyone-know-how-to-calculate-pixel-count-quickly/45393

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating AreaUtils and reviewing how it estimates an object's screen pixels. Read the linked forum discussion and compare the current calculation with the issue's proposed field-of-view-based formula. Done means the approximation is corrected and its behavior is verified against representative projection and distance cases.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
computer-graphics, game-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.