axCWIMAQVision.ExtractSingleColorPlane, performed twice on two separate images, throw an error on the second try

I have the following code in c#:

' Private Sub ExtractColor (SourceImage, CWIMAQImage CWIMAQImage DestinationImage)
{
CWIMAQImage colorPlane = new CWIMAQImage();
axCWIMAQVision1.ExtractSingleColorPlane (SourceImage, colorPlane, CWIMAQColorPlanes.cwimaqLuminancePlane);
axCWIMAQVision1.Copy (colorPlane, /DestinationImage);

}

I need to run this method twice on two separate, identical images every time that overwrite the original image. It works on the first fine image, but then on the second picture, she throws an exception ("Type of Image invalid"). What happens here? I tried to change the order of how to get picture but the first we're STILL working and the second fails.

I just looked at your code once again, and now I'm sure of it.  Image1 and Image2 are pointing to the same image as the Original.  Since using them as images of destination, they are getting crushed.  Your code is like the following:

ExtractColor (Original, Original) / / Original has been transformed from color to grayscale

ExtractColor (Original, Original) / / cannot convert to grayscale image, must be color - error!

Bruce

Tags: NI Hardware

Similar Questions

  • The procedure of procurement of the game Clash of Clans first two payments $9.99 $4.44 and the second did not gems continued with the developer of the game and they told me to resolve this ongoing problem with Apple's iTunes... help me solve

    The procedure of procurement of the game Clash of Clans first two payments $9.99 $4.44 and the second did not gems continued with the developer of the game and they told me to solve this problem continue with Apple iTunes... help solve me this problem and the compensatory jewelry

    Double-see your message, my first response to this topic tells you how to contact iTunes Support (we are fellow users): Re: the procurement process of the Clash game Clans the amount was deducted from the iTunes account and do not have t...

  • Y510P image does not fit into the second screen using HDMI

    Hi, I have the Y510P with Windos 8.1 latest graphic drivers. I am connect to my HDTV via HDMI and the image fits well in my TV and it has a little zoomed. I was looking for a solution in all the menus of Intel HD 4600, nVIDIA Control Panel, Windows scaling... Nothing works. I have another laptop and it has an option that is changing the image and the TV shows that what is supposed to be for show.

    How can I solve this and did what I see in the screen of my laptop on the second screen (TV)?

    Thank you!

    I have a 1280 x 720 Samsung TV, I don't know the model exactly.

    The probem disappear when you change your screen resolution, or change the size of the elements, or something like that. It has something to do with the Panel of Intel, where there is a scaling option, in the tab 'display '. Well, there should be an option to select the scale, but it is not.

    So, to make it appear, you need to do this:

    1. connect the HDMI

    2 desktop, right-click, screen resolution, in 'View', you must select your TV, in my case "Samsung TV"

    3. you change the resolution from 1080 to 720

    4. then select Samsung TV as output ONLY screen, so the screen of the laptop turns off

    5. go in Control Panel (right click, graphics properties... office, display) Intel

    6. NOW, in the scaling box, you can move the 2 sliders and adjust the image, so now I can make it adapt to the screen

    Although it is a solution, and everything works fine, I don't like. I should be able to look at the screen of my laptop, and the most annoying is that steps 1 to 5 are reset every time you unplug the HDMI. It is a temporary solution.

    I want my nVIDIA GT 755 M to take control of the HDMI, I think that I could just plug the HDMI then automatically shows properly scaling the picture of my TV. Just plug and unplug, like all my other computers.

    Thanks for the help and hope I can find a real solution.

  • How to read a counter value for the separation of the two edge before meter is stopped by the second edge (6602 Council)?

    I use a timer/counter with DAQmx 6602. I use the separation of two - available via DAQmx cash edge. Count between the two edges works properly, however I do not know how to read the value of the counter during the counting operation (i.e. after the first edge triggered the beginning of the count, but before the second edge triggered the end of the counting). I'll have to wait for the second goes off the edge of the end of the countdown until I can get a counter value. I need to be able to access the current value of the County during the count operation. This was possible in traditional DAQ. How can it be accomplished using DAQmx?

    Ah shoot - I was afraid that this might be the case (for what it's worth, my series of X returned intermediate values, but the material and the underlying driver are quite different)...

    You just need to take one measure at a time or you are buffer several measures of separation of the two edges at the same time?  So just to take one measure at a time, you can set a task of edges of count using the database internal time as the source using an arm start trigger (first edge) and a sample of clock (second Board) to work around the problem.

    Best regards

  • Problems in using images for screensaver - error preventing the slide show

    original title: problems in using images for screensaver

    I always enjoyed using my photos for a screen saver.  Now, I get the message "an error prevents the slideshow to play."  How can I find and fix the error?

    Hello

    Did you change your computer?

    I suggest you to follow the steps and check

    a. go toC:\Users\ \AppData\Local\Microsoft\Windows Photo Gallery\Pictures.pd4
    and rename "Pictures.pd4".

    It can also help to remove all the video of the target directory files, although the screen saver will play some video formats.

  • I need to create two separate images/settings, different from a single image how do I do this?

    I imported a picture, I need to change the image of a project and I need to change it again to another but I want to keep my settings for both. How can I do this?

    Right-click on the image in the library, and then choose Create a Virutal.

    This will do exactly what you want, you can now edit the two versions indpendently.

  • How to add two lines when the second row is not visible, but also gets the first data line too?

    Mr President

    Jdev worm is 12.2.1

    How to add two lines when the second row is not visible, but also gets the first data line too?

    I want to add two lines like below picture, but want the second to remain invisible.

    tworows.png

    I asked this question but my way of asking was wrong, that's why for me once again.

    Concerning

    Try to follow these steps:

    1. in the database table to add the new column "JOIN_COLUMN" and add the new sequence "JOIN_SEQ".

    2. Add this new column in the entity object. (You can add this in entity object by right clicking on the entity object and then select "Synchronize with database" then the new column and press on sync)

    3. in your bookmark create button to create only one line NOT 2 rows.

    4 - Open the object entity--> java--> java class--> on the entity object class generate and Tick tick on the accessors and methods of data manipulation

    5 - Open the generated class to EntityImpl and go to the doDML method and write this code

      protected void doDML(int operation, TransactionEvent e)
      {
        if(operation == DML_INSERT)
        {
          SequenceImpl seq = new SequenceImpl("JOIN_SEQ", getDBTransaction());
          oracle.jbo.domain.Number seqValue = seq.getSequenceNumber();
          setJoinColumn(seqValue);
          insertSecondRowInDatabase(getAttribute1(), getAttribute2(), getAttribute3(), getJoinColumn());
        }
    
        if(operation == DML_UPDATE)
        {
          updateSecondRowInDatabase(getAttribute1(), getAttribute2(), getAttribute3(), getJoinColumn());
        }
    
        super.doDML(operation, e);
      }
    
      private void insertSecondRowInDatabase(Object value1, Object value2, Object value3, Object joinColumn)
      {
        PreparedStatement stat = null;
        try
        {
          String sql = "Insert into table_name (COLUMN_1,COLUMN_2,COLUMN_3,JOIN_COLUMN, HIDDEN_COLUMN) values ('" + value1 + "','" + value2 + "','" + value3 + "','" + joinColumn + "', 1)";
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
      private void updateSecondRowInDatabase(Object value1, Object value2, Object value3, Object joinColumn)
      {
        PreparedStatement stat = null;
        try
        {
          String sql = "update table_name set column_1='" + value1 + "', column_2='" + value2 + "', column_3='" + value3 + "' where JOIN_COLUMN='" + joinColumn + "'";
          stat = getDBTransaction().createPreparedStatement(sql, 1);
          stat.executeUpdate();
        }
        catch (Exception e)
        {
          e.printStackTrace();
        }
        finally
        {
          try
          {
            stat.close();
          }
          catch (Exception e)
          {
            e.printStackTrace();
          }
        }
      }
    
  • New Design student needs help! Images are not appropriate in the right table.

    I am very new to web design, so I don't know I just made a stupid mistake, but I have trouble getting my images to align as I want it on my main page. I want an image to occupy all of the left side and the other 4 images to fill the right side. The page is of 1300 x 900. It seems that there is a margin around the images, but I can't find the place where to fix it. I pasted the html code below the images.

    Screen Shot 2016-03-15 at 12.01.28 AM.png

    IMG_0627.JPG

    < ! DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional / / IN" "http://www.w3.org/TR/html4/loose.dtd" > ""

    < html >

    < head >

    < meta http-equiv = "Content-Type" content = text/html"; Charset = UTF-8 ">"

    < title > Untitled Document < /title >

    < link href = "stylesheet.css" rel = "stylesheet" type = "text/css" > "

    table text-align: "right."

    < / head >

    < body >

    < table width = "650" border = "0px" align = "right" >

    < tbody >

    < / tbody >

    < tbody >

    < b >

    < td > < img src = "Images/Story_img.gif" width = "325" height = "450" alt = "history" / > < table > "

    < td > < img src = "Images/Mechanics.gif" width = "325" height = "450" alt = "mechanical" / > < table > "

    < /tr >

    < b >

    < td > < img src = "Images/Spoilers.gif" width = "325" height = "450" alt = "spoilers" / > < table > "

    < td > < img src = "Images/where_to_play.gif" width = "325" height = "450" alt = "TSF" / > < table > "

    < /tr >

    < / tbody >

    < /table >

    < img src = "Images/Left_Main.gif" width = "650" height = "900" align = "left" alt = "jace" / > "

    < / body >

    < / html >

    Hi Justin,

    I made a new project. One uses tables, but the best way forward - in my eyes - would be to combine several photos into one image, as I did in the second part of the Images in the table images I reworded to 325/450 respectively 325/900 px.

    Hans-Günter

  • A query takes twice as long for an identical database on two separate systems.

    Hi, I'm looking for help with a performance issue on a particular database.

    I'm running the query
    ' for $o in the collection ("rx.dbxml") / RX [dbxml:metadata("janusId") = "12345"] descending return $o/@dos < id item = '{replace (dbxml:metadata("dbxml:name",_$o)' & #34; (», «_»)} "> {$o} < / item > '"
    on two different systems through a ServerProxy xmlrpclib python object. This is the my test request, but the other query performance presents the same problem.

    Data on both systems are identical, and the time required to execute this query is the same for both systems throughout
    each database, except one. For this particular database, the time required to run the query on system B is double
    the system has.

    This is only the case for a particular database that makes me think it's a matter of data?
    However, the data are identical on both systems.

    Is anyone aware of all data related issues that could trigger such a success of performance-based
    the configurations below? What should be my next step to diagnose this problem?

    System A
    ---
    -1 x Quad core Intel Xeon CPU E5450 @ 3 .00GHz
    -32 GB OF RAM

    -Red Hat Enterprise Linux Server 5.1 (Tikanga)
    -Berkeley dbxml 2.4.13 patched for 2.4.16
    -bsddb3 4.5.0
    -Python 2.4.4
    twisted-8.2.0
    -0.12.0 sOAPpy

    -Size used Avail use % mounted file system
    / dev/sda5 39 33 G G 4.3 G 89%.
    ...
    ---

    System B
    ---
    -2 x Intel Xeon CPU @ 2.80 GHz Dual core
    -12 GB OF RAM

    -Red Hat Enterprise Linux Server 5.3 (Tikanga)
    -Berkeley dbxml 2.4.16
    -bsddb3 4.7.5
    -Python 2.4.4
    twisted-8.2.0
    -0.12.0 sOAPpy

    -Size used Avail use % mounted file system
    / dev/map/VolGroup00-LogVol00 384 G 88 277 G 25%.
    ...
    ---

    Thanks for any help.

    Try looking at the exit of db_stat for each system to the query itself.
    1 clear stats:
    db_stat z m
    2. run the query
    3. look at his stats:
    db_stat m

    Note the suspicious differences. You can / must also monitor the disk and the e/s during queries. If the plans are really the same and the data are the same that points to differences in system that would essentially be IO. At least this is the first place to look.

    Kind regards
    George

  • See RAW and JPEG in two separate photos?

    Hello

    Understand that the Photos automatically stacks RAW + JPEG as a photo. Wondering if you guys have found a way of:

    1 see separate RAW and JPEG in individual photos?

    2. If this is not possible, is there a way to set default pictures to show the RAW version as photo thumbnail/principal for each fireplace?

    Currently trying to find a way to effectively create a workflow involving Photos + Lightroom (raw changes), as well as JPEG/RAW files

    Thank you!

    You can do this by selecting the photo stacked and then enter the command ⌘D to duplicate it.  You will see then two separate versions of the same photo.  Open the first version in edit mode and use the command "Image > use RAW original title" to use the RAW file as the original image file, then select the second version and in edit mode and use the command "Image > use JPEG as the original" to use the JPEGfile as the original image file.

    You can now see the two versions of the image separately in the browser.  Duplication will only duplicate previews, not the original images. But you can now edit the RAW and JPEG format separately.

    There is no option in the user interface of the default RAW version.

  • The higher of the two separate calculations

    How can I write a formula and give me the highest of the two separate calculations?

    Hi Me199,

    The MAX function will do. Example, = MAX (performance(1), result2)

    Please give more details on your goal if you want a complete solution.

    Kind regards

    Ian.

  • Action to combine separate images and alpha channels

    I have a sequence of images 200 + each with a separate file, corresponding alpha channel which should be recombined in photoshop. Ideally, I would like to load each image as a layer and the corresponding alpha image as a mask to this layer, and then save the entire file as a .tiff.

    The files are in the order IE results)

    Image_1

    Image_1_alpha

    Image_2

    Image_2_alpha

    Image_3

    Image_3_alpha

    ...

    I am familiar with the actions and batch processing, but something of this magnitude is beyond me. I think there should be some kind of custom script or action. Ideas and help is appreciated!

    So I sort of found a work around that is not as intuitive, but works using measures.

    Basically, I opened a pair of side-by-side images in PS it is)

    Image_1

    Image_1_alpha

    and performed an action where I copied the image alpha basically and pasted as a mask for color image. I then added a record and double closure order to close both files.

    If I open all my files-by-side in sequence and perform the action that I can treat all my files but need to manually run the action rather than use a drop or a lot.

  • Displaying the same Image in two different Image controls

    We use 2 Flex to dynamically display a large image (2 MB +) that is downloaded from an external web server on a different domain. We would like to take that same image, to scale down and post it in along side the version full size of the image in a thumbnail viewer bit that we wrote. This works very well that if I put just the attributes of the source on the two controls Image to the same URL, however, this results in the Image being uploaded twice. Since the image is so large, it is not very desirable behavior.

    Another option that we tried is cloning the bitmapData after one of the images has finished loading and then put back the clone for the second image.

    private void image1Loaded(e:Event): void
    {
    var bmp1:Bitmap = Bitmap (image1.content);
    Image2.source = new Bitmap (bmp1.bitmapData.clone ());
    }

    The problem with this method is that, since the image is downloaded from a server with a different area of our web server, a security sandbox exception is thrown. Because we have no access to this web server, using a crossdomain.xml file is not an option. We looked at the image transmission by proxy through our web server, but given the size of the image, this isn't the best solution either.

    Does anyone know how to do what we try to do without generating a security exception? We don't need to change the image anyway, we just want to display it inside two different Image controls without having to download it twice.

    The image must not be downloaded twice. Flash Player is very picky about it because of the problems you mention. If you download an image from a specific URL and then try to do it again, the image will be have been cached.

    However, if you do this: the image can indeed be charged twice. Why? Because the 2 requests are sent at the same time because no image has been loaded. This translates into the image loaded twice.

    If you have a large image to display, wait for it to load once before the second request. Complete event of the Image will tell you when its bytes have been received.

  • Poster child folder items twice through two different joins to the parent folder?

    Hello

    In Disco Admin, I created two folders: projects and people. Project folder has three elements: ProjectName, project_manager
    (reference), project_administrator (reference). The two reference points are
    associated with primary key of the record of the people.

    In Disco, I want to create a list of projects showing the name of project manager and
    project administrator, but can not seem to find a way to include the person
    Name of the folder the point twice (once for the name of the project manager and the other for the name of the project manager) in the same worksheet.

    Is this possible? It seems that Yes something obvious, but don't know how to do it. TIA.

    Kind regards
    Tamas

    Simpler I think (and I don't know there are others), is to have two separate folders in the BA - one for project managers and one for project managers.

    Each file would use the name table (so the name table would be in BA twice - once for managers and one for admins). The two would be joined at the table of projects using the appropriate reference (managers would use the reference to the project manager in the project table).

  • HP Z27q 5 K, that monitor is considered to be two separate monitors

    Just updated the operating system of El Capitan Sierra.  (2013 MAC PRO - 12 hearts - 64 gig Ram w/SSD)

    My HP Z27q monitor 5K, in the Sierra, (which used to work in El Capitan) is now considered to be two separate screens.   In El Capitan, I have an announcement file (http://www.iclarified.com/49265/how-to-enable-support-for-the-hp-z27q-5k-monitor - to-mac-os-x-yosemite) to the override file and the wa it worked.

    However, Sierra I don't have rights to ad this file.

    Help, please!

    Hi PKscott,

    Have you tried to disable SIP protection and then installing the substitution file?

    1. Restart your mac
    2. until the apple logo appears press "r", hold "r" down until you see a progress bar appear
    3. When prompted choose English
    4. Click the Utilities menu
    5. Choose terminal
    6. in terminal type "disable csrutil".
    7. Press return
    8. You should see a message "the SIP is disabled.
    9. Click on the terminal menu
    10. choose to quit smoking
    11. Click on the Apple menu
    12. Select restart
    13. If you are prompted to select a startup disk select Macintosh HD
    14. Click on restart

Maybe you are looking for

  • IPhone 5 s tasks randomly

    Dears; I use an IPhone 5s that I've recently upgraded to the latest version of iOS (9.3.2), my problem is that the phone starts the opportunity to perform tasks at random without my inetrvention (navigation contact, do a search, typing random charact

  • Omni 1020 120 pc: upgrade processor motherboard Sandy bridge

    Can I use Intel Core i3-3220 (3rd generation) Ivy Bridge 3.3 GHz LGA 1155 55W Intel HD Graphics 2500 for my Omni 1020 120 pc aio pc?

  • Interface not taken in charge

    I am using Readyboost.   I insert my micro SD and receive a message "the device is plugged into an unsupported interface.

  • Lenovo X230T vs Lenovo Twist

    Hello I plan to buy a new laptop and cannot make my choice I love the design of Lenovo Twist but I also need the X230T pen digitizer I'm not a big fan of the X230T battery, but as long as it is for me 6 hrs battery life, I agree with her I hate these

  • How can I change my region

    On my notebook, that you are authorized to change the region four times although my son has used now some how it is fixed on region 1 as apposed to region 4 how remedy to this person.