Yes for example pixel.r
is just a simpler way of writing getproperty(pixel, :r)
(that’s what we call syntax sugar). So to broadcast this access to the r
field you can write getproperty.(pixel, :r)
.
(PS: see Please read: make it easier to help you for tips on how to format your code on this forum.)