Gracias Gracias:  0
Resultados 1 al 1 de 1

Tema: From 2D CaD to 3D Blender

  1. #1
    Administrador y fundador. Avatar de 3dpoder
    Fecha de ingreso
    Apr 2002

    From 2D CAD to 3D Blender

    From 2D CAD to Blender
    by Yellow


    Architectural CAD files are often criticized for being rather large, messy and containing a lot of duplicate or unnecessary information. Unless you have the privilege of working for a more enlightened practice, with a well-enforced CAD policy, it will most likely be necessary to do an amount of cleanup and preparation, in your chosen CAD application, before attempting to import the files into Blender.

    The way you prepare the files may well depend on the approach you intend taquíng to modeling your building. The choice of how you model your building will probably be dependent on the building’s form and construction. As you go through the cleanup process, you'll get a feel for the way the building is put together and a feel for the best way to model it. This can be important if you're working with someone else’s design in order to interpret their design correctly. It alos helps to get some sort of modeling game plan together, before you go any further.

    Whichever way you approach modeling your building, the preparation of CAD files may well include:

    Removing any drawn información which is unnecessary such as text, landscaping, people silhouettes, trees, bushes, hatching and dimensions (specially drawn content, which are made up of hundreds of tiny bitty lines). All the drawn entities in your CAD files, which are imported into Blender, will become editable meshes, made up of edges and vértices. There's no point importing masses of content you don't need, it will only get in the way and slow you down.

    Do a global flattening of z-coordinates, it isn't unknown to have 2D drawings containing stray content with a z-value, the 3rd dimension.

    Scale your prepared drawings to 1 CAD Unit = 1 meter (scaling down by .001, converts millimeters to meters). One of Blender's peculiarities is the restriction it places on your work space. If, for example, you import a large building or site where one CAD Unit equals one mm, Blender will have big difficulties displaying all of it. In fact, you probably won't be able to see much of it at all. Clipping will be evident; panning and zooming will be near impossible. You could try selecting all and scaling down in Blender, if you forget to do it in CAD.

    If you’re not the creator of the CAD files, you could find that they can be rather inaccurately setup and badly layered. In this case, it can be simpler to draw over the major áreas of the drawing you wish to import with your own geometry, divide it up to suit the way you intend modeling, and save it into your own clean CAD file, ready for import into Blender. You could use an unedited import in another .blend file to pik out the finer details later, and Append it into your main model's .blend file, after you've got the basic structure sorted.

    The more accurate the CAD drawings, the easier the modeling process will be. Accurate not only in lines meeting each other, but alos the definition of áreas and perimeters for the different construction materials. Clearly define the boundaries to ensure a smooth process of creating quad faces rather than excessive triangles. In order to use the “mesh2curve” script described later, you'll need to ensure that all boundary lines meet each other (i.e., endpoint to endpoint). The script will fail if there is a breaque in a boundary line.

    Blender’s tools for manipulating the edges and verts of your imports are sparse. There is only rudimentary snapping, a proper dynamic snapping feature is sorely missing from Blender, not only for accuracy but for speed as well. So it pays to get the drawings right in CAD with all the tools available to you, then try to work with or correct inaccuracies in Blender later. For small buildings it's common to have plans, sections and elevations in one drawing. If so, set them out in a logical considered way, such as elevations aligned with each other or aligned to the floor plans. After you've removed the unnecessary entities, explode the drawing a few times, to remove any remaining blocks, Blender won't import them unless they are individual lines.

    For bigger projects, it may well pay to split your drawings down in a way that suits your modeling gameplan. This may mean creating a series of drawings for floor plans, elevations, and sections. If you intend using the elevations to build your model then it may help to split the elevations down further, with each drawing containing one of the elevational elements. For example, all the masonry walls in one drawing, the Windows in another, then create the DXF files for each.

    Once you feel you have your CAD files as you want them, save/export as DXF Release 12. At this point Blender's DXF import hak is almost certainly going to fail to import the DXF's correctly.

    There are various successful methods to get CAD files into Blender, but all depend on external help and that help is at a cost. You can purchase a shareware file converter application such as 'Accutrans'. Or, there are free CAD applications such as 'ProgeCAD' (export as SVG, but it only runs on MS Windows). There's alos Google SketchUP (export as KMZ) but, SketchUp isn't free. You could try the Free Google SketchUP (export as KMZ) but, it's only free for personal use, not commercial.

    So, along with decent snapping and measurement tools, a good implementation of a DXF import would benefit Blender's take up for architectural visualization. It is worth the effort implementing, because most CAD applications, in architectural disciplines, use DXF as the common denominator for interoperability between different CAD applications.

    The solution I've found to be 100% successful and quick, is to use 'Accutrans', a shareware file converter that can convert many file types, but it's DXF export creates a file that Blender imports without issue, every time. And, the DXF's can be as complicated/detailed as you like. Yes, it's not free or GPL but, it's cheap and does the job perfectly. It even runs on Linux with a little bit of help from Wine.

    It is alos possible, I believe, to import DXF into Free SketchUP, save as KMZ and import into Blender via JMS's KMZ/KML Import Script. But, don't use the script that comes with Blender, download the updated versión from jms's site, versión 0.1.9c or above. Version 0.1.9c was the first versión to acknowledge that longitude and latitude settings in the KMZ file affected the import scale into Blender so, although the z scale would be correct, x and y scaling could be distorted. If your importing a KMZ that just contains 2D information then, you will need to choose to 'force edges' in the scripts import process.

    Using CAD files to create the basis of your model can mean that it is more a process of doing vertex-modeling (i.e. vertex to vertex, creating edges and faces) than subdivisión-modeling. Blender’s toolset seems aimed squarely at subdivisión-modeling at the expensé of even simple CAD type tools such as 'proper' snapping, simple measurement, etc. This isn't a suggestion that Blender should be able to do CAD, it's suggesting that certain CAD features are just as valid in a 3D modeler as they are in a CAD application.

    Once the DXF file is imported, the first thing to do is save it as a .blend file, remove doubles and save again. You’re now ready to start modeling.

    There are a few implications to importing DXF's to be aware of:

    Blender is ok with the first DXF import, however if you then join any of the resultant meshes together, when you try importing another DXF into the same .blend file it is very likely you will get the ‘eekadoodle’ error or the more professional description that has replaced it. Any further DXF imports will be rejected and fail. However, if you import DXF’s one after another, before joining any of the meshes together, you will be able to import múltiple times.

    This rather defeats the object of splitting the CAD file in the first place if you want to build your model in stages. A solution is to import each DXF into a new Blender session, then create the objects from the import and suitably name them, then save as a .blend file and Append the objects created into your main model as required later.

    Another peculiarity you may see as a CAD user is that, when the DXF is imported, the resultant edges, regardless of their orientation, will all have a rotation of 0 degrees. This can be problematic when you want to align a new mesh you create in Blender against an edge from your DXF import when you don't know the angle of edge in Blender. In CAD applications, importing a DXF will put each entity into the 3D world coordinate system and give it a rotation value that you can list or query.

    There are various alignment scripts in Blender but, I have found them overly complicated and protracted for what is a simple requirement as a CAD-trained individual, I just want to do a rotate by reference. 3R, a blenderer, has written a python script which allows you to do just that.

    I've noticed a definite difference in the way Blender handles edges between versión 2.37a and any versión thereafter.

    The difference is that in Blender 2.37a, you could make a face from the DXF import vértices or edges and extrude without getting problems with normals.

    In any versión after 2.37a, making a face and then extruding results in some nasty normals as seen above. The supposed solution is to recalculate normals, but I’ve not found this to solve the problem, it just shifts the problem about.

    One solution is to extrude the edges first and then make the face, for whatever reason this resolves the normals problem.

    Unfortunately for me, I find making the faces first and then extruding to be the preferred method and continue to use 2.37a to model buildings before using the current Blender release to do the rest.

    You may approach modeling by using the floor plans and ‘extruding’ the walls up from the plan to the various heights and then, fill in with wall panels above and below door and window openings.

    Doors and Windows could then be added, modeled by either subdivisión or working up CAD elevation imports of doors and windows.

    You may prefer to use elevation drawings instead of plans and create faces by using the vértices and edges of the DXF import(s) in a sequence such as the following, simplified for demonstration.

    First import a prepared elevation just containing brik walls:

    Columns extruded first:

    Then wall panel:

    Continue until wall modeling is completed:

    Apply and scale texture map, preview, adjust scaling and position of map until it looks right:

    Try to correct brik coursing around door and window openings, especially.

    Repeat the process for the other elements of the elevations such as lintels, window sills, Windows etc.

    An alternative approach to modeling, which can be a fast way to get CAD building elevations with more intricate window openings into a 3D form is as follows:

    The building to model.

    First import the prepared DXF’s. Notice window perimeters are to the outside of the arched brickworque above the window openings and to the bottom edge of the window sill. The intention is to model the arched brickworque heads and sills separately and in order for the python script to work, the outlines need to be simplified continuous shapes. The script is available from 3R's website.

    Run the script and watch the meshes convert to curves. Save your work.

    Select and join with Ctrl-J and the final wall panels are ready for extrusión via the Curves menú to give a wall with thickness.

    The modeling can then continue using the vértices and edges to create faces. Extruding first, if you're not using 2.37a.

    Door and window elevations could then be appended from blend files and added to the openings. Other architectural features can then be worked up to complete the elevation. Possibly a roof/eaves/gutter profile imported from the CAD files and extruded around the building to give a roof perimeter line that is ready to start building the roof pitches, etc. The mesh2curve script can be used again for converting meshes to curves for extruding along a path.

    Another example, a simple house elevation. For demonstration, I’ve applied basic textures and lighting to show what can be accomplished very quickly in this way. A quik Yafray render with HDRi lighting.

    Import the prepared CAD elevations, including the simplified wall perimeters (1) for running the mesh2curve script on. Model the doors, Windows, etc. using the edges and vértices from the full-detail CAD elevations (2) and combine the extruded walls created from the mesh2curve script with the individual door and window objects created from the full-detail elevations(3).

    Here are some images of another house model, done in the same way. Images are rendered with Yafray, skydome, low, cached and HDRi image for lighting. They are unfinished works-in-progress as you can see. I am working on creating a library blend file of trees, bushes, planting, etc.; textured and ready to Append into my scenes. Plant Studio is now free and there are many plant and tree parameter files for download. The trees in this image are Aspens made with Arbaro using the default settings.

    All the elevational elements to this house, for example the dormer Windows, canopies, roof lights, entrance doors, window styles and standard window sizes, are all objects stored in the library blend files I’ve created. So, I can quickly build the walls to a particular house as described above and then append in the objects I need, from the library files (including a texture library), to finish the elevations.

    This process works well for visualizing house builders’ house types that are all variations on a theme, using a set of standard details.

    When appending objects created previously, it can be useful to use a duplicate of your DXF import building elevations as a template to snap your appended objects to in order to accurately locate them. In the example below, I used the template to locate the canopy and it's brackets over the entrance doors and the dormer window positions in the roof.

    You can model the basis of a landscape for the site, on which you intend putting the buildings, in the same way. Import a cleaned up 2D DXF of the site survey, having first defined the perimeters in the CAD file for the various landscape elements like the site boundary, the área to be planted and turfed, the outline of the roads and footpaths. Then use the mesh2curve script on each of those perimeter lines to convert them to closed curves, giving you solid infill to your defined áreas. Mesh (1) below is the perimeter for the landscaping. Mesh (2) was a full site import, but I have been moving the meshes edges onto the final site model and then modeling into 3D. The final site model was based on the curves generated from mesh (1) by the mesh2curve script.

    As an alternative to modeling the landscape of the site, where perhaps you're just doing a massing model and want to show the building in relation to it's surroundings, you could just use an image file as your site, perhaps colored up in The Gimp or Photoshop. Here's a method:

    In your CAD application, open up or create the proposed site plan. For example, from an ordinance survey, clean it up as described previously and then add a square border to form a frame around the área of the site you wish to show in your site image map.

    Save the CAD file as a DXF and put it through the conversión process described earlier.

    Then in CAD, print the CAD drawing to an image file. I use .PNG and use the border as your paper edge. In AutoCAD, I’ve setup a 5000x5000 paper size and then I select by window the square border. I alos use quite heavy line weights to help the final image show up clearly when used in Blender. The resultant image could be colored up in The Gimp to form an attractive site plan.

    In Blender, import the DXF, remove doubles etc. Use two opposite edges that form the square and create a face. Then create a material with an image texture for the new face, the image being your site plan .PNG. Set the image to Clip rather than Repeat. The image will hopefully now be registered accurately over the imported site plan mesh. You can now extrude or model some of the surrounding buildings using the building footprints of the site plan mesh. Add your materials, lighting and camera. When rendered, the modeled buildings should appear to sit accurately on the site plan image map.

    • (1) DXF Import of site plan.
    • (2) Plane with image map of site.
    • (3) SketchUP model.

    And a quik internal render. Work in progress again.

    Looking at an architect’s office situation, where it's not unusual to have an architect or building designer conversant with SketchUP, dealing with design development and design issues, whilst a 3D artist or CAD technician conversant with AutoCAD and Blender, could be modeling and visualizing the site from DXF imports ready for integration of the finalized SketchUP model when its design is finalized. The SketchUP model could be imported as a KMZ, as described earlier, and accurately located on the site by snapping it to the previously imported site mesh.


    My intention for this article has been to suggest ways Blender could be introduced into an architect’s work flow, working in conjunction with CAD, the major software element of any modern architects office. There are many other ways Blender could, or in some cases, is being used by architects and, as the subject is so wide, this article only scratches the surface of the opportunities available.

    by Yellow

    Miniaturas adjuntadas Miniaturas adjuntadas From 2D CaD to 3D Blender-twisted.png   From 2D CaD to 3D Blender-h-wall-panels.png   From 2D CaD to 3D Blender-h-windows.png   From 2D CaD to 3D Blender-final-640x480.png  

    From 2D CaD to 3D Blender-t-dxf-in.png   From 2D CaD to 3D Blender-t-extrude-col.png   From 2D CaD to 3D Blender-t-wall-finished-z.png   From 2D CaD to 3D Blender-t-preview.png  

    From 2D CaD to 3D Blender-t-extrude-wall-panel.png   From 2D CaD to 3D Blender-t-wall-brick.png   From 2D CaD to 3D Blender-7-full-ele1.png   From 2D CaD to 3D Blender-7-wall-panels.png  

    From 2D CaD to 3D Blender-7-wall-panel-z.png   From 2D CaD to 3D Blender-7-ele-brick.png   From 2D CaD to 3D Blender-elevation.png   From 2D CaD to 3D Blender-123.png  

    From 2D CaD to 3D Blender-house.png   From 2D CaD to 3D Blender-house-new4.png   From 2D CaD to 3D Blender-template.png   From 2D CaD to 3D Blender-siteplan-2.png  

    From 2D CaD to 3D Blender-siteplan-1.png   From 2D CaD to 3D Blender-su.png   From 2D CaD to 3D Blender-render.png  
    Si vas a subir un trabajo al foro, hazlo adjuntando la imagen, archivo, vídeo o lo que sea, no publicando enlaces de otros sitios.

    |Agradecer cuando alguien te ayuda es de ser agradecido|

Temas similares

  1. Nuevo libro sobre Blender: Creacion de personajes con Blender 2 69
    Por CaminanteBinario en el foro Quien eres tu - Aqui puedes presentarte
    Respuestas: 5
    Último mensaje: 21-12-2013, 01:52
  2. Blender Demora cuando seleccionas un objeto en Blender Posible Blender Bug
    Por KAEIKO en el foro Problemas con Programas
    Respuestas: 8
    Último mensaje: 30-08-2011, 00:57
  3. Respuestas: 1
    Último mensaje: 30-04-2010, 03:46
  4. Ubuntu 7 10 +blender+aceleracion grafica =Blender peta :
    Por opengl en el foro Problemas con Programas
    Respuestas: 24
    Último mensaje: 23-02-2009, 01:48
  5. abrir archivo de autocad en blender aprendiendo blender 01
    Por Sinor Favela en el foro Problemas con Programas
    Respuestas: 6
    Último mensaje: 21-04-2008, 10:34

Actualmente estos son sus permisos de publicación en el foro.

  • -No puedes crear nuevos temas al no estar registrado o no haber iniciado sesión en el foro.
  • -No puedes responder temas al no estar registrado o no haber iniciado sesión en el foro.
  • -No puedes subir archivos adjuntos al no estar registrado o no haber iniciado sesión en el foro.
  • -No puedes editar tus mensajes al no estar registrado o no haber iniciado sesión en el foro.