viz: fixed memory leak
Merge pull request #3347 from Nerei:memory_leak_in_viz_opencv30