Why is reading a bitmap so slow in Racket?

Viewed 69

I'm writing a CRUD app to learn Racket. Each item has an image associated with it, so I'm using read-bitmap to open the file and load the bitmap. Only one bitmap is loaded at a time, initiated by user-selection in a list-box%. Without drawing to any context, this operation takes ~5 seconds to load a 2-3MB jpeg. Why is it so slow? Is there a better way?

I figured I was doing something wrong in the application so I tried read-bitmap in DrRacket, which led to the same slowness:

#lang racket/gui
(require racket/draw)

(read-bitmap "/path/to/my.JPEG")
1 Answers
Related