Oh, I see. In that case, they should use the render-image function
directly. Override the on-paint method, call the get-dc method and
pass that and some suitable coordinates to do the drawing. I recommend
using this only for drawing the final image, don't use other dc
methods (I mean, you can, but
Thanks. Yes, they want to (say) draw a solid green circle next to the name
of someone who has been active in the last five minutes. As I understand
it, they followed the GUI Toolkit intro and arrived at the point where they
have a canvas% with the on-paint method specified in its constructor. The
o
Here’s one way, if you mean a bitmap% object:
#lang racket/base
(provide image->bitmap)
(require racket/class
(only-in racket/draw make-bitmap bitmap-dc%)
(only-in 2htdp/image image-width image-height)
(only-in mrlib/image-core render-image))
(define (image->bitmap im
When you say "bitmap" do you mean "bitmap% object"? And if so, why do
they want to do that? If not, do you mean something else?
Robby
On Thu, Mar 19, 2015 at 5:24 PM, Andrew Mauer-Oats wrote:
> Is there a public way to change an image created using the 2htdp/image
> library into a bitmap?
>
> M
4 matches
Mail list logo