Jump to content

Resize image dll


Recommended Posts

Hi,

I have made a program that transforms the R,G,B values of an image into H,S and I arrays. I use a 3D surface graph to visualize the hue is a 3D manner.

The problem is:

When a picture has a resolution of about 320 X 240 the 3D surface graph is resonable quick but when the image is too large the 3D surface graph becomes unreasenable slow.

I managed to downsize the image resolution. In combination with a zoom function I'm able to see all the pixel data if necessary. But then again when the images become too large (>1280*1024) the methode it self becomes unreasenable slow.

How can I down size the image data. Is there mayby a dll file with an example available?

Andries

PS. I use Labview 7.0

Link to comment

QUOTE(Rimmergogo @ Nov 7 2007, 07:52 AM)

I'm not totally sure I understand exactly what you're doing, so forgive me if I'm way off-base.

If you were using LV8.2 or greater, I would suggest my LVOOP Imagemagick library :P. But even though you're on LV7, you can still use ImageMagick directly to do what you want. Check out the convert utility, especially the density and/or resample operators.

What you can do is build your command-line string in LabVIEW, execute it with the System Exec.vi function, and then load the resulting output file as a PNG/TIFF/whatever. ImageMagick usually involves a bit of trial and error, but it's a terrifically powerful toolkit.

Finally, if you're messing around trying to see if your operations are taking effect, you might find the identify utility will save you from having to actually open & display your output files.

Link to comment

QUOTE(Rimmergogo @ Nov 7 2007, 08:52 AM)

When a picture has a resolution of about 320 X 240 the 3D surface graph is resonable quick but when the image is too large the 3D surface graph becomes unreasenable slow.

I managed to downsize the image resolution. In combination with a zoom function I'm able to see all the pixel data if necessary. But then again when the images become too large (>1280*1024) the methode it self becomes unreasenable slow.

I'm not entirely clear on what you're doing with regards to 2D and 3D images, but if you have Vision, there's IMAQ Resample to change the size of an image, with different interpolation methods available. Also for a 2D image, a quick and dirty way to resize it might be to throw away every other pixel before displaying it. Inelegant, but fast.

Link to comment

If you want, I posted a pure G version once here. It essentially does what eaolson decribed, so the quality is far from great, but it works for some things.

If you want another, search the OpenG site for a utility called Bird's Eye View, where you can find a VI which does bi-cubic interpolation in pure G.

Link to comment

QUOTE(Justin Goeres @ Nov 7 2007, 10:12 AM)

I'm not totally sure I understand exactly what you're doing, so forgive me if I'm way off-base.

If you were using LV8.2 or greater, I would suggest my LVOOP Imagemagick library :P . But even though you're on LV7, you can still use ImageMagick directly to do what you want. Check out the convert utility, especially the density and/or resample operators.

What you can do is build your command-line string in LabVIEW, execute it with the System Exec.vi function, and then load the resulting output file as a PNG/TIFF/whatever. ImageMagick usually involves a bit of trial and error, but it's a terrifically powerful toolkit.

Finally, if you're messing around trying to see if your operations are taking effect, you might find the identify utility will save you from having to actually open & display your output files.

Justin, could you post a quick video of your Imagemagic library in work (JingProject.com)

I've once tried to install, but can't recall what it was, but there was a big hurdle involved in getting it working.

I would just love to see your example of the power of it in action.

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
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
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.