JuliaGeometry / JuliaGeometry/GeometryBasics.jl

`union` with negative width rectangles gives wrong result

Open
#164 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Julia
Stars
215
Forks
64
Avg merge
3d 18h
Merged PRs (30d)
2

Description

julia> union(Rect2f(0, 0, -1, -1), Rect2f(0, 0, 1, 1))
GeometryBasics.HyperRectangle{2, Float32}(Float32[0.0, 0.0], Float32[1.0, 1.0])

Contributor guide

No contributing guide indexed for this repository

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

Reproduce the Julia example using union with two Rect2f values, including the negative-width rectangle, and inspect how Rect2f and HyperRectangle are handled. Trace the union operation from that entry point and determine the intended geometric result for negative dimensions. Done means the example returns the correct union and the behavior is covered by a regression test.

Written by the indexing model from the issue text.

Assessment

Tech stack
julia
Domain
computer-graphics
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.