http://code.google.com/p/tubras/source/detail?r=1897
Added:
/trunk/tools/irrb/doc/_static/img019.png
/trunk/tools/irrb/doc/_static/img020.png
/trunk/tools/irrb/doc/_static/img021.png
/trunk/tools/irrb/doc/_static/img022.png
Modified:
/trunk/tools/irrb/doc/billboard.rst
/trunk/tools/irrb/doc/camlight.rst
/trunk/tools/irrb/doc/irrbtheme/static/irrbdoc.css
/trunk/tools/irrb/doc/skyboxdome.rst
/trunk/tools/irrb/io_export_irrlicht.py
=======================================
--- /dev/null
+++ /trunk/tools/irrb/doc/_static/img019.png Wed Jan 4 16:11:58 2012
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/tools/irrb/doc/_static/img020.png Wed Jan 4 16:11:58 2012
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/tools/irrb/doc/_static/img021.png Wed Jan 4 16:11:58 2012
Binary file, no diff available.
=======================================
--- /dev/null
+++ /trunk/tools/irrb/doc/_static/img022.png Wed Jan 4 16:11:58 2012
Binary file, no diff available.
=======================================
--- /trunk/tools/irrb/doc/billboard.rst Fri Jul 8 13:10:47 2011
+++ /trunk/tools/irrb/doc/billboard.rst Wed Jan 4 16:11:58 2012
@@ -1,15 +1,38 @@
+==========
Billboards
==========
.. toctree::
:maxdepth: 2
-[screenshot]
-
+.. container:: irrb-right
+
+ .. figure:: _static/img019.png
+
+ Sample Billboard .blend file - `04-Billboard.blend
<http://tubras.googlecode.com/svn/trunk/tools/blendfiles/26/04-Billboard.blend>`_
+
Creating a Billboard in Blender that will be exported as an Irrlicht
Billboard scene node may be performed in 3 steps:
-1. Add a plane (quad) to your scene. The position and scale of the plane
are relevant. The rotation is ignored.
-2. Assign an image to the Billboard using Blender's UV/Image Editor.
-3. Set the irrB Object Type to "Billboard". You may optionally adjust the
billboard shade colors.
-
-[billboard props screenshot]
+ **1.** Add a plane mesh to your scene at the position you would like the
billboard to appear. The scale and rotation are ignored by **irrB**.
+
+ **2.** Create an UV map for the plane and assign it an image using
Blender's UV/Image Editor.
+ The actual UV coordinates are ignored by **irrB**, but you must assigned
an image to the UV map.
+
+ **3.** Set the irrB Object Type to "Billboard" in the **irrB** object
sub-panel. Once the object
+ type is set to "Billboard", you then define the width, height, vertex
(shade) colors.
+
+----
+
+Transparency
+============
+
+.. container:: irrb-left
+
+ .. image:: _static/img020.png
+
+If the image you assigned to the billboard in the UV/Image Editor is
transparent
+and you would like the billboard to be transparent as well, simply create a
+new Blender material and assign it to the billboard plane mesh.
+
+In the **irrB** material properties sub-panel, assign the material type to
+either "trans_alphach" or "trans_alphach_ref" depending on your
requirements.
=======================================
--- /trunk/tools/irrb/doc/camlight.rst Tue Jan 3 11:03:18 2012
+++ /trunk/tools/irrb/doc/camlight.rst Wed Jan 4 16:11:58 2012
@@ -1,6 +1,7 @@
Cameras and Lights
=========================
.. highlight:: cpp
+ :linenothreshold: 5
.. toctree::
:maxdepth: 2
@@ -9,15 +10,14 @@
and light data is only exported when the corresponding is selected in
**irrB**'s
export sub-panel.
-.. container:: irrb-right
-
- .. image:: _static/img017.png
-
Irrlicht camera and light specific properties may be set in **irrB**'s
object
sub-panel.
Camera Details
--------------
+.. container:: irrb-right
+
+ .. image:: _static/img017.png
A camera node in a .irr scene file will appear as follows::
=======================================
--- /trunk/tools/irrb/doc/irrbtheme/static/irrbdoc.css Thu Dec 29 04:52:01
2011
+++ /trunk/tools/irrb/doc/irrbtheme/static/irrbdoc.css Wed Jan 4 16:11:58
2012
@@ -362,7 +362,20 @@
-webkit-box-shadow: 5px 5px 10px #000000;
-moz-box-shadow: 5px 5px 10px #000000;
}
+
+div.irrb-center {
+ clear: none;
+ border: 1px solid #BDC58F;
+ box-shadow: 5px 5px 10px #000000;
+ -webkit-box-shadow: 5px 5px 10px #000000;
+ -moz-box-shadow: 5px 5px 10px #000000;
+}
div.irrb-padleft140 {
margin-left: 180px;
- padding-left: 140px;}
+ padding-left: 140px;
+ }
+
+div.body p.caption {
+ text-align: center;
+}
=======================================
--- /trunk/tools/irrb/doc/skyboxdome.rst Mon Sep 26 10:03:18 2011
+++ /trunk/tools/irrb/doc/skyboxdome.rst Wed Jan 4 16:11:58 2012
@@ -5,11 +5,60 @@
.. toctree::
:maxdepth: 2
-Exporting Sky Boxes and Domes.
-
-Creating a Skybox in Blender that will be exported as an Irrlicht Skybox
scene node requires 4 steps:
-1. Add a Cube mesh to your scene. The position and scale are not
relevant. However, the rotation is important. The Cube should NOT be
arbitrarily rotated. In order for irrb to determine the which images are
the front/back, left/right, and top/bottom, each side of the cube must be
perpendicular to the Blender axes.
-2. Each one of the six Skybox images must be individually mapped to the
appropriate face on the cube. The easiest method for doing this is to use
face select mode CTRL-TAB, faces. Select the appropriate face to map,
unwrap (U), and then assign the corresponding image.
-3. Flip the face normals so that all of normals are facing inward Select
all of the faces (CTRL-A), W, flip normals.
-4. Add an irrb object ID property (inodetype = skybox) to the Cube
indicating that the object should be exported as an Irrlicht Skybox scene
node.
-
+.. container:: irrb-right
+
+ .. image:: _static/img021.png
+
+Creating an Irrlicht Sky Box or Dome in Blender both require:
+
+ 1. Create an arbitrary mesh. A single plane will work fine both a sky box
or dome.
+
+ 2. Create a new Blender Material for the newly created mesh.
+
+After the material has been created, you simply need to assign the
appropriate
+number of images to the material texture slots.
+
+For a Sky Dome, only a single image meeds to be assigned to the first
texture slot.
+
+For a Sky Box, six texture slots will need to be created - each with an
assigned image.
+What's more is that **each texture slot must be named appropriately** (not
the images
+themselves).
+
+The texture slot names for a Sky Box node must
be "left", "right", "top", "bottom",
+"front", and "back". The names are case insensitive and the order is
arbitrary.
+
+----
+
+Sky Dome Options
+================
+
+The Sky Dome options located in the **irrB** Object sub-panel:
+
+.. image:: _static/img022.png
+
+are used to control the size and density of the sphere mesh that is
generated
+for the sky dome.
+
+ **Horz Res** - Number of faces along the horizontal axis.
+
+ **Vert Res** - Number of faces along the vertical axis.
+
+ **Tex Pct** - The percentage of the image to use, e.g. 0.8 uses
+ the top 80% of the image, 1.0 uses the entire image.
+
+ **Sphere Pct** - The percentage of the sphere to generate. A value
+ of 1.0 generates exactly the upper hemisphere. 1.1 will generate slightly
+ more, and 2.0 will generate a full sphere. It is sometimes useful to use
+ a value slightly bigger than 1 to avoid a gap between some ground place
and the sky.
+
+ **Radius** - The size of the sphere in "units".
+
+.. note::
+
+ The **Radius** field must be large enough to contain all of the objects in
+ your scene. Othewise, objects that fall outside of the sky dome radius
will
+ be hidden.
+
+ The sky dome material should have "Fog" disabled in the **irrB** sub-panel
+ to prevent the image from being affected by fog. If sky dome image
appears
+ as a solid color, the materials "Fog" setting is likely enabled.
=======================================
--- /trunk/tools/irrb/io_export_irrlicht.py Sat Dec 31 11:37:27 2011
+++ /trunk/tools/irrb/io_export_irrlicht.py Wed Jan 4 16:11:58 2012
@@ -1666,8 +1666,8 @@
options=emptySet)
bpy.types.Object.irrb_dome_radius = FloatProperty(name='Radius',
- description='Radius', default=10.0,
- min=1.0, max=1000.0, soft_min=1.0, soft_max=1000.0,
+ description='Radius', default=500.0,
+ min=1.0, max=10000.0, soft_min=1.0, soft_max=10000.0,
step=3, precision=2,
options=emptySet)
@@ -4879,6 +4879,10 @@
addWarning(msg)
return None
+ if len(bObject.material_slots) == 0:
+ addWarning('SkyDome missing material')
+ return None
+
mat = bObject.material_slots[0].material
if not mat:
addWarning('SkyDome missing material')