simple question, importing images 
Author Message
 simple question, importing images
Story:
I select an image in photoshop, copy and paste it into labview panel.
Then the image size will not be the same as seen in photoshop and i
guess because of that a little bit "distorted"/blurry as well.

If i change the dpi of the image to about 110 (instead of normal 72)or
so in photoshop before copy/paste, the image will get almost the same
size in labview as seen in photoshop. But still a little bit
"distorted".

Changing (shrinking) the image size within labview decrease image
quality and also saves the image as original size (larger file) so
this is out of the question.

Question:
Is there as setting where i can get a qualityloss copy/paste of images
into labview?

Thanks in advance!



Tue, 26 Jul 2005 17:58:37 GMT  
 simple question, importing images
LabVIEW inserts the image in pixels. So best you can do is:

Save your image with photoshop as .bmp-file with a size in pixel as
you want it on the panel.
Put this image in the clipboard by using "Edit>>Import picture from
file...". Then use CTRL-v to get the picture on the front panel.

Let photoshop do the resizing of your image, it does it better than
LabVIEW.

Waldemar



Tue, 26 Jul 2005 19:35:05 GMT  
 simple question, importing images

Quote:
> Is there as setting where i can get a qualityloss copy/paste of images
> into labview?

As pointed out in the other post, the best way is to use the menu item
to Import the image, then paste it on your panel.

The reason that the other mechanism doesn't work as well?  Going through
the Windows clipboard tends to move images into and out of EMF or
enhanced metafiles.  Many times it works fine, but the two packages have
to use it in the same way.  Unfortunately, there seem to be two
different interpretations of how the clipboard works, and the paint
packages are split, so we had to choose which ones we work with.  As an
escape mechanism, we also have the import from file to avoid the
clipboard madness.

One other note, the imported file doesn't have to be saved as bmp, png,
jpg and a number of other image formats work as well.

Greg McKaskle



Tue, 26 Jul 2005 22:29:42 GMT  
 simple question, importing images
I found that drag & drop a bmp file onto the front panel won't cause
any distortion.  So I always save the image to a temporary bmp file
before "paste" onto front panel.  Works everytimes.

George Zou
http://gtoolbox.yeah.net

P.S.  hopefully, NI can get this fixed before next release.  It
shouldn't be that hard.



Wed, 27 Jul 2005 01:34:44 GMT  
 simple question, importing images

Quote:
> LabVIEW inserts the image in pixels.

hmm.. I dont understand this.

Quote:

> I found that drag & drop a bmp file onto the front panel won't cause
> any distortion.  So I always save the image to a temporary bmp file
> before "paste" onto front panel.  Works everytimes.

cool ok.. seems pretty easy.
thanks everybody!!


Thu, 28 Jul 2005 22:15:05 GMT  
 simple question, importing images
Hi,

I meant following:

think a picture has a size of 2*2 inches. If you would use 72 dpi
photoshop will generate a picture of 144*144 pixel, with 120 dpi it
will be 240*240 pixel.
LabVIEW will generate the picture in pixels so a 120 dpi picture will
ge larger than a 72 dpi.

Waldemar



Fri, 29 Jul 2005 15:21:09 GMT  
 simple question, importing images

Quote:

> > LabVIEW inserts the image in pixels.

> hmm.. I dont understand this.


> > I found that drag & drop a bmp file onto the front panel won't cause
> > any distortion.  So I always save the image to a temporary bmp file
> > before "paste" onto front panel.  Works everytimes.

> cool ok.. seems pretty easy.
> thanks everybody!!

The easiest way I have found, that need not include creating a temp
file, is to use a screen capture utility called MWSnap.  I go into
whatever app has the image I want (Paintshop, Paint, etc...actually
any window including LV), do a Ctrl-Shift-A and I get to grab any
rectangle in any window. A left-click and MWSnap has it. Ctrl-C and
the clipboard has it. Go to LV and Ctrl-V to dump it into Labview.
One may even use it in a control via "Import Picture False", etc. in
the control editor.

Using this quick method I make all my own buttons (especially those
with text, so I absolutely know how they will appear on any PC).
MWSnap will even let you save the BMP as a GIF with transparency.  I
like using transparency on control buttons to let you see the button
and a name, and yet view an associated indicator underneath.  Be
careful with transparent GIF's however...the transparent area must be
surrounded by a valid color, or a strange kind of bleeding can occur
when pasted into LV.

Greg



Fri, 29 Jul 2005 20:55:56 GMT  
 simple question, importing images

Quote:

> Hi,

> I meant following:

> think a picture has a size of 2*2 inches. If you would use 72 dpi
> photoshop will generate a picture of 144*144 pixel, with 120 dpi it
> will be 240*240 pixel.
> LabVIEW will generate the picture in pixels so a 120 dpi picture will
> ge larger than a 72 dpi.

> Waldemar

Hmm, ok
but hmm..
I always work with pictures with pixels in mind only. Why should it
then matter what dpi the image has?

I mean as long as you don't print the document, dpi has no meaning.
(except for labview :-) (or am i wrong here?)

Try following:
1. open an image in photoshop. (lets say 200x200)
2. select all
3. ctrl-c
4. ctrl-v into labview
5. change dpi in photoshop. The resolution will then change
accordingly so change it back to 200x200.
6. select all
7. ctrl-v into labview

result: two different image sizes in labview. But same file size and
image size in all other programs.
Seems to me that labview is reading dpi information.

correct me if im wrong.
thanks
/ape



Sat, 30 Jul 2005 03:55:56 GMT  
 simple question, importing images

Quote:


> > > LabVIEW inserts the image in pixels.

> > hmm.. I dont understand this.


> > > I found that drag & drop a bmp file onto the front panel won't cause
> > > any distortion.  So I always save the image to a temporary bmp file
> > > before "paste" onto front panel.  Works everytimes.

> > cool ok.. seems pretty easy.
> > thanks everybody!!

> The easiest way I have found, that need not include creating a temp
> file, is to use a screen capture utility called MWSnap.  I go into
> whatever app has the image I want (Paintshop, Paint, etc...actually
> any window including LV), do a Ctrl-Shift-A and I get to grab any
> rectangle in any window. A left-click and MWSnap has it. Ctrl-C and
> the clipboard has it. Go to LV and Ctrl-V to dump it into Labview.
> One may even use it in a control via "Import Picture False", etc. in
> the control editor.

> Using this quick method I make all my own buttons (especially those
> with text, so I absolutely know how they will appear on any PC).
> MWSnap will even let you save the BMP as a GIF with transparency.  I
> like using transparency on control buttons to let you see the button
> and a name, and yet view an associated indicator underneath.  Be
> careful with transparent GIF's however...the transparent area must be
> surrounded by a valid color, or a strange kind of bleeding can occur
> when pasted into LV.

> Greg

Ah, ok cool tip!
thanks a lot.. I maybe look into that utility some day.


Sat, 30 Jul 2005 04:03:25 GMT  
 
 [ 9 post ] 

 Relevant Pages 

1. import Image vs from PIL import Image vs import PIL.Image

2. Question in french (a simple question, very simple)

3. Import , __import__, ihooks question

4. import/from import question

5. Simple forth question - maybe simple ?

6. Simple Question seeks simple answer

7. getting an image-bearing widget to refresh its image (bonus question: at regular intervals)

8. importing graphical images into vw 2.0

9. Can't use imported image file

10. I want to import VRML- or STL-images in Labview

11. PixelTex 0.2 [generates pixelTexure nodes from imported images]

12. Can't import pygame.image

 

 
Powered by phpBB® Forum Software