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

    Posts

    Recent Best Controversial
    • RE: Materials from face to components

      @tig said:

      This alternative one-liner will process all selected component-instances, making those instances take the material of the first face found within the component's definition.

      ms=[];mod=Sketchup.active_model;mod.selection.grep(Sketchup;;ComponentInstance).each{|i|d=i.definition;d.entities.grep(Sketchup;;Face).each{|f|ms<<f.material};m=ms.compact[0];i.material=m};
      

      To make a menu item of such simple commands you can try the following.
      It's not difficult - just take care...

      Use a plain-text editor, like Notepad++ [or TextWrangler on a MAC], and add a new file into your Plugins folder*** named say 'MyOneLiners.rb' - ensure that its encoding is set to UTF-8.
      Add this line to the very start of the file to be on the safe side:
      # encoding: UTF-8

      Then add the following line for each 'one-liner'...

      UI.menu("Plugins").add_item("TITLE"){CODE}

      Substituting your desired 'name' for your command in place of TITLE [keeping the paired ""], and also copy and paste the full code into where it says CODE [leaving the pair of enclosing {} ]

      Do a new line for each command you want.

      Save the RB file, and restart SketchUp to see your new command[s] listed under the SketchUp Extensions menu [previously called Plugins]...

      ***To open your Plugins folder [which is hidden by default] just copy+paste+enter this one-liner into the Ruby Console:

      UI.openURL("file;///#{Sketchup.find_support_file('Plugins')}")
      

      You could even add that command to your menu items, as say "OpenMyPluginsFolder" !

      Work fine thanks for the help !!

      posted in Newbie Forum
      D
      dannyver
    • RE: Materials from face to components

      @tig said:

      How do we determine the color you want for the component-instance ?
      There seem to be several different materials on various faces [or even sub-components] inside it ?

      If you select the component-instance and give it the default material in Entity Info then how does it export ?

      IFC always applies the 'container's' material to nested faces - the faces' materials are ignored.

      Try this one-liner, copy and paste it into the Ruby Console + enter.
      It examines the model's definitions and finds the first face inside each component-definition that has a material, it then applies that material [if any] onto every placed instance of that component.

      Sketchup.active_model.definitions.each{|d|next if d.group?||d.image?;ms=[];d.entities.grep(Sketchup;;Face).each{|f|ms<<f.material};m=ms.compact[0];d.instances.each{|i|i.material=m}}
      

      All sub-components only have 1 surface material.

      If I give the component standard material then it is all exported as light gray.

      This is exactly what I was looking for and works great. This saves me so much time thanks a lot !!

      Is it also possible to process this in a plugin?
      And can it then be that it only processes selected components when something is selected?

      posted in Newbie Forum
      D
      dannyver
    • RE: Materials from face to components

      @tig said:

      Unfortunately that explanation makes it even less clear.
      Where is the 'face' ?
      Where is the component-instance ?
      Where does the layer's color come into this ?

      Please explain how you do it manually, step-by-step - in very simple terms...
      I appreciate that it's likely that English is not your first language, so keep it very simple, to avoid things getting lost in translation...

      step 1 dwg import via xref
      step 2 copy xref component on a map
      step 3 open the xref component, the components contained therein provided with the same material as there is on the surface of the component
      stap 4 when I export the drawing to .ifc all components have the material / color of the component (green). this should be the material / color of face.

      So it would be handy if there were a plugin that would copy the material / color of the face to the component that contains the face.


      example

      posted in Newbie Forum
      D
      dannyver
    • RE: Materials from face to components

      @tig said:

      Please expand on this.
      There's probably insufficient detail to give a useful reply.
      However, here's my attempt at recasting what I think you mean...

      • You want a Plugin which will find a particular face's material and apply that material onto a particular component-instance.

      • How is the chosen face to be determined ?

      • How is the affected component-instance to be determined ?

      • Is there more than one instance of this component ?

      • Is the face actually nested inside the component that is to receive the material ?

      • Is that nested face to have its material removed after it's applied to the 'container' ?

      • Is this to only affect component-instances, or are groups also to be considered ?

      But... why can't you use the eyedropper-tool from the 'Materials Browser' dialog, and pick to select the desired face's material, then use the paint-bucket to paint the 'container', just as if you had selected the material off the browser itself ? Editing the container, and then exiting the edit, as necessary to access the face and container as needed.
      Note: to wipe a face's material, just select it with a single-click and use 'Entity Info' to reassign its front-material from the top icon-click and the 'default material which is always first in the swatches in the 'Choose Paint' dialog...

      I will explain why I could use this well. I now use an xref plugin to load an autocad drawing into sketchup. Then I place this loaded 98x component on a site plan of a building. then I export an .ifc of this.

      the problem is that now the colors are not exported because the colors of the composet are being exported but these are with a loaded .dwg the layer of colors from autocad.

      I could adjust this manually, but the autocad model is still often adjusted.

      posted in Newbie Forum
      D
      dannyver
    • Materials from face to components

      I am looking for a plugin with which I can transfer the material from the face to the first component. Does anyone have an idea or something for this?

      posted in Newbie Forum sketchup
      D
      dannyver
    • RE: [Plugin] View Parts (1.2) β€” Sept 13 2011

      it is not that it is not working, but it dos not work in site a components/group.

      it while make this plugin much more useful when it while work in site a component. maybe there is someone that can make it work

      posted in Plugins
      D
      dannyver
    • RE: [Plugin] View Parts (1.2) β€” Sept 13 2011

      @driven said:

      hi dannyver,

      I don't use SU 6 and I'm on a mac so it's hard to know what issues your having.

      maybe you could re-cast your question to target your setup better.

      e.g. "I've tried this plugin using SU6 on this skp and it doesn't seem to function, can someone check if it's my skp?

      or "can someone post a skp that works with this plugin in SU6 so I can check my setup..."

      With the first example you'll likely find out if your skp works or with the second you'll eliminate a wrongly setup skp...

      sorry I can't be of more help. Personally I know it 'basically' works on mac using SU8, but I only tested the functionality for future use.

      other than that I suggest checking you've got the latest version, and re-read any instructions or posts.
      also, if you no longer use SU6 update your User Settings.
      john

      i update my user settings right away πŸ˜‰

      posted in Plugins
      D
      dannyver
    • RE: [Plugin] View Parts (1.2) β€” Sept 13 2011

      @dannyver said:

      @jean-franco said:

      Hi,

      @driven said:

      I tried both standard and a version using TIG's mods, and although both create scenes, everything is hidden.

      I've the same situation under Windows XP 3.
      If I select components within a group and launch Viewparts, it creates all the needed scenes but all is hidden. And no way to unhide anything.

      Have a look at the attached file.

      Driven, If you don't mind, I'd like to have your updated script with TIG's modifications to do a test.
      I'm sorry but I'm really not a Ruby scripter.
      Thanks.

      [attachment=0:3wnzrn5t]<!-- ia0 -->cerificateur-scenes.skp<!-- ia0 -->[/attachment:3wnzrn5t]

      i have the same problem is ther any one ho has a answer or solution for this problem already ❓ ❓

      is there no one ho has a solution for this problem 😒 . this can make this plugin very useful πŸ˜„

      posted in Plugins
      D
      dannyver
    • RE: [Plugin] View Parts (1.2) β€” Sept 13 2011

      @jean-franco said:

      Hi,

      @driven said:

      I tried both standard and a version using TIG's mods, and although both create scenes, everything is hidden.

      I've the same situation under Windows XP 3.
      If I select components within a group and launch Viewparts, it creates all the needed scenes but all is hidden. And no way to unhide anything.

      Have a look at the attached file.

      Driven, If you don't mind, I'd like to have your updated script with TIG's modifications to do a test.
      I'm sorry but I'm really not a Ruby scripter.
      Thanks.

      [attachment=0:1k9cpp7m]<!-- ia0 -->cerificateur-scenes.skp<!-- ia0 -->[/attachment:1k9cpp7m]

      i have the same problem is ther any one ho has a answer or solution for this problem already ❓ ❓

      posted in Plugins
      D
      dannyver
    • RE: Layers

      i tough when ther wil be a plugin that can make it work that you can open a component whit the view mode hide rest of the model switch on
      and then you can make a scene of it and it whil save this the selection this would make it very easy to make scene's from different components! 😎

      posted in Newbie Forum
      D
      dannyver
    • RE: Layers

      @dave r said:

      Layers only control visibility of components. Scenes are like snapshots. If you want different views of the same component, just move the camera to show the component as needed and make new scenes. You don't need any layers to do that. Use layers to turn off visibility for the components you don't want to see.

      As far as going to LayOut, you aren't "transporting" components there. You are only inserting views which you establish with scenes in SketchUp.

      thanks for your answer but then i stil need to make differt layers and turn them off to make a scene from a component that is inside or between oder components. or am i wrong

      posted in Newbie Forum
      D
      dannyver
    • RE: Layers

      @dave r said:

      There isn't any reason to put a group on different layers for different scenes.

      How can i capture one group/component in one scene whit out puthing it on diffent layers then.
      i like to transport each group/component to lay out and them gif measurements to it whitout taken my hole model apart ❓

      posted in Newbie Forum
      D
      dannyver
    • Layers

      very nice πŸ˜„ πŸ˜„ πŸ˜„

      i am wondering if ther is a plugin that can capture the view style hide rest of model in a scene.
      this would make it a lot easier to make different scene's from one group whit out putting it on differt layers

      posted in Newbie Forum sketchup
      D
      dannyver
    • RE: Plugin material

      @tig said:

      If faces or nested groups/components within a group or component have the 'default' material then using the paint-bucket on the group or a component-instance will display that material for every piece of 'default-material' within the group.
      If you want to change the material of an object within a group/component that already has a material to it then you must edit the group/component and 'repaint' the object with the new material.
      Think of it this way...
      You have a car component.
      It has a body in the default-material but windows in a glass material, trim in dark-colored material, seats in gray-leather material, headlights in a silver material and other lights in red or orange materials etc.
      Within the car-component there are sub-components - tires and mirrors.
      The tire has no default materials - just silver hub material and dark-rubber material.
      The mirror gas a 'mirror' material for its glass and the rest is default-material so that it matches the car body.
      Now, when place two instances of the car-component - paint one 'blue' and the other 'green'.
      Both instances refer to the same definition BUT look different as their bodies and mirrors are displayed colored with the instance's material [they are actually still 'default-material'].
      You decide that the car should have a black-leather roof in all versions.
      Edit an instance and paint the roof 'black'.
      All instances now show a black roof but the rest of the body is colored as before.
      Remember that you can set your paint-bucket to the default material and repaint an instance with that so you aren't confused by the default material looking 'colored' during an edit...

      thanks that is very clear 😎

      posted in Plugins
      D
      dannyver
    • RE: Plugin material

      @tig said:

      Select them and use the paint bucket tool ???
      What is it you want to do exactly ?

      and when i want to paint nested groups/components all at ones πŸ˜•

      and when i get som new component out of the programs i saved i neet to open te component and select al the fases, i cand just click at the outside of the component is thit normal ❓

      posted in Plugins
      D
      dannyver
    • Plugin material

      is ther a plugin that can gif all the selected groups and components a new material ❓

      posted in Plugins
      D
      dannyver
    • RE: [Preview] Skabinet (make cabinets with Sketchup)

      when is it coming out looking forword to it 😍

      posted in Plugins
      D
      dannyver
    • RE: Plugin to make board and group

      @dedmin said:

      There is already plugin like this - http://forums.sketchucation.com/viewtopic.php?f=323&t=23411&p=199076&hilit=woodwork#p199076

      tanks but what i would like is a plugin whit a icon in the toolbar that i can draw a face whit than give it a hight and than it turns in a group by it self πŸ˜„

      posted in Plugins
      D
      dannyver
    • RE: Plugin to make board and group

      @ktkoh said:

      There is board plugin and I wrote a plugin that makes it a component. Search for board plugin

      K2

      i cant find it do you no wher i can?

      posted in Plugins
      D
      dannyver
    • RE: Plugin push/pull

      @unknownuser said:

      A4chitect has this http://forums.sketchucation.com/viewtopic.php?t=17040

      I haven't tried it though as I don't see the need. Let us know if it's any good?

      this scales the group no puss/pull or are i doing somthing wrong ❓

      posted in Plugins
      D
      dannyver
    • 1
    • 2
    • 1 / 2