Displaying bitmaps in DrRacket using 2htdp/image is near instantaneous when
(display)-ed, but takes quite a while when shown as a result.

The effect gets very bad when lots of images are combined with (beside) and
(above), while (display)-ing remains fast.

Racket version is 6.5.

Dan



Sample comparison:

displayln: 1 milliseconds
result: 714 milliseconds


Code:

#lang racket

(require 2htdp/image)

(define harpos (bitmap/url "
http://3.bp.blogspot.com/-_PE5YujeDKk/VcP3vpTgJZI/AAAAAAAAGpE/97T8sdMj6CE/s640/harpo-tryptych.png
"))

(define a (current-milliseconds))
(displayln harpos)
(define b (current-milliseconds))
(~a "displayln: " (- b a) " milliseconds")

(define c (current-milliseconds))
harpos
(define d (current-milliseconds))
(~a "result: " (- d  c) " milliseconds")

-- 
You received this message because you are subscribed to the Google Groups 
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to