LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Have CVI to be an efficient image process tools.

Dear Experts ,

there are some questions to consult you .(My CVI version is 6.0)

I have used CVI to program industrial automation application for some
years ,but never to deal with image process . These days , I am always
involved in the trouble of how to process image with CVI , but not get
any idea . The questions are as follows :

1> How to create a labview or AutoCAD like tool palette ,which includes
many different icons represent different objects ? through drag-drop ,
I can place an object shape on my application window .

2> Once loaded a shape or a picture to a drawing area , e.g. , a line ,
what policy can be used to stretch it along with X or Y axial
direction ? and also how to zoom in or out a shape ?

3> How to move an image object along with arbitrary direction within
the drwaing area ?

4> Can lock the size of a canvas control ? because when loading a bmp
file into it , the canvas size always changes to fit the image's
size .

5> Can get the dimension size and the position of an image located in
a canvas or a picture area ?

6> For Canvas and picture control , which of them would be more
available ?

7> Assuming above skill can be realized , that means the user can draw
or arrange their own image layout , I believe that the user's decision
can be saved into a file , this file does not contain any image data
but just some related properties . When next time loading the user's
own project , the policy is that as the predefined property
relationship saved in the above file to search the corresponding image
data located in a special directory and reappearance them on the
drawing area . Since in Windows , CVI can just support .bmp and .wmf
image format , but the size of bmp format is too large , so is there
any way or function to turn the bmp file to wmf format ?

I also hope you could shift me a very simple example (davidlee62@163.com). Your advise is
highly appreciated . Thanks.

Best Regards

David
0 Kudos
Message 1 of 3
(3,100 Views)
All of the items that you mentioned here will require you to create your own custom algorithms for drawing figures on to a canvas. The canvas control has some basic UI events it can fire, but nothing as sophisticated as what you need in terms of. You will need to track the mouse pointer movements and check its location with respect to the canvas control. There are examples installed with CVI that show you how to track mouse evnets and draw on a canvas and such.

You would need to manually keep track of each structure that you draw on the canvas. The canvas cannot store the data that you write to it, it just draws the data without storing it internally.

Once you figure out a way of representing the figure and its data, you can then manipulated it however you like
. But this functionality is not built into the graph or the canvas, and there are no built in functions that would readily do what you need

For the picture control, you can change one of the properties of the control called fit more to make sure it resizes the image and not itself when you load a bitmap into it. Check out the other options for the fir more as well.

I know this is not the answer you were looking for, but I hope this helps

Bilal Durrani
NI
Bilal Durrani
NI
0 Kudos
Message 2 of 3
(3,100 Views)
Thank you Bilal . Can I use Windows SDK to realized such works on the panel ? I am afraid the cvi panel would take some constraints for doing this . would you please show a simple example as your idea ?

BR

David
0 Kudos
Message 3 of 3
(3,100 Views)