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 7876819
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T03:13:40+00:00 2026-06-03T03:13:40+00:00

If someone can share the code for What is C++(OpenCV) equivalent for Image.setValue(…) method

  • 0

If someone can share the code for

What is C++(OpenCV) equivalent for Image.setValue(…) method in C# EmguCV framework.
emgucv reference:
http://www.emgu.com/wiki/files/2.3.0/document/Index.html

for example how to code in C++ next:

 private static Image<Gray, Byte> FilterPlate(Image<Gray, Byte> plate)
 {
  ...
  Image<Gray, Byte> thresh = plate.ThresholdBinaryInv(new Gray(120), new Gray(255));
  using (Image<Gray, Byte> plateMask = new Image<Gray, byte>(plate.Size))
  plateMask.SetValue(255.0);
  ...
  thresh.SetValue(0, plateMask);
  }

especially what is C++ equivalent for next:

  thresh.SetValue(0, plateMask);

Thanks.

  • 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-06-03T03:13:40+00:00Added an answer on June 3, 2026 at 3:13 am

    I’m not use EmguCV, but as documentation said

     thresh.SetValue(0, plateMask);
    

    Set the element of the Array to val, using the specific mask

    So, I think, you can use

    void cvSet(CvArr* arr, CvScalar value, const CvArr* mask=NULL)

    Sets every element of an array to a given value.
    

    http://opencv.willowgarage.com/documentation/operations_on_arrays.html#set

    Example:

    cvSet(thresh, CvScalar(0), plateMask);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Can someone share how to make items in a ListViewer scrollable? Source code will
Can someone share a simple example of using the foreach keyword with custom objects?
Can someone share their experiences with s#arp architecture. we have decided to follow mvp
Can someone share a good way to save the program state (UINavigationController stack, etc)
Can someone please share a extremely simple version of JQuery Ajax with pagination??
Someone can point me reliable method to run given application in different session of
I'm converting some c code to python. Can someone convert this for loop from
Can someone explain this WPF behaviour? <Page xmlns=http://schemas.microsoft.com/winfx/2006/xaml/presentation xmlns:x=http://schemas.microsoft.com/winfx/2006/xaml> <Grid> <!-- Rounded mask -->
I hope someone can help. The following piece of php code (see below) is
Can someone help me convert the following code into code that instead has two

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.