So I have a fairly simple Winforms app. It has a panel with a bmp image that is being updated every second, via
Graphics.DrawImage
I want to be able to draw a rectangle over the updating images. There seems to be no way to do this in Winforms, however.
First, I tried drawing on the first panel, but there seems to be no way to set the z-index of Graphics elements, so every time the image gets updated, the rectangle is deleted.
Second, I tried making a second panel and drawing in it. Yet, it seems like there is no way to make a truly transparent panel in Winforms. I looked around for some workarounds, but it seems like all they do is essentially make the second panel part of the first, so the previous issue with the rectangle getting deleted arises again.
Is there anyway to do what I am trying to do? Without switching to WPF?