sketchucation logo sketchucation
    • Login
    1. Home
    2. jolran
    3. Posts
    ℹ️ Licensed Extensions | FredoBatch, ElevationProfile, FredoSketch, LayOps, MatSim and Pic2Shape will require license from Sept 1st More Info
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 37
    • Posts 1,027
    • Groups 2

    Posts

    Recent Best Controversial
    • RE: Explode 1 level component

      So I was wrong in everything I said πŸ˜„

      Yes it was part of some longer piece, I copy and pasted it wrong, sorry.

      posted in Developers' Forum
      jolranJ
      jolran
    • RE: DC instance make unique

      Hi TIG.

      @unknownuser said:

      I'm still not entirely sure why it has to be a DC - why not just a component ?

      Since you know what I'm working on a.t.m. Are you refering to why I'm using DC's or why DC are the cause of this problem?

      But yes it is the components inside that's the problem. Actually, I really do not need the additional instance. I'm just after the face and edge collection from the components inside the DC.

      Iterating through nested component entities I get perculiar results.

      If putting the DC inside a group and explode the group, it crashes sometimes. Although if I iterate the group.entities and explode, it doesent crash. BUT only 1 component inside get's exploded that way 😲 . Using group.ents.to_a or not doesent matter. Neither "next if not e.valid?" or something like that.

      If you have a better way to get to the face or edge entities inside the nested components without exploding them, I would be most greatful to hear about it πŸ˜„

      Then I wouldent have to do this method and the original DC could be left in peace.

      posted in Developers' Forum
      jolranJ
      jolran
    • DC instance make unique

      Hi. I have this snippet, trying to make a nested DC unique so I can manipulate it without worries.
      And it's a copy of a DC in current model selection.

      #comps = active selected component in Sketchup
      
      	comps_def=comps.definition
           comp_tr=comps.transformation 
           ### Make an instance of comps with comps transformation ###
      	  comps_instance=ents.add_instance(comps_def, comp_tr)
             comps_instance.make_unique   
              comp_ent=comps_instance.explode   # this crashes sketchup!
      

      The instance doesent get unique? Is there any problem of using original components transformation?
      I used it to position the 2nd instance to match the original. πŸ˜•

      posted in Developers' Forum
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      OK a little more rabbeling. Maybe it can help someone in similar situation.
      Although I must warn! It's not about booze and women πŸ˜„

      Have experienced plenty of crashes. Did put the DC in a new group and exploded the entities therein.
      It's difficult to get to entities and iterate a collection in nested components, if the components are not exploded?

      Probably the user want's to keep the DC for further editing anyway? So to explode the DC would not be very polite.

      So new aproach is to make an instance of the DC. Explode the shit out of it, and extract edges and faces and materials if possible and get rid of it. THEN recreate the dc from that information on to the faceclone or vice versa. Probably have enough information to know what to erase, and then do erasing.
      That IS probably the way to play safe.

      I get the feeling it's risky doing things with entities of current Sketchup selection? Grouping, exploding etc.
      If you clone them, or copy. You can do what the heck you want with the copies?
      That IS probably the way to play safe. And I sence that is what TIG is doing in his scripts.

      I noticed that faces and edges created in code doesent behave like they do in normal Sketchup modeling. In code if you split a face with an edge you don't get 2 faces! The edge lie on top of the face. Therefore one must use intersect with.
      Although I have also noticed some inconsistency in this!
      But if it's true, orders of drawing things won't matter that much, wich is a good thing.

      posted in Plugins
      jolranJ
      jolran
    • RE: Make Grid Plugin

      Somewhat biased reply, but you could try crosshatching. http://forums.sketchucation.com/viewtopic.php?f=323&t=38637

      if it's edges you want. Only work on planar faces.

      posted in Plugins
      jolranJ
      jolran
    • RE: Explode 1 level component

      oh sorry typo. You need to incoperate it with the rest of your script and put "end".
      Never mind.. I probably to green to give any advice.
      Will have a look at that bomb, thanks!

      posted in Developers' Forum
      jolranJ
      jolran
    • RE: Explode 1 level component

      @unknownuser said:

      it took you a few seconds, while i had been looking for a solution the whole day...

      πŸ˜„ I know the feeling

      Does this give the same result for you? I've heard iterators are a good bet.
      I'm just a hack, just something I picked up..
      Acctually looking for the contrary of what you are, exploding everything that's nested.
      So I will try the opposite of what TIG recommended for you. Good thread!

      ents.to_a.each{|e|
      	      next if not e.valid?
      	       e.explode if e.class==Sketchup;;ComponentInstance
      	   }
        end
      
      
      
      posted in Developers' Forum
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      OR do a face_clone of the DC with material and all. Then erase everything outside the original selected face!!!

      Wonder if that's possible.. Would be the safest method, I believe..

      There is a problem exploding nested components. And it's needed to get whole model edge, face, vertice collection?

      Edited: No, no, no... Not face_clone. Will have the material problem then again if moving over stuff to a new entitiy..

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      There are some major problems. 😞

      Have looked at 2d tools for ideas, but need serious time to study that script.
      So been trying other things..

      Getting result nr 3 on the picture is no problem, with or without faces. (Transfering the material is not done yet)

      Problem is deleting the correct edges. If "face_frame" is not wanted(In this case "face_clone" outer and inner loops)
      It sounds easy πŸ˜„ But when intersecting, the added result is nr 4 if one delete the face loops. Deleting with reference to vertices won't work? Since they are sometimes connected to same edges one wish to keep.

      My theoretical fix:
      Keep all the result from nr3 including faces. And do material transfer.

      Although! Looking at picture nr 2 one clearly see the problem when adding 2 faces connected on top of each other.
      There is a normal conflict(?) So it's either delete original face OR turn the result into an component with cutting behavior.
      (I think I know how to do that in the definition list)

      I'm working on the later solution, so one can have a better workflow, should one wish to delete the hatches..

      Now problem is, in wich direction I should troubleseek a solution for material transfer?

      1. Let say i have a DC or standard component with material/color attributes(forget about textures atm). Can they be transfered to the result component, after intersection? Remember, geometry has changed..
      2. Iterate trough faces and get material infos from DC.entities. Use method face.position_material.
      3. Use UV helper?

      Not much info about the UV helper in the API?...


      stamptool_trouble.jpg

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] bim-tools 0.13.4(june 22, 2015)

      Looks exiting!

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      Wow, EarthMover this is exactly the kind of feedback needed, and you have some very great ideas. Thanks! πŸ‘

      I will put effort in trying to make them happend. Hopefully with some push in the right direction from TIG if I would get stuck. Which I will πŸ˜„

      Thanks for posting!

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      Haven't dared to look at that script, cause it's darned complexed!
      But I will see if I can understand what is going on in that script. Thank's for the idea. I think it sounds pretty smart, could be the solution I looking for.

      BTW. This material-transfer side of things is seriously complex, no? I managed to get a array list of materials itterating through a components.entities. But then have to transfer that on to the intersected face(gents). Face erasing should only occour on faces without materials.. πŸ‘Š

      I will look on your 2d tools TIG cause this is confusing.. Maybe it's all the cider I drank as well πŸ˜„

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      @unknownuser said:

      I was going to give you a nudge in the right direction BUT luckily I waited... and you solved it yourself, grasshopper!

      He he. Don't worry TIG(Yoda) I will come back for help soon. Working on the material-transfer side of things. Not easy..

      @unknownuser said:

      Are you OK on compiling a list of possible patterns from a folder-listing ?

      Do you mean in component sampler, or in the script?

      In this example I'm just using a DC from component's library and placing it manually.

      I made this insulation DC pretty quickly for testing, so many things can have gone wrong. Please have a look at it! Scale with handles..

      I know it would be kewl 😎 to have it function more automatic and load from file, but as you know it involves a lot of more work with webdialogs etc.. I hope I did not give the impression I had gotten that far in development.

      Have poor experience from DC's. Only had Su pro for a week. Need to read up on them.
      You have some good tips about DC's there though TIG:thumb: Will sure follow them.

      Thank's Tig!


      insulator1_1.skp

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      Little progress. So now got intersecting with component working.(Not added to the whole script yet)

      The tool is not much difference from Sketchup's native intersection, exept:
      It adds the geometry inside a group to a specific layer. And removes the faces(that could be featured as a choice?)
      But I think those 2 small things speed up workflow quite a lot.

      Would be good if materials could get transfered as well. It doesent do that in Sketchup intersection, from what I can see?
      See what can be done with that..


      stamptool_test.jpg

      posted in Plugins
      jolranJ
      jolran
    • RE: Floor generator

      Nice plug.
      An advanced dynamic component could get you far on this subject. Random textures, perhaps not.
      But I reckon you have Sketchup free?

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      That's all I needed to know. That there are lurkers out there β˜€
      It's no fun to put effort into something that people find quite useless.
      Although this has been a team effort so far (with a lot of TIG).

      @unknownuser said:

      I would love to remove other cads from my workflow and do everything in SU

      That's the direction! Question is, what is needed to do that..

      Thank's for posting.

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      Hm. Not much response. Maybe there is not much demand for other types of hatchpatterns other than lines? πŸ˜•

      Anyway got another thingy to test. Sort of a stamp tool (if it doesent already exist)
      You manually place and edit the 2d component. Select face and component, click an icon and the grouping and intersection is made. With alternatives for keeping materials, and deleting faces etc..

      Could actually be a good workflow like that, cause if using DC one could see the patterns update with each change that
      is made. And then run the intersection-grouping when it looks good.
      This way the user could use his own library of patterns, on top of those that will get provided...

      Just an idea......

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      A little report...

      Been fooling around a little with DCs. It's all new to me. Took a while to get the attributes from Dc to work in ruby, as well...

      On the picture "insulation-pattern". Insulation "triangles" are sizable in width and height. Get funny unit conversions though when trying to match facesize or other similar tasks. (I work in cm) Either DC's are buggy or the way I construct the DC is wrong. I guess the later theory.
      In this example no transformation or rotation is involved, neither intersection. Only alignment to the edge on X-axis. And alignment WOULD be quite a task to fix. Unless one can snap to face? (could not get that to work) Each DC gets added in the components sampler when running the script. I guess there is a way to delete the instance, and question is if the DC would get added if one would do an intersection and delete the dc before the operation is done?

      So using DC's for this purpose is not as straight forward as I thought. I might explore the possibilities of making patterns
      through code instead. Not sure yet. Could fastly become quite complex code with arcs and stuff...
      At least rotation would be easier if drawing on the created face-clone.
      Will take a peak and then maybe come back and do the bugfixes TIG spotted, and Kyyu's recommendations. Indenting maybe πŸ˜‰ πŸ˜„


      1st insulation test.jpg

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Ruby Console Pro #2

      @unknownuser said:

      A console and an editor are two different things.

      Ok, I see.. I do use notepad ++ as well. To be more precise then, my wish was for folding methods in console.
      But I get your point.

      posted in Plugins
      jolranJ
      jolran
    • RE: [Plugin] Hatchfaces (v1.8 beta) UPDATED 15-Dec-2012

      Ok, ok. No worries... English is not my native language so I might have missunderstood some things.
      And I'm a little tempera(mental) πŸ˜„

      @unknownuser said:

      So you mean I should stop developing it until I have matured?

      Total missunderstanding, sorry.

      @unknownuser said:

      I debated if I should say anything at all

      I do apreciate you advice though!! Really. Don't hold back!
      I might have to argument against some of the advice, if there are things behind the scenes that you are not aware about that could change the scenario. That doesent mean your outcome is not apreciated. I WILL use your codeexample further on.

      All the best.

      posted in Plugins
      jolranJ
      jolran
    • 1
    • 2
    • 42
    • 43
    • 44
    • 45
    • 46
    • 51
    • 52
    • 44 / 52