title: cv::Scalar not displaying expected color
body: <p>On an image frame, I use </p>
  
  <p><code>void ellipse(Mat&amp; img, Point center, Size axes, double angle, double startAngle, double endAngle, const Scalar&amp; color, int thickness=1, int lineType=8, int shift=0)</code> </p>
  
  <p>to draw an ellipse and I want to set the ellipse color to green  <img src="https://i.stack.imgur.com/Vb1tn.png" alt="enter image description here"> [ RGB value : (165, 206, 94) ]. 
  So I set the parameter <code>const Scalar&amp; color</code> to</p>
  
  <pre><code>cv::Scalar(94.0, 206.0, 165.0, 0.0); // as BGR order, suppose the value is 0.0 - 255.0
  cv::Scalar(94.0/255.0, 206.0/255.0, 165.0/255.0, 0.0); // suppose the value is 0.0 - 1.0
  </code></pre>
  
  <p>I also tried RGB alternative.</p>
  
  <pre><code>CV_RGB(165.0, 206.0, 94.0); // as RGB order, suppose the value is 0.0 - 255.0
  CV_RGB(165.0/255.0, 206.0/255.0, 94.0/255.0); // suppose the value is 0.0 - 1.0
  </code></pre>
  
  <p>But the color being displayed is white <img src="https://i.stack.imgur.com/ul7p6.png" alt="enter image description here"> [ RGB value (255, 255, 255) ] , not the desired green one.</p>
  
  <p>What I missed at this point? Any suggestion please. Thank you.</p>
  
  <p><strong>EDIT:</strong></p>
  
  <p>Let me put whole related code here. According to <a href="http://docs.opencv.org/doc/tutorials/ios/video_processing/video_processing.html#opencviosvideoprocessing" rel="noreferrer">OpenCV iOS - Video Processing</a>, this is the <code>CvVideoCamera</code> config in <code>- (void)viewDidLoad;</code>:</p>
  
  <pre><code>self.videoCamera = [[CvVideoCamera alloc] initWithParentView:imgView];
  [self.videoCamera setDelegate:self];
  self.videoCamera.defaultAVCaptureDevicePosition = AVCaptureDevicePositionFront;
  self.videoCamera.defaultAVCaptureSessionPreset = AVCaptureSessionPreset352x288;
  self.videoCamera.defaultAVCaptureVideoOrientation = AVCaptureVideoOrientationPortrait;
  self.videoCamera.defaultFPS = 30;
  self.videoCamera.grayscaleMode = NO;
  [self.videoCamera adjustLayoutToInterfaceOrientation:UIInterfaceOrientationPortrait];
  </code></pre>
  
  <p>Then after <code>[self.videoCamera start];</code> called, the <code>(Mat&amp;)image</code> would be captured and can be processed in the CvVideoCameraDelegate method <code>- (void)processImage:(Mat&amp;)image;</code> and here are the code to draw an ellipse:</p>
  
  <pre><code>- (void)processImage:(Mat&amp;)image {
  
  NSLog(@"image.type(): %d", image.type()); // got 24
  
  // image.convertTo(image, CV_8UC3); // try to convert image type, but with or without this line result the same
  
  NSLog(@"image.type(): %d", image.type()); // also 24
  
  cv::Scalar colorScalar = cv::Scalar( 94, 206, 165 );
  cv::Point center( image.size().width*0.5, image.size().height*0.5 );
  cv::Size size( 100, 100 );
  cv::ellipse( image, center, size, 0, 0, 360, colorScalar, 4, 8, 0 );
  </code></pre>
  
  <p>}</p>
  
  <p>Eventually, the ellipse is still in white, not the desired green one.</p>