Hi,
On my Apple M1 Max running 14.3 Sonoma, an overly-large bitmap surfaces a fairly low-level error
#lang racket
(require racket/draw)
(make-bitmap 2147483648 1)
------------------------------------------------------
Welcome to DrRacket, version 9.1 [cs].
Language: racket, with test coverage [custom]; memory limit: 256 MB.
. . cairo_image_surface_create: given value does not fit primitive C type
C type: _int32
value: 2147483648
>
I don't know what the better thing to do is, but this peeks out through the htdp lang image library, and I would think that there we'd want to have a nicer domain-level error message. For instance:
#lang htdp/isl+
(require 2htdp/image)
(save-image
(rectangle 2147483648 1 "solid" "black")
"huge.png")
maybe something like "image is too large to render"?
Hi,
On my Apple M1 Max running 14.3 Sonoma, an overly-large bitmap surfaces a fairly low-level error
I don't know what the better thing to do is, but this peeks out through the htdp lang image library, and I would think that there we'd want to have a nicer domain-level error message. For instance:
maybe something like "image is too large to render"?