This time we will cover all modelling and preparation techniques to import your scenes to hauzd engine.
This is the first part of the production process to create an interactive 3D project.
We will need 3ds Max to create all our architecture files and export each scene as .fbx, currently, this is the only software compatible with our scripts and our engine.
Why do we need low poly Modelling?
Hauzd final product is designed and developed to run smoothly in any device, mid-range smartphones, low end pcs, modern smart Tvs, Touch Screens and more, most game engines requirements are expensive high-end hardware, this is not the case with our engine, so we must prepare our scenes to run correctly for real time rendering.
Hauzd engine can run big projects with large masterplans and hundreds of units, but you must always have in mind that you have to ensure your client a good performance in all available devices.
Our engine will use the tris as final polycount, you can inspect this number by going into Configure viewport, statistics and show.
You can download and inspect our library to understand how many polys we recommend for each type of object and check how they are created.
Each Interior scene object needs to have the
3d object asset and the
2d object that will be used for the 2d floorplan viewport.
Try to always use the lowest and most accurate amount of poly needed for an object so it doesn’t look chunky but keep in mind these assets will be seen from a certain distance , you can remove lower faces or geometry that the user won´t ever see.
You can also remove all small details and create it as textures using the texture map, using this method, you can add as many details as you want. You can create this textures in photoshop or any other image creation software, always use
power of two dimension.
POWER OF TWO DIMENSIONS
Avoid using more than 3000 tris in one object, save this number for something really important and high detailed element of the scene.
The name convention for your 3d objects is:
ObjNumber adds up to your object name and it will help you to keep your scene organized, Hauzd engine needs unique names for all 3D object so having this number will avoid duplicated names errors.
You will use
TAGS to define some options and engine instructions for your 3d Objects, the most used are:
- BAKE=XXXX, This tag is one of the most important tags, this will be used to bake the lights and shadows into your object, the value of X will be the resolution for your lightmap, this will be independent from your texture atlas and according to your object size, a small objet can use 64 value, and a big object like a full scene floor can use a value of 1024, it must power of two dimensions.
Hauzd engine will do its best to automatically render transparent objects correctly, but you can apply the
SORT tags to certain situations.
- TRANS=XXX This tag and value is used for sorting Transparency, The transparency value by default for all transparent objects is 128. Hauzd engine uses back to front rendering so, the lowest value will be drawn first, and the highest value will be drawn last, the object you want to be directly on front of the camera, should have the highest value, and the object that is further away should have the lowest value.
Correct Back to Front Drawing
Correct Back to Front Drawing
Incorrect Back to Front Drawing
Incorrect Back to Front Setting
- SORT This tag is used for sorting triangles within a single object, this will automatically cache multiple triangle orders based on different camera angles, this is particularly useful for foliage geometry to avoid display artifacts.
- MIRROR=10 This tag is for creating a reflection plane on your floorplan floor, it will only work with planar geometry and its expensive on performance so use it wisely.
MIRROR=10 Tag Active
NO mirror Tag
You also need to set certain
PREFIXES to identify what type of asset it is:
- obj_ this will mark your asset as a “3D OBJECT”, any asset marked as an "obj" in the engine, will be able to be used as an instance object and shared among scenes within the engine, this saves a Lot of memory and optimizes performance.
- geom_ We recommend to use this prefix for all your unique non instanceable structure geometry, terrain, walls, roof, floors, or forms a part of your building, house or apartment.
- plan_ This prefix is for the geometry that acts as a 2d display on the engine, if you created your floorplan using the Walls Generation Script, all geometry intended for 2d display will be automatically generated with this prefix.
- planObj_ his acts the same as the "plan" prefix but "planObj_" is intended for 2d furniture or "props" representation, anything thats not walls, doors, windows, or part of the floorplan structure should have this prefix so the engine can distinguish between this 2 categories and be able to hide them if desired when visualizing the apartmen's measurements.
- planDim_ You will only add this prefix to the lines (splines) that you will use for marking your floorplan's measurements.
- part_ This prefix is for marking any geometry that is intended to be highlighted when selected, in most cases you will use the "part_" prefix for marking apartment windows on your building exterior scene or floors in keyplans.
- partColl_ This prefix works in conjunction with the "part" prefix, since no geometry object will be able to be highlighted if it is not selected first, and the "partColl_" prefix is preciselly to mark a geometry object as a "selectable volume" so the engine can detect its Collition so users are able to tap on it.
part_ on Window Object
part_ and partColl_ in action
- cam_ You will use this prefix for marking the 3d object the engine will use as the reference for the Camera through which you will view and manipulate your 3d scene.
- camLoc_ This prefix works exactly like the "cam" one but "camLoc_" is intended for marking the Nurbs object that will be used as reference for the Points of Interest Camera.
Unlike regular game engines with Hauzd you can have practically unlimited number of light sources in your scene, you will have 2 prefixes to identify them.
- sun_ This prefix will mark your Omni light as a "Sun light" that will be recognized by the engine.
- light_ This will mark standard light elements as interior lighting.
Material Set Up
Right now, only standard materials are compatible with the engine, we will need to use texture atlas containing the maps you need for some objects, using power of two texture dimensions sizes, we can organize all our different maps inside that canvas.
You can use Photoshop to assemble your atlas and, to define the reflection value, you can use the opacity value, being 2 the lowest value for reflectivity, and 100 the highest value. We will learn how to use this a little bit later.
For now, you can only use the diffuse input for your color and reflection value, and the alpha input if the object has any kind of texture based transparency.
To organize our scenes better, we will set up a multi sub material, which will hold our materials so we can assign them with material ids. The name conventions for this materials will be:
You will use tags to define some options for your materials, the most used are:
- ENVMAP This will define the cubemap reflection based on the Specular Value or your png opacity value that you assigned in photoshop.
- ENVPULL=X.X this tag is for the reflection not to stay fixed with the camera, recommended value is 0.7
- BAKEOPAC=X.X this makes the material translucent to the light it receives, a value of 1.0 will stop the light from passing through the object and create a solid shadow.
- TWOSIDE This tag will make the material turn the object's polygons visible by their 2 sides.
To set and use the lightmaps, first, in the modelling process you need to add a second UV channel where the shadows will be baked, you can use our script for this, make sure none of the parts of the uvs are overlapping, this may cause artifacts, after setting the tags, you need to run the “BAKE” command in our engine and wait for some minutes, after its ready, you can click VIEW and see the results.
If it looks pixelated, dirty or with noise, you can increase the resolution in the bake tag and run the command again.
Installing Scripts and Overview
For 3ds max, you need to go to your script folder and copy all the contents inside of it, this way, the main hauzd script will load every time you open the software.
From this script you can execute the engine, export your scene correctly and unwrap UVs.
Same way for illustrator UI script, you need to go to your local disk, and paste the file in the preset folder.
This script will be used to export your interface assets for Hauzd engine.
For the wall generation script, you can paste the files in a separate folder and open it whenever you need it.
Scenes Hierarchy / Linking
You need to create your project using different level of details that we are going to organize from bigger to smaller.
Masterplan - > Buildings -> Keyplans -> Unit
House/ Office / Apartment / Floor
We will link all these scenes using interactive collisions with the tags part and partColl. This way, the user can go in and out from each unit after configuring the pairing with hauzdEdit.
You can begin your 3D production with the smallest unit and the bigger exterior scene, the fastest way to work your interior scenes is to use our wall
generation script, this script will generate the walls, doors, windows, textures, unwrap your UVs for texture and lightmaps, and set all names and tags you will need for your structure.
After cleaning up your CAD file, you can import it in 3ds max, you will need to trace splines, this is the way the script will recognize where to build a wall and how to do it.
Using IDs, the script will recognize where to create a solid wall, a door or a window.
The most important thing is that you always need to place yourself in front of the wall you will draw, and draw ALWAYS to the right.
There are several video tutorials and documentation for this script in our help desk, we recommend to go to help.hauzd.com and learn everything about it, this wall generation script can make your work easier for interior floorplans, it creates everything you need so you just need to add and place furniture, extra elements and you´re done.
Before exporting, Make sure everything you need to add to the engine is in the proper EXPORT layer, check tags and use the Export Button of the script.
keyplans, you will need to make the structure of the whole floor, you can use the wall generation script in this part as well, but you can skip the furniture, you will also need to set up your collisions so the final user can enter each unit from this keyplan.
exterior modelling we need to use another workflow, the wall generation script won´t be useful on this part, we need to optimize as much as we can by attaching multiple close objects and be careful with our vegetation, we also need to set our collision objects for this scene, this collisions will lead into our keyplans or apartments.
Remember, you can use our
for your scenes or create your own assets.