Jump to content

Not the same image under MAX or under VIs


Recommended Posts

Hi all,

I have a camera (digital linear) connected to a NI-PCI-1422 acquisition card.

When I watch the image under MAX, I get this:

post-6600-1204020381.png?width=400

a black image... (which is normal !)

When I watch with a very simple Low Level Snap VI, I get this:

post-6600-1204020457.png?width=400

a not very black image !!!!

Does anyone know why ??? What is wrong with this NI example code, I'm using ?

Thanks for your help !

Laurent

Link to comment

It doesn't seem like there's anything wrong with the example code, just the scaling of the values displayed is different. It seems as though the image is getting "autoscaled" to the range of pixels values in your image. Right-click on the "Image" control and select "16-bit Display Mapping...". Change the "Conversion Method" to get the correct display. I've also found that when the 16-bit Display Mapping isn't working the way I expect it to, that adding the "IMAQ Image Bit Depth" function VI after the image is acquired (keeping the "Bit Depth (0)" of the IMAQ Image Bit Depth VI unwired), usually solves the problem.

Link to comment

QUOTE(bmoyer @ Feb 26 2008, 02:26 PM)

It doesn't seem like there's anything wrong with the example code, just the scaling of the values displayed is different. It seems as though the image is getting "autoscaled" to the range of pixels values in your image. Right-click on the "Image" control and select "16-bit Display Mapping...". Change the "Conversion Method" to get the correct display. I've also found that when the 16-bit Display Mapping isn't working the way I expect it to, that adding the "IMAQ Image Bit Depth" function VI after the image is acquired (keeping the "Bit Depth (0)" of the IMAQ Image Bit Depth VI unwired), usually solves the problem.

I've tried the different conversion method, without any correct results !

The correct one should be "Given range" from 0 to 255, but that's worst than the original...

I've tried as well to add "IMAQ Image Bit Depth", but no better results...

Link to comment

QUOTE(lraynal @ Feb 26 2008, 08:59 AM)

I've tried the different conversion method, without any correct results !

The correct one should be "Given range" from 0 to 255, but that's worst than the original...

I've tried as well to add "IMAQ Image Bit Depth", but no better results...

Does this VI work?

Link to comment

QUOTE(bmoyer @ Feb 26 2008, 04:14 PM)

Does this VI work?

Your conversion is probably more like the one in MAX, which would explain what I get...

But I don't understand why do we need to change the conversion range to get something approching the MAX image !

The display mapping in Full Dynamic should be enough !!! Don't you think ?

Link to comment

QUOTE(lraynal @ Feb 26 2008, 10:31 AM)

Your conversion is probably more like the one in MAX, which would explain what I get...

But I don't understand why do we need to change the conversion range to get something approching the MAX image !

The display mapping in Full Dynamic should be enough !!! Don't you think ?

The default "Full Dynamic" range, means to scale the image so that the brightest pixel in the image gets a 255 (maximum brightness on the screen). MAX doesn't display in Full Dynamic range. You would think that the default display method would be the same as MAX but it isn't. NI would have to explain that decision for you.

Pressing Ctrl-H in the 16-bit Display Mapping screen will give you a description (somewhat crude) of what each option does.

Bruce

Link to comment

QUOTE(bmoyer @ Feb 26 2008, 05:01 PM)

The default "Full Dynamic" range, means to scale the image so that the brightest pixel in the image gets a 255 (maximum brightness on the screen). MAX doesn't display in Full Dynamic range. You would think that the default display method would be the same as MAX but it isn't. NI would have to explain that decision for you.

Bruce

Ok, looks quite clear to me, now ! Even if.....

Thanks a lot, Bruce !

Cheers,

Laurent

Note: Anyone who would like to add something to this "strange" behavior is more than welcome !!!! I'm still hungry of information and explanation !

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.