reason:
You are trying to read back from video memory. Depending on hardware, such read-backs might be extremely slow. GetCurrentImage method is intended for rare snapshots where performance is not critical. To speed things up you have to find another solution which does not include reading back from video memory, e.g. you can have a helper inermediate filter in between, which caches a copy of last presented frame, then read from this copy and not from VMR. You might need to also implement format conversion to convert video frame to RGB afterwards.
solution:
use IVMRWindowlessControl9 interface.
经测试,在使用IVMRWindowlessControl9 的GetCurrentImage所需时间只要0.002s,测试环境为:win10 + vs2013 + GTX1050,但是有些人用此方案时,GetCurrentImage所需时间却有3s的延迟,估计是硬件的差异所导致的。