Skip to content

Record regions between OpenRgn and CloseRgn - #51

Merged
colemancda merged 12 commits into
masterfrom
feature/region-recording
Dec 2, 2026
Merged

colemancda merged 12 commits into
masterfrom
feature/region-recording

Conversation

@colemancda

Copy link
Copy Markdown
Member

Records a region between OpenRgn and CloseRgn in Port, following a new Mac OS 9.2.2 capture.

Capture

RegionRecordingCapture.c (Retro68, PowerPC) draws in a port over an in-memory bitmap while a region is open and writes each case's region record, the pen's location and the number of inked pixels. Its output on Mac OS 9.2.2 under UTM is RegionRecording-macos-9.2.2-ppc.txt, unmodified. The README section lists what it showed.

Behavior

  • Nothing is drawn while a region is open, whatever the verb.
  • Only framed shapes are recorded: rectangle, oval, round rectangle, region and polygon. Paint, erase, invert and fill record nothing, and neither does FrameArc.
  • Overlapping shapes combine by the even-odd rule.
  • Lines record only as a path that comes back to its start.
  • FramePoly leaves the pen at the polygon's last point.
  • A second OpenRgn starts over; CloseRgn with none open gives an empty region on Mac OS 9.2.2 (endRegion() returns nil).
  • Recorded polygons use a rasterization measured from one triangle. PaintPoly is unchanged.
  • A single diagonal Line recorded a staircase of pixels that Graphite does not reproduce.

RegionRecordingTests compares nine groups of cases to the capture's record bytes.

@colemancda
colemancda merged commit 6abf752 into master Dec 2, 2026
3 checks passed
@colemancda
colemancda deleted the feature/region-recording branch December 2, 2026 02:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant