I am doing an animation, and every 2 seconds I call the following code
mMarkup= new Annot.Ink(CurrentAnno);
However, it appears to be not releasing memory over time. I am using PDFViewWPF.
Yes, when you call methods like those, then some resources are being allocated, that won’t be released, whether they are used or not, until PDFDoc.Save is called.
It would be best to do that sort of rendering on your own graphical layer over top of ours. In particular you can call PDFViewWPF.GetCanvas to get a canvas you can use for drawing.
At the very least reusing an existing Ink annot would be ideal, instead of calling new each time.