⚠️ Update | Sketchucation Tools 5.0.8 released with licensing improvements and bugfixes Download

Alkategóriák

  • No decscription available

    20 Témakörök
    462 Hozzászólások
    HornOxxH
    @pilou said: More appetizing in chocolate! Eggs are good as well - but only very fragile when falling down in SketchyPhysics
  • Trace what prevents an object from being GC'd?

    22
    0 Szavazatok
    22 Hozzászólások
    2k Megtekintések
    Dan RathbunD
    @unknownuser said: (http://forums.sketchucation.com/viewtopic.php?f) of this topic":25oe0j3o] Did you dispose of all Locals, Constants, instance vars, and perhaps maybe even Procs that are within your subclass? That said... you should be able to have proc refs, if they are instance @refs because they are likely to have refs inside them that ref instance objects. If the class is a singleton (most WebDialogs are,) just limit the number of instances to 1, in the wrapping namespace, the same way you would for a tool instance.
  • Web page loaded while ruby processes?

    9
    0 Szavazatok
    9 Hozzászólások
    582 Megtekintések
    fredo6F
    @thomthom said: Fredo uses timers to slice up the work, but it makes the total processing time a lot slower. Actually the overhead is reasonably small. The goal of this mechanism is just to give back control to the UI, in case the user has clicked or typed a key. This is not to perform heavy stuff while the script is itself busy with computation. Fredo
  • Find any methods that are never called?

    3
    0 Szavazatok
    3 Hozzászólások
    265 Megtekintések
    thomthomT
    @tig said: add =begin...=end around the method and retest the script: Make sure to restart SU before retesting. Because a load will not remove the old method. Easy trap to fall into, as you won't notice something failed until you start the next time.
  • View.guess_target algorithem?

    7
    0 Szavazatok
    7 Hozzászólások
    512 Megtekintések
    Chris FullmerC
    Oh yes, that zoom tool. I forgot about that one. I never use it, I'm a scroll wheel only person. And the scroll wheel does zoom to where the mouse cursor is. The actual zoom tool though yes, that also uses the mouse pointer to some degree. If you hold it over something close, you zoom quickly. hold it over something far and you zoom slower. Even if your mouse goes from being on top of something close to not on top of something int he same dragging event, the speed of zoom will vary. I'd never noticed that before. The orbit tool (again, my scroll wheel) doesn't do what I was thinking it does. It does seem to just orbit around the center of the screen, and the distance of the z axis seems to be based on some sort of target. I'm wondering if it has to do with the near and far culling planes? Perhaps evenly spaced between them? Chris
  • [Code] Creating attr like methods

    8
    0 Szavazatok
    8 Hozzászólások
    2k Megtekintések
    thomthomT
    Doubledone!
  • Attribute accessor - get all as an array?

    13
    0 Szavazatok
    13 Hozzászólások
    6k Megtekintések
    Dan RathbunD
    @chris fullmer said: That is great to know, because that is precisely what I will be doing with these ... Spooky! .. now I'm answering your questions before you ask them. (.. does anyone hear the "Jeopardy" theme?)
  • Entities relationship - Sketchup Ruby SDK

    14
    0 Szavazatok
    14 Hozzászólások
    2k Megtekintések
    N
    Thanks for all the suggestions, pointers and tips. I am making progress exporting both raw entities and entities within components instances (including the transformation) It's not complete yet (some instance are place wrongly) but I should be able to figure the rest out (might be group handling etc) Thank you once again.
  • Importer in the same wind order

    3
    0 Szavazatok
    3 Hozzászólások
    343 Megtekintések
    G
    thanks TIG. Now i must find a method for import all faces in correct wing order: 1)i see that there is a m_pMesh->GetPolygonPointIndex(m_nCurrPoly+1, m_nCurrPoint+1, &m_idx); is sufficent have the correct indexes of the vertexes for import all in the correct windorder ? 2) or i must separate the importation of vertexes like the sketchup example SkpToXml of the sdk? The sample project do that: extract the loops hr = pFace->get_Loops(&pLoops); long nLoops; hr = pLoops->get_Count(&nLoops); //If this is a simple face (no loops) if (nLoops==1){/////////////////////////////////////////////////////////////////is a simple face //import vertex in counterclockwise order CComPtr<ISkpLoop> pLoop; hr = pFace->get_OuterLoop(&pLoop); CComPtr<ISkpVertices> pVerts; hr = pLoop->get_Vertices(&pVerts); } else ///////////////////////////////////////////////////////////////////is a complex face tessellate it with: pFace->CreateMeshWithUVHelper(3, pUVHelper, &pMesh); and imports vertex in clockwise order????? //there i must place the m_pMesh->GetPolygonPointIndex??? and import in specific order???? ecc.... is sufficent???? Thanks a lot.
  • Open Source License?

    8
    0 Szavazatok
    8 Hozzászólások
    519 Megtekintések
    Dan RathbunD
    The MIT License is consise. @unknownuser said: Copyright (c) <year> <copyright holders> Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  • Untagged deleted element after using outer_shell on group

    12
    0 Szavazatok
    12 Hozzászólások
    1k Megtekintések
    Dan RathbunD
    BTW.. there might be some API call that also has the effect of triggering garbage collection. Try view.refresh() Hmm.. it also occurs to me, that Sketchup may be wanting to keep references to deleted entities around, just in case the user decides to do an undo. But a call to all_connected() should not return these entities in the result Array. If it does, then it's the all_connected() method that is bugged. You said that you were wrapping your code in your own operation... if you didn't (ie you just let Sketchup handle the undo,) I wonder if the error would also occur? Meaning it could be an operation bug.
  • Ruby Console access from C extension

    10
    0 Szavazatok
    10 Hozzászólások
    795 Megtekintések
    T
    I have tried the last solution: rb_eval_string("$stdout.write(\"Message\n\")"); and it works well. I am using it for debugging purpose, so the speed is not important for me. Thanks!
  • Open SU vs open model - __FILE__ might vary

    10
    0 Szavazatok
    10 Hozzászólások
    635 Megtekintések
    Dan RathbunD
    TIG's suggestion DOES work !!! File.identical?("C:/Program Files/Google/Google SketchUp 8/Plugins/testfile.rb", "C:/PROGRA~1/Google/GOOGLE~3/Plugins/testfile.rb") true Then, stripping off the filename and testing dir against dir: File.identical?("C:/Program Files/Google/Google SketchUp 8/Plugins", "C:/PROGRA~1/Google/GOOGLE~3/Plugins") true But it's still stupid, that the installer writes 32 bit quoted pathname, and the app overwrites it each time it starts up with a 16bit pathname. If I start SU7, i wonder if it will overwrite the registry key. Bet it will...
  • Using Polygon Mesh

    11
    0 Szavazatok
    11 Hozzászólások
    3k Megtekintések
    Chris FullmerC
    @adamb said: @thomthom said: @adamb said: But if you like, I've got code that handles quads Quads? Whatcha mean? You give me a four-sided polygon (quadrilateral) , and I'm sure I can stretch to writing code to break it into triangles. Best response ever.
  • Writing out temp files - How to cleanly delete when done?

    23
    0 Szavazatok
    23 Hozzászólások
    5k Megtekintések
    AdamBA
    @chris fullmer said: Currently, on Vista 64 when I create the folder in sketchup ruby, if I try to delete the folder through the windows explorer it tells me the folder is currently being used in another app. And I get an error as well when I try to delete the open folder through another instance of SketchUp. I just don't know how it will react in other windows versions and on a Mac, especially since SU on OS is MDI. It might not be able to differentiate which instance of SU created the folder and which is trying to delete it. But it would be interesting to test. Chris, Not being able to delete a folder/file on Windows typically means there is a process somewhere with a 'handle' to the file/folder. Yes, it is pathetic that Windows still cannot handle stuff like this - every other OS can.. but anyway.. First double check you really are releasing the File Descriptor handle you use in Ruby. If you the file isn't really closed, you won't be able to delete it. Adam
  • Meaningless Menu Separators

    5
    0 Szavazatok
    5 Hozzászólások
    413 Megtekintések
    Dan RathbunD
    @thomthom said: You mean so that separators only adds a separator between the native tools and the plugin tools? And.. I agree with the above for Main menus (incl. "Plugins",) and the right-click Context menu.
  • Beginners Guide??

    8
    0 Szavazatok
    8 Hozzászólások
    1k Megtekintések
    Dan RathbunD
    Ruby Newbie's Guide to Getting Started
  • Sketchup 8 Patch ETA

    15
    0 Szavazatok
    15 Hozzászólások
    2k Megtekintések
    Dan RathbunD
    And now I'm REALLY hoping for M2... the toolbar entries in my Registry are up to 566 and growing !! Sketchup is very slow to startup. (sigh.. manual delete of registry keys, again.. and again.)
  • Web Dialogs -Get string from Ruby before Body loads?

    35
    0 Szavazatok
    35 Hozzászólások
    3k Megtekintések
    Chris FullmerC
    Thanks Dan. I'll look at that and point the html developer to it. In the end we've got it worked out now, but only after some serious extra effort.
  • OnTransactionStart/Commit oddities?

    29
    0 Szavazatok
    29 Hozzászólások
    3k Megtekintések
    Dan RathbunD
    Yes the more I think about it, 2 Operation callbacks with an opflag parameter makes more sense, less documentation to maintain in the API pages... easier to program. Simplest all around.
  • Extending SketchUp entities

    16
    0 Szavazatok
    16 Hozzászólások
    2k Megtekintések
    Dan RathbunD
    @thomthom said: @dan rathbun said: But what's the big deal? It's better than modifying the base API class, isn't it? If my script iterate the entities in a model and extends them with my mixin module - then I wouldn't want to affect other scripts. It'd be the same as modifying the base class. We'll yes.. if you end up defining a new singleton method for EVERY Sketchup::Entity subclass instance in the model(s), then it would be comparable to extending all the classes themselves. Also.. a singleton method, is in effect, a single instance override of any inherited method of the same name, so (referring to my previous example,) if Google later ended up adding a :has_dictionary? method to the API Sketchup::Entity superclass, my example would be overriding that method, on an individual instance basis.

Advertisement