Jump to content

JBenghiat

Member
  • Posts

    2,024
  • Joined

  • Last visited

Everything posted by JBenghiat

  1. Jeff, It's not you, elliptical beams have had issues with both bottle rotation and beam angles. I reported this as a bug a while ago. As a shameless plug, you may want to take a look at Beam Draw http://benghiatlighting.com/software/products/beam-draw-4. One tools specifically lets you visualize PAR beams. -Josh
  2. There is no reason that turning off developer mode should cause your issue, unless your case statement isn't set up right. I tried your vso, and it worked fine for me even in developer mode, except that the object would occasionally crash VW. A few suggestions: You shouldn't need vsoState clear, as you haven't set up your object to accept states. Before CreateText, check that Len( text ) > 0 I recommend against testing for HParm = NIL. There are some cases where you want the NIL case to be handled, like inserting the object. My guess is your issue lies with the PickObject call -- it's fairly old and may be causing a memory leak. Try the FindObjAtPt commands, which might be more stable. -Josh
  3. You can use the instrument summary, with the only item being a label legend specified as your "typical" symbol. This also scales the symbol, allowing you to place it directly on a sheet layer. Personally, I have a typical symbol that I converted to group and scaled to work on a sheet layer. I made this into a new symbol, which gets inserted with my "blue" title block symbol, along with notes, revisions, etc. -Josh
  4. Your script works for me. The only think I can think of is that the main name of your parameter should be "area" and not your alternate name. I would also recommend placing your set field section in the button 1 case. Delete the ResetObject call in your main code. If uncommented, this could cause an endless loop.
  5. Sounds like you are on the right track. SetRField should only be in the button event. What does your SetRField look like? Does your call work from the main reset part of the script if you use a test string? A button event won't reset the object to display the new data. Add a ResetObject() call to cause the PIO to regenerate. -Josh
  6. The function reference in the developer wiki is more comprehensive than that in the help. You can both search the page for a function name, and there is a site search function. http://developer.vectorworks.net/index.php/VS:Function_Reference The new image controls have actually been around for a while -- since VW 2012. What has changed is the resource file format, as well as the SetVSResourceFile command. Setting the image isn't deprecated per se, but the command that loads a resource file into memory is. The one thing that has changed completely is string functions. Because of the resource file update, this switch happened fairly abruptly. Usually, deprecated functions will simply generate warnings for a few versions before they disappear completely. HTH, Josh
  7. The command you want is UpdateImageControl2. http://developer.vectorworks.net/index.php/VS:UpdateImageControl2 As the command takes a path to the image in your resource package, you don't specify a resource file elsewhere.
  8. Resource files were totally re-worked for 2015. See Kevin's link to the developer wiki above. The page explains the correct format for resource files. If you scroll down to the bottom of the page, you can find information on the new vs routines. Once you get the hang of it, managing resources actually becomes much easier. -Josh
  9. To reiterate Jim's comments, what you describe is expected behavior. Viewports maintain layer and class visibilities independently from document settings. Sheet layer objects respond to document visibility settings, just like design layer objects. Either edit your saved views to show or ignore the "Title Block" class or assign your key to another class that is always visible. -Josh
  10. Are you providing feedback to a user or for trouble shooting? You can build a custom dialogue with a scrolling text box for UI. For testing, write to a log file. -Josh
  11. You don't really fillet an object, you fillet between two line segments. To fillet a NURBS curve, you have to specify a non-endpoint vertex (as a way to ensure the selection of two segments) and assume that those two segments are straight. What are you ultimately trying to model? Does the radius need to be precise, or are you just trying to round off transitions? -Josh
  12. Short answer -- yes, you can provide a directive to VW's encryption process to include modules. Just as with encrypting VS, the module gets sucked into to the distributed plug-in. They key is including an xml file with the same name and in the same location as the plug-in you wish to package. {full path to plug-in to encrypt} {relative path to module file 1} {relative path to module file 2} Notes: - The xml flags are case sensitive - Use the Path parameter if you are packaging a file the resides outside of your plug-ins folder (I keep all my code files in Dropbox and manage with git Example: I have a project in: Users/myname/Projects/Project 1 In the Project 1 folder I have: |_ _Encrypt |_ thePlugin.vso |_ thePlugin.xml |_ lib |_ __.init__.py |_ piolib.py |_ thePlugin |_ __.init__.py |_ _main.py The xml looks like: /Users/myname/Projects/Project 1/_Encrypt/ thePlugin/_main.py lib/piolib.py It's been a while since I got this working smoothly, so feel free to contact me privately with questions. -Josh
  13. Your easiest approach would be to start with a 2D poly and convert to NURBS. With Add2DVertex, you add the vertex coordinates as though the fillet is not there and specify a radius. -Josh
  14. The summary will build a key for any symbol with a Light Info record attached. You can attach the record and manage its data via the Lighting Symbol Maintenance command. In order for the summary to display counts, however, the symbol must be placed in the drawing as a Lighting Device. -Josh
  15. Hybrid PIO's can't insert on an alternate plane (when you extrude, it becomes hybrid). You may be able to get the plane of the path and manually adjust your 3D geometry accordingly. If you are creating a true top/plan view (as opposed to a schematic for the 2D view), you also have to adjust the plan view to match the rotated plane. -Josh
  16. Hi Jeremy, Create a symbol with all three components, and assign the light info record (if you don't have one already). You can also use lighting symbol maintenance to add the symbol to the list. Make sure the type and wattage match for all the parts as well as the composite symbol. In the summary list, add the composite symbol (it will be flagged as unused). FYI, the composite symbol can be anything, like a shortened strip with a break line, as long as type and wattage fields match in symbol maintenance. -Josh
  17. The issue you observe is a result of a user-defined origin. Certain plug-in fields adjust their displayed values based in the origin offset. It's a bit of a long-standing bug. Using the control point to adjust the footprint should function as expected. -Josh
  18. IES files are an open standard and the data is a simple text file. Vectorworks use of the IES file is part of the rendering algorithm, so there is not really a way to access RW's calculations from an API. You can read data from the IES file and perform calculations. Perhaps searching for a Python IES library would be the first step. -Josh
  19. Are you trying to create a light for rendering or visualize beam coverage with "Show Beam." If the latter, the "Vertical beam" option seems to have a bug. You can, however, get a good idea of coverage with the solid beam option in non-vertical mode. -Josh
  20. I reported the bug with 2014. It looks like it will take some time to fix. -Josh
  21. The issue is with 2D only symbols -- for some reason they can disappear from viewports. Add a 3D locus to your symbols (easy to do in the body symbols) and you should see them again. -Josh
  22. I'm a big proponent of using viewports for rendering for the following reasons: - You can save views and scale them to a printed page. Either create the view and "save" it to a VP via the Create VP command, or my preferred method: create a RW camera and convert the camera to a VP. - Each VP can have its own lighting options via Object Info or individual light settings via the Visualization Palette. - You can update several Viewports at once and, depending on how taxing the render, continue to work while the VP updates. - The VP takes its resolution from the Sheet Layer settings on which it resides. This means you can be very specific about resolution and print size. You can also do a test render at low resolution (even lower than screen, say 45 dpi), then up the resolution to print quality before updating the renders. - If you make changes to the design, your renders are already set up. I export the sheet layer to PDF to share, even if I'm opening in an image editor to further manipulate. Keep in mind that the PDF also has a resolution which can down-sample but not up-sample your final output. HTH, Josh
  23. Just in case, are you aware of the developer wiki? http://developer.vectorworks.net/index.php/VS:GetPluginString -Josh
  24. Unless you've pasted incorrectly, you are missing the semicolon after the last line of your script. -Josh
×
×
  • Create New...