Recently I have been modelling some reinforcement in Revit. One annoyance I came across was when 2 bars are close to each other Revit moves one of them to eliminate the clash. Very annoying. I would prefer to be able to place all the reinforcement and then go through the whole model and decide which bars I want to move to eliminate clashes.
After a bit of trial an error I found that if you put the reinforcement into groups you can put the bars wherever you want and revit doesn't try to automatically move them. So I have been grouping bars based upon their shape:
This has the added benefit of being able to tweak a sets location by selecting the group and moving it.
Monday, July 29, 2013
Monday, July 22, 2013
Ribbon Icons
Without pointing fingers, there are some pretty ugly icons out there! I wonder if the people who made these icons realise that in the SDK, Autodesk supply a PDF titled Autodesk Icon Guidelines.
The guidelines go into quite a bit of detail describing things like colours, lighting and shadows. I can imagine if you were a professional icon artist the document would be very useful. I'm obliviously not a professional graphic artist nor do I have the tools of one, but to create good looking icons is easy!
To create my icons I normally take a screen shot of an existing Revit icon then modify it by adding badges or ascents as appropriate. This can all be done using built-in windows tools like snip and paint.
The end result is icons that have the same look and feel as the Autodesk ones, but more importantly convey to the user the intention of the tool. I like to think without reading the name of the tool, users have an idea of what the tool does.
You can get your hands on the Guidelines via the SDK download here:
Monday, July 15, 2013
Getting Elements
Quite often when writing code for Revit I need to get all the elements of a particular category. To help me do this I wrote the follow helper method:
So when I need to get elements I call that method. For example to get all the floor elements I use:
So when I need to get elements I call that method. For example to get all the floor elements I use:
Monday, July 8, 2013
Unit Vector
A unit vector is a vector whose length is 1. To convert a vector to a unit vector you simply divide each component of the vector by the vectors length.
For example to find the unit vector of the vector (1, 5, 7):
Thankfully using the Revit API the calculation is very trivial:
For example to find the unit vector of the vector (1, 5, 7):
Thankfully using the Revit API the calculation is very trivial:
Subscribe to:
Posts (Atom)