RGBsurface pixels read-only?

Out of curiosity I tried this example code in the HELP for RGBsurface…

… however the line

surf.Pixel(x, y) = &cFFFFFF

fails on the first pixel with UnsupportedOperationException…

So… it appears the pixels are read only, and cannot be set. If this is true, it implies a bitmap cannot be created by code, pixel by pixel. Correct ?

It probably depends on the backing of the picture.

Try making picture your self with New Picture. And see if you can write into that. (Am betting you can).

Aha, thanks you are correct.