Transparent Picture Control Quirks?

(cross-posted to LAVA)
Can anyone explain this?
A Picture Control that has been painted transparent has a different Erase First behavior in the context menu.
Regular picture control, dropped right off the palettes:
Note that the Erase First item is enabled, and checked by default.
But, if we use the paintbrush to paint the interior of the Picture Control transparent and then bring up the context menu again:
Note that now Erase First is checked and disabled so it cannot be unchecked.
But there's more.  If you try to set the Erase First behavior programmatically, LabVIEW doesn't generate an error and seems to accept the setting, but the change isn't reflected in the context menu:
It also appears that, regardless of the behavior shown, a Picture Control that's been painted transparent ignores all programmatic Erase First settings and behaves as though it's set to Always Erase.  This, in turn, means that if you set a Picture Control's background to transparent, it will always tend to flicker as you draw more stuff to it, unless you take special precautions (like deferring panel updates).
Why does a transparent-background Picture Control behave differently from a Picture Control with an opaque background?
Message Edited by Justin J. Goeres on 12-01-2008 02:30 PM

Since;
1) Justin is used to the "Dark-side" and
2)all picture related question interest me
3) And NI does not answer Q's on LAVA I will help out a bit. The following is what I think Justin wanted us to see,
Justin J. Goeres wrote:
(cross-posted to LAVA)
Can anyone explain this?
A Picture Control that has been painted transparent has a different Erase First behavior in the context menu.
Regular picture control, dropped right off the palettes:
Note that the Erase First item is enabled, and checked by default.
But, if we use the paintbrush to paint the interior of the Picture Control transparent and then bring up the context menu again:
Note that now Erase First is checked and disabled so it cannot be unchecked.
But there's more.  If you try to set the Erase First behavior programmatically, LabVIEW doesn't generate an error and seems to accept the setting, but the change isn't reflected in the context menu:
It also appears that, regardless of the behavior shown, a Picture Control that's been painted transparent ignores all programmatic Erase First settings and behaves as though it's set to Always Erase.  This, in turn, means that if you set a Picture Control's background to transparent, it will always tend to flicker as you draw more stuff to it, unless you take special precautions (like deferring panel updates).
Why does a transparent-background Picture Control behave differently from a Picture Control with an opaque background?
Message Edited by Justin J. Goeres on 12-01-2008 02:30 PM
Message Edited by Ben on 12-01-2008 04:05 PM (eastern US)
Ben
Ben Rayner
I am currently active on.. MainStream Preppers
Rayner's Ridge is under construction

Similar Messages

  • How do I get picture control to display PNG images with transparent background?

    I have an image of a robot arm looking from the top with a transparent background and saved as PNG. When I drag the image directly to LabVIEW front panel, the image shows properly with the transparent background, but I want to manipulate it such as rotate the image. I used the Read from PNG.vi to read the image to a picture control, but the background isn't transparent anymore. Am I missing something?
    Please help.

    unclebump gets 5 stars for referring you to a document that I wrote. 
    Incidentally, I wrote it years back, for LabVIEW 7.0.  A couple of notes to summarize:
    The picture control doesn't "really" support transparency.  However, the image data type supports masking, and stores the alpha channel, if present in your image data.  So you use the "Create Mask By Alpha.vi" referenced in that document to mask out pixels whose transparency is above a certain level.  It does not support partial transparency.  You could try to implement your own blending algorithm based on the picture control's current pixel values, and the image data's RGB value and transparency value, but it would probably be very slow.
    Also, that VI ships with 8.0 and later.  I don't know if it's on the palettes but it lives here:  vi.lib\picture\picture.llb\Create Mask By Alpha.vi
    Good luck!

  • Set 2d picture control image

    I'm making some palette installers for ease of distribution for some libraries I have written. I'm following the example VIs (search the example finder for "palette API").
    I'm having some frustration in setting the new palette icon; the icon constant is a 2d picture control but I can't find a way to drop my image into it, and I can't set it programatically as the 2d picture control VIs only allow me to draw shapes into it.
    - Cheers, Ed
    Solved!
    Go to Solution.

    In cases like this I often resort to using a transparent classic path as an overlay to catch dropped files.  If you do not plan on interacting with the picture control, it is quite easy.  Otherwise it is just a few more events to control visibility when the mouse enters the VI with the button pressed.
    Just run the VI and drag PNG, JPG, or BMP files to the picture control.
    Attachments:
    DragToPictureControl.vi ‏16 KB

  • How to drag a file into a picture control in a runing VI?

    When the VI is runing, LabVIEW allows users to drag a file from windows explorer to the File path control to get the path. But how could I drag a file into a picture control to get some event?
    Since the Picture control will also used to reponse to some other events so put the a transparent file path control on top of it may be the last idea in my mind...
    Is there any other options??
    Thanks guys!

    In Dreamweaver CS4, whenever I try to drag a newly updated version of a swf file into a certain directory / folder in the Files panel of the Dreamweaver interface, the file simply gets placed under my website's root instead.
    You are dragging the file from OUTSIDE of DW (using Explorer/Finder) and dropping it within DW's FILES panel (I didn't think you could do that!)?  Or you are dragging it from within the FILES panel, but from outside your site (by choosing "Local Disk" from the drop list)?  I think what you are seeing is the best you will get with that procedure.  Try going to "Local Disk" and copy the file, then return to your site and paste it where you want it.

  • Can you programmat​ically change a picture control frame/bord​er

    In a platform neutral manner can I programmatically change a picture control frame/border
    Solved!
    Go to Solution.

    You can make it look that way using many differnt methods.
    The simplest is to make the border transparent and put a boolean behind the picture. Size the boolean so it looks like it is the border of the picture. Change the color of the boolean and you are on you way.
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Replacing colors in a picture control

    Hi all,
    I'm running into some performance issues with the frequent updating of colors in a picture control. This is the method I'm currently using to update the colors.
    The picture contains only two colors; the color of the icon, and the pane color to mimic transparency.
    is this method possibly too slow and could be the culprit of perfomance issues, and is there a better way of doing this?
    Thanks

    Hi Gazebo,
    a loop-less approach:
    It's not perfect as it creates datacopies and has a coercion dot inside, but may provide ideas!
    You may even use ReshapeArray to work with a 1D array (in the core of the routine), LabVIEW usually is faster then…
    Best regards,
    GerdW
    CLAD, using 2009SP1 + LV2011SP1 + LV2014SP1 on WinXP+Win7+cRIO
    Kudos are welcome

  • Remove a picture control's frame ?

    I have an app where I need to place several 200x200 pixel picture controls on the front panel.
    I would like to remove the standard frame/border so that only the content is displayed.
    Solved!
    Go to Solution.

    Use the picture from the classic pallette and use the paint brush tool to color the border transparent (T).
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • Open pdf and display it in picture control or picture box in LV8.5

    Im trying to open a pdf in labview v8.5 and post it in a picture control or picture box (activeX). Any help would be appreciated. thanks.
    M

    mblu,
    Check out these Forums that seem to have figured out how to do this using ActiveX.
    PDF in labview front panel
    Displaying A PDF File on the Labview Front Panel
    Import a pdf document to an active x control
    Ben Sisney
    FlexRIO V&V Engineer
    National Instruments

  • How do I apply a texture to an imported .stl file in 3D Picture Control?

    Hi, I'm trying to apply a 2D image as a texture to an imported .stl file in 3D picture control. It works fine if I'm using a standard shaped mesh created in LabVIEW, however is there a way in which a texture can be applied to an imported model that isn't a standard shape, in my case a balloon. I've attached the an image of the Sub vi where I apply the texture. The object just shows up as a flat colour. Do I need to define how the image is applied to the mesh due to it being a non-standard shape? If so, any pointers would be appreciated.
    Many thanks.
    Oh, I'm using LabVIEW 2009 SP1.
    Attachments:
    stl texture problem.jpg ‏60 KB

    Apologies, been trying all afternoon and then a couple of minutes after posting, I figured it out. Using a property node for the Scenemesh reference, I set the property TextureGenMode to Spherical and it appears to now display the texture on the mesh.

  • Loop delay when using two VI's with picture controls simultaneously

    Hey all,
    I have observed an odd behavior and I'm not quite sure why it happens. I have two VI's that are mapping GPS coordinates onto XY graphs that are displayed on top of picture controls. When the maps from both of the VI's are visible on screen the loops get delayed by as much as a second, but if you just cover the map portion with another window they go back to looping at twice a second as they should. It took me a little while to figure this part out, let me tell you. There are no computing limitations that should be affecting it since my CPU is only at 10-12% and have 4GB of RAM available. I checked the GPU too just in case and it was sitting at 3% usage, so no hold up there. Anyone have any experience with something like this happening to them? It has me stumped.
    I though it might have to do with how LabVIEW handled them, so I went ahead and made them into EXE's and tried it out with the same results.
    Thanks in advance for any help or suggestions,
    dnorman

    dnorman wrote:
    Is it possible to run the redraw of the picture tiles in parallel, on multiple cores, if they are going into the same control?
    I doubt it. Even if the picture control wasn't pretty old (and it is), I don't know of any mechanism which will give you this level of control.
    Here are potential options. I have no idea if they will help:
    Instead of building separate commands, process the data in such a way that you have a single raster image (i.e. a 2D array) to place into the control. I believe this should be faster.
    Use another type of display (such as a .NET indicator).
    Instead of using the XY graph, overlay the data directly onto the image (there should be some graph VIs in the picture palette which might help).
    Try defering panel updates before updating all the controls and undefering after. I don't think this will help, but it's probably the easiest change to make.
    Try to take over the world!

  • Inserting a small graphics in a picture control

    Does any one have an example code for inserting a small graphics/8 bit bmp file (15x15) in a relatively large (240x360) 8 bit jpeg image at known location in LabVIEW using Picture Control? Thanks in advance.

    Hello,
    To read an image file (BMP, JPG, PNG) and put it into a picture control you can use the OpenG function "draw image from file", and then use the picture control property "Zoom" to fit it correctly.
    Here's an example :
    You can get OpenG functions from here.
    Hope this helps.
    When my feet touch the ground each morning the devil thinks "bloody hell... He's up again!"

  • 2D picture control doesn't refresh properly

    I have an application which displays a picture in a 2D picture indicator and draws a few rectangles and lines on top of the picture. 
    The locations of these lines change throughout the day, and the application is designed to run minimized and then provide a quick-look at various status items when it is restored by the user.
    While minimized however, the image does not appear to get updated, even though my code is updating it once per second. I can't actually tell what happens when it's minimized obviously, but the behavior persists for some time after the window is restored, and the state it is 'frozen' at is from the time it was minimized.
    There are other digital indicators on the front panel getting updated in the same 1Hz loop, so I know it is just the 2D picture indicator that's not working--i.e., something with LabVIEW or system related is causing the image not to refresh while it's minimized, and more importantly, for some time after the application is restored.
    Some things that will cause a successful refresh to the displayed image after I restore from the task bar to a stale display:
    Minimize again, then restore again (of the LabVIEW window)
    Probing the datapath on the BD for the final Draw Line output that connects to the indicator
    Waiting for awhile (15 seconds? 30 seconds?)
    I also tried setting the following property node with no effect: 
    VI > Panel > Defer Panel Updates > Set to False
    Another way to think about this would be to imagine a 2D picture control with an analog clock, where lines are drawn for minute and hour hands, and updated once per second.  This is not what I'm doing but the example is easy to understand.  When the application is restored from the taskbar, the clock appears frozen in time from the last time it was minimized.
    Same behavior running this in LV 2012 and 2013... I am looking for any other property nodes or refresh methods to force a refresh at 1Hz, regardless if the display is visible.  The display should be immediately up-to-date when the application is restored by the user.
    Solved!
    Go to Solution.

    You could try looking at the panel resize event (to recognize the restoring) and then force an update using one of the following methods (I have no idea if they will help):
    Set defer to T and only then to F.
    Set defer to T when minimizing.
    Set the FP window state to something else (hidden, minimized, etc.) and then to standard. This should ideally do the same thing you did with minimizing and restoring again.
    Use the window position property to place the window off the screen and then back in its original position.
    See if you can toggle the synch. updates property programmatically.
    Have a hidden control displayed over the picture control and then hide it.
    Try to take over the world!

  • Save content of picture control as .jpg into excel file?

    Is it possible to save the contents shown of a picture control as a jpeg file into an excel file along with other data? Is this possible without using ActiveX? If I have to use ActiveX how do I use this?
    Thanks

    Hello AndyBE,
    ActiveX is definitely going to be your best bet. I�ve attached an example that should meet your needs. Let me know if this works for you.
    Have a nice day!
    Robert Mortensen
    Applications Engineer
    National Instruments
    Robert Mortensen
    Software Engineer
    National Instruments
    Attachments:
    Picture_To_XL_(6i).vi ‏133 KB

  • How can I load a graphic in SOFFCONT1 into an SAP picture control?

    At my customer site, GOS attachments to PM notifications are stored in SOFFCONT1, so I can't use cl_bds_document_set to get a URL that I can pass to the load method of the SAP picture control.
    How can I load the actual graphic in SOFFCONT1 into an SAP picture control?
    Or do I have to configure IW22 so it stores in BDS content servers, not SOFFCONT1?
    If this is the case, how do configure IW22 so GOS knows to store attachments as BDS documents rather than in SOFFCONT1 ???
    Thanks
    djh

    This explains how to make sure your PC and bin documents are saved on your HTTP content server, instead of in the database:
    http://help.sap.com/saphelp_nw04/helpdata/en/c0/1aca5823ee11d3a2db00a0c943858e/content.htm

  • 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

Maybe you are looking for

  • Standard Reports in M M

    Dear All, I need these are all the standard Reports... 1. Purchase Requisition link with Purchase Order Report. 2. Purchase Order, Order Qty, Received Qty(GR), Open Qty Wise Report 3. Purchase Order, Order Qty, Received Qty(GR), Open Qty, Invoice Ver

  • CD Drive no longer imports CDs in iTunes

    I had been successful importing and porting music tracks to my Ipod for a few months then all of a sudden the import bombs in the second or third track of a CD by giving an error message much like when a USB drive is improperly disconnected. Then the

  • HT6114 mac os 10.9.2 update conflict with adobe camera raw ?

    All of a sudden Adobe camera raw won't convert either raw Canon or Leica files.  Keep getting the error code to re-install CS6, but that does not solve it.

  • Audio not working properly in U410. Need to retry several times, and then it works

    Hi, I have an U410 with Win 8.1. I went throught the troubles upgrading to 8.1. Installed the Conexant driver 8.65.3.53, and then de Dolby Gui. However, when I want to: listen to music, see a film with WMP, or see a youtube video, the sound doesn't w

  • Me~ear terminates during loipro01 import activity

    Hi experts, after having starting our server, the service u201Eme~earu201C terminates approx. two days later. Upon restarting service, the same happens again. This exception occurs during the loipro01 import activity. So we need your help any ideas,