How to find average nt,s,c from ntsc image?