3D Picture Control: Find Object function closes scene reference when it has no children

I am using Labview 8.2
The "Find Object.vi" function is causing me some problems as it is closing the reference to the Scene Object passed into it when that Scene object does not contain any child objects.  The attached screengrab shows the relevant part of the "Find Object.vi" function - the input (parent) reference is added to the front of the queue, and if the "ObjectCount" method returns 0, then the reference is closed (and hence unavailable from that point on.  By removing the "Close Reference" function, the reference remains valid, but I am unsure of what other consequences this would have (and I don't like editing NI VI's!).
I have attached an example VI to illustrate this, hopefully it is clear enough what is happening.  Basically, I want to be able to check for the existence of a child object without risking losing the parent object's reference.  I could always write my own but perhaps the "Find Object.vi" function is incorrect?
Attachments:
Find Object Testing.vi ‏30 KB
Find Object_closingreference.png ‏5 KB

pauldavey,
I agree with you again that the behavior of "Find Object.vi" does not appear to be optimal.  It is almost as if it should be called "Select Object.vi" as it doesn't appear to be handling the case in which no objects are found very well.
The help file states that it:
Takes a 3D scene reference
and an object name and returns the first object in the scene with a matching
name.
As it's behavior is not defined for the event that a matching object is not found I would recommend writing your own VI to perform the function you need.
I plan on looking a little further into this and I may end up filing a CAR for this behavior too.
We appreciate the feedback and I apologize for the difficulties this VI is causing you.
Regards,
Simon H
Applications Engineer
National Instruments

Similar Messages

  • Questions on 3D picture control and STL file

    Hi,
    I am currently working on a project in which I load an STL file to vizualise a 3D object (see attachment). I have several problems and questions.
    1) I would like to execute rotations (X,Y,Z) on this 3D object. Unfortunately, Labview executes only one rotation and I don't know why
    2) If I load several objects, is it possible to create links/joints between them? I saw the example with the robot arm provided in the Labview examples, but I don't understand where and how the joints are defined.
    3) Is it possible to import an image (png, jpeg,..) on a scene display? I would like to visualize a graduation to see the number of degrees of rotation of my object.
    Thank you for your answers
    Message Edited by kastillio on 10-23-2009 04:24 AM
    Attachments:
    load_stl_geom_8_6.zip ‏56 KB

    Thank you so much for your post on our forum.
    I created an example based on the VI You send Fact is that we need to use relative rotation. With absolute the previous rotation is cleared and the new rotation is done from the zero point. With your example this means that you first do the Y rotation and immediately the X rotation is done resetting the previous Y rotation. If you swap these two rotations you will notice that only the Y rotations works because the previous X will be reset.
    As said I made an example based on relative rotation so the rotation will be done from the current position. I used the rotate object.vi and used a event structure looking at the value change from the x or y control. The function will be executed when these value changes occur.
    Best regards,
    Martijn S
    Applications Engineer
    NI Netherlands
    Attachments:
    load_stl_geom_8_6.vi ‏18 KB

  • ACR 4.6 Picture Controls

    I am confused about what is happening.  Any help would be appreciated.
    I understand that Nikon Picture Controls can be used to change the color balance which may give better color.
    I am running CS3 in a 64 bit Vista Ulimate operating system
    What I am trying to understand is how the Camera Profile works in the Camera Calibration tab in ACR.  I am currently shooting a Nikon D200 and a D300.  I understand that Nikon picture controls can be available in the Camera Profile of the Camera Calibration tab
    I went to http://www.adobe.com/support/downloads/thankyou.jsp?ftpID=4040&fileID=3754 and downloaded ACR 4.6.  I then unzipped and installed.
    After installing ACR 4.6 I downloaded and installed GND 5.5 at http://www.adobe.com/support/downloads/thankyou.jsp?ftpID=4576&fileID=4244
    The Title bar in ACR shows Camera Raw 4.6.  The Camera Profiles in the ACR Camera Calibration tab shows ACR 4.4 and 4.3.  After installing GND 5.5 the Nikon Picture Controls (NPC) appear in Camera Profiles.  When I click on one of the NPC it seems to work but the Shadows, Red green and Blue Primaries are not changed.
    When I go to the DNG 5.5 DNG Converter in the compatibility section of the preferences section it says that it should work for 4.6 and later.
    My confusion relates to the fact that my Camera profile in the Camera Profile shows ACR 4.3 and 4.4 – not 4.6 and the DNG converter preferences says 4.6 and later.  Someone that I know who downloaded and installed ACR 4.6 and DNG at the same time has the camera profile showing 4.6. 
    Do I have a problem or am I spinning my wheels?  If I have a problem how do I correct the Problem?

    Forums #1 wrote:
    My confusion relates to the fact that my Camera profile in the Camera Profile shows ACR 4.3 and 4.4 – not 4.6 and the DNG converter preferences says 4.6 and later.  Someone that I know who downloaded and installed ACR 4.6 and DNG at the same time has the camera profile showing 4.6.
    The fact that there are two older profile versions (4.3 & 4.4) simply mean that the FIRST version to support your camera model was 4.3. The fact that 4.4 is there as well means the profile was modified (improved) for ACR 4.4. the reason both are there are for legacy reasons...
    Looking at the Profile drop-down is NOT the way you determine the current version of Camera Raw you have loaded...the ONLY way is using the  "About Plug-ins" menu item or looking at the main ACR title bar in the window (as long as you aren't at full screen).
    If you have the Adobe Standard and the vender looks profiles loaded, you're good to go...as to what those profile will or won't do to and for your image...well, that's for you to decide. I tend to use Adobe Standard.

  • My finder will not close down. it only allows to relaunch

    My finder will not close down and when I force quit. It only allows to relaunch. It is causing stability issues throughout my computer.

    The finder has to restart, otherwise you won't be able to do anything on your computer(open windows, switch windows, and open files).

  • Find Object.vi function of 3D picture control - when object not found

    I am using Labview 8.2, and this post is regarding the 3D Picture Control.
    I am wanting to make use of the "Find Object" VI to either return a reference to a named object, or otherwise determine that it does not exist yet.  However, if I call it with the name of an object that doesn't exist yet (i.e. just any random string), it returns an error message that arises from the attempt to release a queue (the reference to which gets lost when crossing a zero-iteration For Loop's tunnels), instead of an error message that says "Object not found" which I would find much more useful.  With a simple modification of the "Find Object.vi" function, this behaviour can be changed, by replacing the For Loop's tunnels with shift registers.
    The problem with the current function is that the error is not an intentionally thrown error, rather just the result of the queue's refnum being set to the default 0 as it "exits" the For Loop, since in the situation that an object is not found, the code passes a 0 to the N terminal.
    The attached images show the problematic code and the simple modification
    Attachments:
    Find Object.png ‏2 KB
    Find Object_modified.png ‏2 KB

    pauldavey,
    I agree with you - the current way of handling the case of an object not being found does not appear to be ideal.
    This was reported to R&D (# 43D8GSVQ) for further investigation.
    Thanks for the feedback!
    Regards,
    Simon H
    Applications Engineer
    National Instruments

  • 3d picture control view single object

    I'm using the 3D picture controlfor the first time and I'm amazed at how much faster it is at drawing than the old Picture control.  Likey Likey.
    What I would like to do is to abuse the 3D picture control as a 2D picture control but I need to fill the viewport with a single side of a box created in the scene.
    I can create the box to have th same orientation and size of the viewport and also create the texture for the box the same size, this is no problem.  What I want in the end is to have my texture pixel-perfect in the viewport of the 3D picture display.
    I can do this manually via "projection Matrix" and "model View Matrix" but I don't quite understand where the numbers come from.  Since I'm a bit of a dunce when it comes to matrix transoformations, can somebody perhaps help me out with some tips on where to find this informaiton out?
    Shane.
    Say hello to my little friend.
    RFC 2323 FHE-Compliant

    I worked it out. 
    Knowing that the corners of the viewport are always from -1,-1 to 1,1 regardless of the actual aspect ratio of the indicator it's kind of easy to work out the settings required.
    Simply paint a texture on a 1x1x1 cube and voilà.
    I'm amazed at the difference in speed between the old picture control and the new 3D picture control.  Is it hardware-accelerated?
    Shane.
    Say hello to my little friend.
    RFC 2323 FHE-Compliant

  • BCG Brightness Contrast Gamma - Looking for BCG function returning color table / lookup table coded in pure G and applicable to Intensity Graph or Picture Control

    Looking for BCG function returning color table / lookup table coded in
    pure G and applicable to 8-bit Intensity Graph or Picture Control. Do
    not want to use IMAQ Vision is this particular application.  Any
    help is appreciated.
    Sincerely,
    Don

    Take a look at this color model software I put together.  (Don't concern yourself much with the basic programming at this point.). The color component generator subVI is borrowed from a LabVIEW example.
    First look at test_color2.vi.  If you adjust the sliders of the various controls, you will see how it works.  You can see that for pure B&W images, brightness, contrast, and gamma (which I think I have coded correctly) are all fairly straightforward to modify.
    Now look at test_color3.vi.  Here we try to adjust BCG for color images using the color model shown here where current color component clusters are carried into the BCG event cases via shift registers.  You can see that once color is introduced into the image, it becomes difficult to mix the colorizing with the BCG model.  And this is pretty much where I am right now.
    Would be interested in comments / suggestions.
    Sincerely,
    Don
    Attachments:
    test_color2.llb ‏2251 KB

  • How can I view my object in Labview's 3D picture control?

    Hey everyone,
    I'm very new to Labviews interface and was wondering how I can go about creating a VI (or subVI) to load my pre-existant VRML file and display it using 3D picture control.
    Just looking for a very simple solution.
    Many Thanks!
    Solved!
    Go to Solution.

    Hi,
    The VIs used to load a VRML file are only included in the Full Development System version of LabVIEW according to the help. If you do not have a Full Development System License you won't be able to find those VIs.
    You can find them under : Programming » Graphism and sound » 3D Picture control » File loading (sorry for the bad translation I have French version).
    Regards,
    Da Helmut

  • Examples of scenes rendered by the new LV 3D picture control (2)

    According to NI News august 6, 2004, there is a new :
    8. Download LabVIEW 3D Picture Control Evaluation Software With the new LabVIEW 3D Picture Control evaluation software for LabVIEW 7.1, you can model and render basic 3D scenes for advanced visualization in LabVIEW. Download the software at:
    http://digital.ni.com/express.nsf/bycode/nn0804a08
    I've downloaded it for evaluation, but couldn't install since I run LV 7.0 Express, so I stated the previous request for some samples of scenes
    Any help would be appreciated

    Unfortunately the dedicated topic for the 3D Picture Control tools was lost in the transition. The old forums had the concept of a "topic", which was different from a typical question or other thread, and they were not migrated.
    One of most useful parts of that thread was a link to the download page for the tools, which I will post here.
    LabVIEW 3D Picture Control Evaluation Software
    Additionally, I have created a new dedicated forum post for these items. The new dedicated forum for these 3D tools is here.

  • How to convert from Finder Object reference to POSIX path

    I'm new to AppleScript. I'm super close to getting what I need done, but I've ran across a snag in the middle.
    The error I'm getting is Can’t make quoted form of POSIX path of item 1 of {«class docf» \"filename\" of «class cfol» \"foldername\" of «class cfol» \"Desktop\" of «class cfol» \"Username\" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\"} into type Unicode text. the problem area is highlighted and notated below. I've looked all around online but can't find what I need.
    Thanks in advance for any and all help!
    set text item delimiters to "."
    tell application "Finder"
      set theFilestoChoose to every item of (choose file with prompt "Please select the file(s) you would like to move and rename" with multiple selections allowed) as list
      display dialog "Would you like to move these files to an existing folder and then rename them, or create a new folder and then rename them?" buttons {"Move to an existing folder and rename", "Create a new folder and rename"}
      if result = {button returned:"Move to an existing folder and rename"} then
      set firstnewname to "Aauuttoommaattoorr"
      repeat with index from 1 to the count of theFilestoChoose
      set theFilesChosenbeingrenamedfirsttime to item index of theFilestoChoose
      set filenamecount to text items of (get name of theFilesChosenbeingrenamedfirsttime)
      if number of filenamecount is 1 then
      set fileextension to ""
      else
      set fileextension to "." & item -1 of filenamecount
      end if
      set the name of theFilesChosenbeingrenamedfirsttime to firstnewname & index & fileextension as string
      end repeat
      log theFilesChosenbeingrenamedfirsttime
      set choosingtheplacetomove to choose folder with prompt "Select the folder to move to"
      set thechosenfoldersname to name of folder choosingtheplacetomove -- sets the folder name as text
      set AppleScript's text item delimiters to {"-"}
      set Numberofthemonthatthebeginningofthefoldername to text item 1 of thechosenfoldersname as string -- for later to append the number back on without having to ask again!
      set shortenedname to text item 2 of thechosenfoldersname as string
      set the name of choosingtheplacetomove to shortenedname as string
      set thefolderstemporarynameaslocation to choosingtheplacetomove as string
      move theFilestoChoose to folder thefolderstemporarynameaslocation
      log theFilestoChoose
      set allfilesindestinationfolder to every file in choosingtheplacetomove as alias list --
      set aInitials to the text returned of (display dialog "Whose camera were this/these pictures taken on?" default answer "")
      set filteredList to my filterList(allfilesindestinationfolder, aInitials) as list
      log filteredList
      -- everything above this is correct so far and works perfect
      --TROUBLE SECTION BELOW
      set theSortedfilterList to (sort filteredList by creation date) -- something happens here with the theSortedfilterList that makes it unintelligible to convert to POSIX later. but I need the files in the order that this line puts them.
      log theSortedfilterList
      set timetorenamelasttime to theSortedfilterList
      set newbasename to shortenedname
      repeat with index from 1 to the count of timetorenamelasttime
      set theonefile to item index of timetorenamelasttime
      set theonefilenamecount to text items of (get name of theonetwothreefile)
      if number of theonefilenamecount is 1 then
      set fileextensionone to ""
      else
      set fileextensionone to "." & item -1 of theonefilenamecount
      end if
      tell application "System Events" to set CreaDate to creation date of file theonefile
      set CreaDate2 to CreaDate as text -- need to trim down to the first 10 characters and eliminate the "-"
      set AppleScript's text item delimiters to {""}
      set shorteneddatename to text items 1 thru 10 of CreaDate2 as string
      set the name of theonefile to shorteneddatename & {"-"} & newbasename & {"-"} & aInitials & {"-"} & index & fileextensionone as string
      end repeat
      --Trouble section above
      set the name of choosingtheplacetomove to Numberofthemonthatthebeginningofthefoldername & "-" & shortenedname as string -- returns the month prefix to the foldername
      else if result = {button returned:"Create a new folder and rename"} then
      set repeatConfirmation to true --Boolean to decided if script should be repeated; default is to repeat
      repeat while (repeatConfirmation = true) --Repeat if Any Tests Are Failed
      set thefirstquestion to choose from list {"January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"} with title "Event Month Selection" with prompt "Select the month in which the event started. Select only one month:"
      set theMonthAnswer to result
      if theMonthAnswer = false then --"For historical reasons, choose from list is the only dialog command that returns a result (false) instead of signaling an error when the user presses the “Cancel” button."
      set repeatConfirmation to false
      set exitingeventmonth to display dialog ("You are exiting selecting the event month phase of the program. You will need to manually fix this decision") buttons {"OK"} with title "Exiting Event Month Selection"
      if button returned of exitingeventmonth = "OK" then
      set theMonthAnswer to ""
      end if
      else
      set confirmationanswer to display dialog "You selected " & theMonthAnswer & ", is this correct? " buttons {"Yes, that's correct.", "No, the picture(s) are from a different month."} with title "Confirm Event Month Selection"
      if button returned of confirmationanswer = "Yes, that's correct." then
      set repeatConfirmation to false
      else
      display dialog ("That's okay, you can select another again!") buttons {"OK"} with title "Return to Event Month Selection"
      end if
      end if
      end repeat
      log theMonthAnswer
      if theMonthAnswer = "" then
      set monthtonumber to "You have cancelled this action."
      log monthtonumber
      else if theMonthAnswer = {"January"} then
      set monthtonumber to "01"
      log monthtonumber
      else if theMonthAnswer = {"February"} then
      set monthtonumber to "02"
      log monthtonumber
      else if theMonthAnswer = {"March"} then
      set monthtonumber to "03"
      log monthtonumber
      else if theMonthAnswer = {"April"} then
      set monthtonumber to "04"
      log monthtonumber
      else if theMonthAnswer = {"May"} then
      set monthtonumber to "05"
      log monthtonumber
      else if theMonthAnswer = {"June"} then
      set monthtonumber to "06"
      log monthtonumber
      else if theMonthAnswer = {"July"} then
      set monthtonumber to "07"
      log monthtonumber
      else if theMonthAnswer = {"August"} then
      set monthtonumber to "08"
      log monthtonumber
      else if theMonthAnswer = {"September"} then
      set monthtonumber to "09"
      log monthtonumber
      else if theMonthAnswer = {"October"} then
      set monthtonumber to "10"
      log monthtonumber
      else if theMonthAnswer = {"November"} then
      set monthtonumber to "11"
      log monthtonumber
      else if theMonthAnswer = {"December"} then
      set monthtonumber to "12"
      log monthtonumber
      end if
      set theNameofFoldertoMake to text returned of (display dialog "Please enter the name of the new folder you are creating:" default answer "" with title "New Folder Name")
      set LocationOfNewFolder to choose folder with prompt "Choose the location of the new folder you are creating:"
      set theNewNameofFoldertoMake to monthtonumber & "-" & theNameofFoldertoMake
      set newfolderaction to make new folder at LocationOfNewFolder with properties {name:theNewNameofFoldertoMake}
      move theFilestoChoose to newfolderaction
      end if
    end tell
    --function
    on filterList(allfilesindestinationfolder, aInitials)
      set patterns to {aInitials as string, "Aauuttoommaattoorr"}
      set output to {}
      repeat with aFile in the allfilesindestinationfolder
      repeat with aPattern in patterns
      set filepath to aFile as string
      if filepath contains aPattern then
      set end of the output to aFile
      exit repeat
      end if
      end repeat
      end repeat
      return output
    end filterList

    Okay, so you wanted the debugging and error messages. Thank you for the coaching. Here is what I get from the following line:
    set theSortedfilterList to (sort filteredList by creation date)
    log theSortedfilterList
    Log returns:
    (*document file Aauuttoommaattoorr3.AVI of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk, document file Aauuttoommaattoorr2.MOV of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk, document file Aauuttoommaattoorr1.mov of folder SnowDay of folder Desktop of folder Username of folder Users of startup disk*)
    set pxFile to POSIX path of ((theSortedfilterList) as alias)
    Error: "Can’t make {«class docf» \"Aauuttoommaattoorr3.AVI\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \"Username\" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\", «class docf» \"Aauuttoommaattoorr2.MOV\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \" Username \" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\", «class docf» \"Aauuttoommaattoorr1.mov\" of «class cfol» \"SnowDay\" of «class cfol» \"Desktop\" of «class cfol» \" Username \" of «class cfol» \"Users\" of «class sdsk» of application \"Finder\"} into type alias." number -1700 from {«class docf» "Aauuttoommaattoorr3.AVI" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk», «class docf» "Aauuttoommaattoorr2.MOV" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk», «class docf» "Aauuttoommaattoorr1.mov" of «class cfol» "SnowDay" of «class cfol» "Desktop" of «class cfol» "Username" of «class cfol» "Users" of «class sdsk»} to alias
    That is why I labeled it with Finder Object reference won’t return POSIX path, because I tried what was suggested about using the POSIX path of line. I thought seeing the lines above and around it would help set the context.
    So I need those files, but I need them sorted by creation date so that they’re in that order for the next renaming step.

  • 3D Picture Control Orthographic View zoom - Camera Set up?

    I am trying to display two 3D picture controls.  One displays some objects in 3D (Auto Projection: Perspective, Camera Controller: Spherical).  This 3D image works great and I am having no problems with it.  The other Picture Contol is meant to simulate a 2D image of the 3D object, essentially a Plan View.  To do this I made a 3D picture control with a Orthographic view.  I set the camera to view from above (z-axis) and set the target to be positive y-axis. 
    I have attached an example vi (labview 2013 SP1) that creates some simple 3D objects and displays them in Perspective and Orthographic using the same Camera Position.  On initial start, the Orthographic image is zoomed in heavily. If I manually zoom it (Hold Shift button and mouse up or down), then the Orthographic image will set itself to the correct Camera position.  This is essentially the solution to my problem, but I can't assume the user will have the ability to manually zoom the image.  So I need to set it programmatically.
    If you manual adjust the view on either screen (rotate and zoom), then click the Set Camera button, both images will give a plan view, but only the Perspective Image will be at the correct camera zoom or distance.  The Orthographic stays at the last zoom distance.
    Is there any way to set the Camera distance for Orthographic projection programmatically?   I have tried starting with the 3D picture control as perspective, set the camera distance and then changing it to orthographic, but this still results in a zoomed orthographic image.  From the reading I have done, I think I am trying to the impossible.  Does any one have another suggestion to get the same result.  I have previously used the 2D picture functions to generate the image but found that method inefficient. 
    And suggestions would be great.
    Thanks
    Relec
    Attachments:
    3D_projection_Test.vi ‏38 KB

    Hi Relec,
    thank you (and Kudos) for that inspiring demo!
    Took me while to work it out, but I might have found something that could help us with the orthographic projection.
    Sometime back someone posted a way to collect the current Camera data. Sorry I lost the source. But here is my version as a Get3DCameraPosition.vi using the ModelViewMatrix.
    Unfortunatly this doesn't return the current Target and so a bit of guessing in the right Direction is necessary.
    I'm impressed you found a way to make the Shift-Drag Zoom-movement possible on the orthographic window.
    It seems a whole thread at http://forums.ni.com/t5/LabVIEW/3D-Picture-Control-Doesn-t-Zoom-in-Orthographic-Mode/td-p/1544460/page/2 wasn't able to find that out.
    In the meantime I've found a way using the ProjectionMatrix to create a zoom-effect which I build into your demo using the mouse wheel.
    All in all I've tried to translate camera movements from the perspective window in the ortho - assuming this is what you were after?!
    Again the missing target information doesn't make it quite right.
    Regs
      Jannis

  • Stl get/find object?

    Hello, I am fairly new to LabView and using CAD models, so I'm sorry if my question sounds silly...
    I have been given a stl file to create a 3d simulation in LV for a group project and I'd like to ask whether there's a possibility of adding some colour or texture to the stl models in LV so they don't appear gray. I have been looking at multiple online examples using both wrl files and stl files, but I only saw techniques such as finding and getting objects from a 3d scene and colouring them were used for wrl files and not for stl. So I was wondering - are there some other techniques to acquire single objects from stl scene and "paint" them?
    Thanks in advance for any answers,
    D.
    PS.
    I'm using LabView version 9.

    Hi losiek,
    I'm not very familiar with 3D control but I think I've found a few links that may help.
    3D Picture Control - Create a Moving Texture Using a Series of Images
    3d Texture mapping problem
    LabVIEW 3D Picture Control Evaluation Software Discussion
    I hope this helps.
    Kind regards,
    Rico P

  • Mouse down on 3D picture control

    Hi,
    i would like to know how to indicate mouse down on the 3D picture control as can be done for the picture function.
    http://forums.ni.com/ni/board/message?board.id=170&message.id=49423&query.id=66219#M49423
    regards
    king1

    Hi King1
    I have been able to modify an example VI which came with LabVIEW v8.2 which uses the 3d picture control. I have added an event structure to the code which allows the user to pause the rotation of 2 objects in the picture display area. I have added notes to the block diagram which should help in describing its behaviour. the file is attached with this post.
    I hope this is of some help, there are a few more 3d picture examples in the LabVIEW example directory which might also be of use.
    Best wishes
    Rob L
    Rob L
    NI Applications Engineer
    UK & Ireland
    It only takes a click to rate this message ;-)
    Attachments:
    3D Picture with User Selection.vi ‏61 KB

  • How do i set the size of 3d picture control

    dear sir,
                I have attached my vi.I have one doubt  ie I have used translate object. vi in my vi to move my picture according to the value set by the y position.This y position indicates depth my object.this is sample object  insteat of i am going to update my underwater vehicle.
    What my problem is when i chnage the y value beyond 200 I can not see my picture.so  how do i set the size of the 3d picture control size.
           I have to see my picture within the 3d picture control eventhough i change the y value between 0-500,how do i solve my problem.
    Another my doubt is how do i show the depth value (ie y value in translate object .vi) in 3d picture control ie while the picture is moving in a 3d picture control at the same time i want to display the corresponding depth rating in the 3d picture control
    Pls anyone suggest me as soon as possible.
    Thanks and regards
    jayanthi.k
    Attachments:
    Untitled 1.llb ‏67 KB

    Jayanth,
    Take a look at the attached example.  Alternatively, you can search for it in NI Example Finder by going to Help>>Find Examples in LabVIEW, click on the search tab, and search for meshes.  I had difficulty reading your code, but I believe you need to position your lighting source in the optimal location to get better definition.  And the example shows how to bind a color to the object.
    Trey B
    Applications Engineering
    National Instruments
    Attachments:
    Using Meshes.vi ‏76 KB

  • How can I determine mouse position within a 2D picture control

    I have an application where I'd like the user to be able to interact with objects drawn in a 2D picture control using the mouse.  In order to do this, I need to translate between screen coordinates, which are passed with the mouse events, and coordinates in the 2D picture control.
    The problem I'm running into is that I can't find a way to determine the screen coordinate of the upper left hand corner of the 2D picture control's drawing/client area.  I tried using the picture control's "Position" property, but this results in an offset due to the difference between the upper left hand corner of the picture control (including the label, etc.) and the upper-left hand corner of the drawing area.  See attached VI.
    Does anybody know how to get the screen coordinate of the corner of the picture control's drawing area?
    Mark Moss
    Solved!
    Go to Solution.
    Attachments:
    2D Picture Mouse Test.vi ‏27 KB

Maybe you are looking for