Unfortunately, NewImageOp does need to make a copy, see
gioui.org/commit/74407a50d598bfd27e8f8e48b6832cc5df04de77.
There are three reasons to make a copy, two important and
one less so:
First, the ImageOp.src field is used as a key in an image=>texture map to
quickly determine whether we can reuse an existing texture for an image. There
is no efficient way to know whether the user has mutated an image, which should
replace the cached texture.
Second, even if we somehow detected image mutations, letting the program use
the image contents while the GPU goroutine is accessing it leads to race
conditions.
Third, and less importantly, sometimes the image contents is not in a GPU
friendly format and a copy is needed anyway.
That said, I might have missed a better design for efficient drawing of images.
Please let me know.