Ask Your Question

Revision history [back]

Hi there,

You are using threshold function "cvInRangeS" for an RGB image.It is actually apllied on HSV image. Convert your image using cvCvtColor(p_imgOriginal, p_imgOriginal, CV_BGR2HSV);

Then learn how you can extract the specified color region using the respective Hue Saturation Vales, This link could help you:Click here

Hope this helps you :)