I need to convert GDI methods calls of a relatively complex program into equivalent Direct2D code. For most of the GDI functions I could write equivalent code. But I haven't found any equivalent code for InvertRect. Since the drawing is done dynamically, I can't create (or it will be a performance bottleneck) WICBitmap to get pixels and invert the color.
Can anyone suggest me a good solution, please?