|
Re: TrackTwoColors execution time
I am looking at this code also. It is unusable as is, toooo slow as you analyzed. It dynamically allocates and deletes memory for the hit nodes. This is not a good practice in any code where the goal is anything approaching real-time performance. With the color thresholds pretty liberal, this could cause a lot of delay.
It also seems to fetch two pictures, one each time it looks for one of the 2 colors. I think it need only process a single image. In fact, this would be preferable, correct?
Comments? Suggestions?
|