Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7431825
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T09:21:21+00:00 2026-05-29T09:21:21+00:00

Am using cvLoadImage from OpenCV 2.1 on Windows to load a .bmp file. (legacy

  • 0

Am using cvLoadImage from OpenCV 2.1 on Windows to load a .bmp file. (legacy app, maintaining code, not new development.)

Is it loading it in RGB or BGR order? Documentation http://opencv.willowgarage.com/documentation/c/reading_and_writing_images_and_video.html does not say.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T09:21:22+00:00Added an answer on May 29, 2026 at 9:21 am

    The usual order is BGR.Try this code with your own single pixel image.

    IplImage *img = cvLoadImage("c:\\pixel.bmp");
    CvScalar s;
    s=cvGet2D(img,0,0);
    cout << s.val[0];  //first color value (blue)
    cout << s.val[1];  //second color value (green)
    cout << s.val[2];  //third color value (red)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I load a binary image in OpenCV using cvLoadImage as follows: IplImage* myImg=cvLoadImage(<ImagePath> ,-1);
I am trying to load a JPEG image using the cvLoadImage function and it
Using TortoiseSVN against VisualSVN I delete a source file that I should not have
I could not start an OpenCV application under Windows. Given the following simple OpenCV
Using Rails 3.2.0.rc2 and ruby 1.9.3p0 In app/views/requests/_form.html.erb I have the following code for
I am using opencv and successfully created a video file using number of images.
A few days back, I started using new OpenCV-Python interface, cv2 . My question
I am writing an application using the OpenCV libraries, the Boost libraries and a
I am working through the book Learning OpenCV from the O'Reilly series and am
I am updating some older OpenCV code that was written in (I guess) an

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.