[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [38903] branches/soc-2008-mxcurioni: Merged changes in the trunk up to revision 38893.

Tamito Kajiyama rd6t-kjym at asahi-net.or.jp
Mon Aug 1 22:18:06 CEST 2011


Revision: 38903
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=38903
Author:   kjym3
Date:     2011-08-01 20:18:02 +0000 (Mon, 01 Aug 2011)
Log Message:
-----------
Merged changes in the trunk up to revision 38893.

Revision Links:
--------------
    http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=38893

Modified Paths:
--------------
    branches/soc-2008-mxcurioni/CMakeLists.txt
    branches/soc-2008-mxcurioni/build_files/cmake/cmake_consistency_check.py
    branches/soc-2008-mxcurioni/build_files/cmake/cmake_netbeans_project.py
    branches/soc-2008-mxcurioni/build_files/cmake/cmake_qtcreator_project.py
    branches/soc-2008-mxcurioni/doc/python_api/examples/bge.constraints.py
    branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.1.py
    branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.py
    branches/soc-2008-mxcurioni/doc/python_api/examples/blf.py
    branches/soc-2008-mxcurioni/doc/python_api/examples/mathutils.Vector.py
    branches/soc-2008-mxcurioni/doc/python_api/rst/bge.constraints.rst
    branches/soc-2008-mxcurioni/doc/python_api/rst/bge.events.rst
    branches/soc-2008-mxcurioni/doc/python_api/rst/bge.logic.rst
    branches/soc-2008-mxcurioni/doc/python_api/rst/bge.render.rst
    branches/soc-2008-mxcurioni/doc/python_api/rst/bge.texture.rst
    branches/soc-2008-mxcurioni/doc/python_api/rst/bge.types.rst
    branches/soc-2008-mxcurioni/doc/python_api/rst/bgl.rst
    branches/soc-2008-mxcurioni/doc/python_api/sphinx_doc_gen.py
    branches/soc-2008-mxcurioni/doc/python_api/sphinx_doc_gen.sh
    branches/soc-2008-mxcurioni/intern/ghost/intern/GHOST_SystemCocoa.mm
    branches/soc-2008-mxcurioni/intern/ghost/intern/GHOST_SystemWin32.cpp
    branches/soc-2008-mxcurioni/release/scripts/modules/addon_utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy/__init__.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy/path.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy/utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_extras/__init__.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_extras/image_utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_extras/io_utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_extras/mesh_utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_extras/object_utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_extras/view3d_utils.py
    branches/soc-2008-mxcurioni/release/scripts/modules/bpy_types.py
    branches/soc-2008-mxcurioni/release/scripts/modules/keyingsets_utils.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/add_mesh_torus.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/image.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/mesh.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/object.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/object_align.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/object_quick_effects.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/object_randomize_transform.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/presets.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/screen_play_rendered_anim.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/uvcalc_smart_project.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_empty.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_modifier.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_world.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_info.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_node.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_text.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_userpref.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_view3d.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_view3d_toolbar.py
    branches/soc-2008-mxcurioni/release/scripts/templates/addon_add_object.py
    branches/soc-2008-mxcurioni/release/scripts/templates/batch_export.py
    branches/soc-2008-mxcurioni/source/blender/blenkernel/BKE_blender.h
    branches/soc-2008-mxcurioni/source/blender/blenkernel/BKE_curve.h
    branches/soc-2008-mxcurioni/source/blender/blenkernel/BKE_material.h
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/DerivedMesh.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/cdderivedmesh.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/curve.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/customdata.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/ipo.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/key.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/material.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/mesh.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/multires.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/seqeffects.c
    branches/soc-2008-mxcurioni/source/blender/blenkernel/intern/text.c
    branches/soc-2008-mxcurioni/source/blender/blenlib/intern/BLI_args.c
    branches/soc-2008-mxcurioni/source/blender/blenlib/intern/pbvh.c
    branches/soc-2008-mxcurioni/source/blender/blenloader/intern/readfile.c
    branches/soc-2008-mxcurioni/source/blender/collada/MaterialExporter.cpp
    branches/soc-2008-mxcurioni/source/blender/collada/MaterialExporter.h
    branches/soc-2008-mxcurioni/source/blender/editors/armature/editarmature.c
    branches/soc-2008-mxcurioni/source/blender/editors/curve/editcurve.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/interface_anim.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/interface_handlers.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/interface_layout.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/interface_panel.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/interface_regions.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/interface_templates.c
    branches/soc-2008-mxcurioni/source/blender/editors/interface/resources.c
    branches/soc-2008-mxcurioni/source/blender/editors/object/object_add.c
    branches/soc-2008-mxcurioni/source/blender/editors/object/object_relations.c
    branches/soc-2008-mxcurioni/source/blender/editors/screen/screen_ops.c
    branches/soc-2008-mxcurioni/source/blender/editors/sculpt_paint/paint_image.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_node/node_draw.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_node/node_edit.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_sequencer/sequencer_add.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_text/text_ops.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_view3d/view3d_edit.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_view3d/view3d_header.c
    branches/soc-2008-mxcurioni/source/blender/editors/space_view3d/view3d_select.c
    branches/soc-2008-mxcurioni/source/blender/editors/transform/transform.c
    branches/soc-2008-mxcurioni/source/blender/editors/transform/transform.h
    branches/soc-2008-mxcurioni/source/blender/editors/transform/transform_generics.c
    branches/soc-2008-mxcurioni/source/blender/editors/transform/transform_snap.c
    branches/soc-2008-mxcurioni/source/blender/editors/util/undo.c
    branches/soc-2008-mxcurioni/source/blender/editors/uvedit/uvedit_ops.c
    branches/soc-2008-mxcurioni/source/blender/gpu/intern/gpu_material.c
    branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_modifier_types.h
    branches/soc-2008-mxcurioni/source/blender/makesdna/DNA_scene_types.h
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_ID.c
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_access.c
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_modifier.c
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_object_api.c
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_scene.c
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_wm.c
    branches/soc-2008-mxcurioni/source/blender/makesrna/intern/rna_wm_api.c
    branches/soc-2008-mxcurioni/source/blender/modifiers/intern/MOD_uvproject.c
    branches/soc-2008-mxcurioni/source/blender/python/intern/bpy_rna.c
    branches/soc-2008-mxcurioni/source/blender/python/mathutils/mathutils.h
    branches/soc-2008-mxcurioni/source/blender/python/mathutils/mathutils_Matrix.c
    branches/soc-2008-mxcurioni/source/blender/python/mathutils/mathutils_Quaternion.c
    branches/soc-2008-mxcurioni/source/blender/python/mathutils/mathutils_Vector.c
    branches/soc-2008-mxcurioni/source/blender/render/intern/source/convertblender.c
    branches/soc-2008-mxcurioni/source/blender/windowmanager/WM_api.h
    branches/soc-2008-mxcurioni/source/blender/windowmanager/intern/wm.c
    branches/soc-2008-mxcurioni/source/blender/windowmanager/intern/wm_init_exit.c
    branches/soc-2008-mxcurioni/source/blenderplayer/bad_level_call_stubs/stubs.c
    branches/soc-2008-mxcurioni/source/creator/creator.c
    branches/soc-2008-mxcurioni/source/gameengine/GameLogic/Joystick/SCA_Joystick.cpp
    branches/soc-2008-mxcurioni/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
    branches/soc-2008-mxcurioni/source/gameengine/Ketsji/KX_PyConstraintBinding.cpp
    branches/soc-2008-mxcurioni/source/tests/CMakeLists.txt
    branches/soc-2008-mxcurioni/source/tests/check_deprecated.py

Added Paths:
-----------
    branches/soc-2008-mxcurioni/release/scripts/templates/ui_menu.py
    branches/soc-2008-mxcurioni/release/scripts/templates/ui_menu_simple.py
    branches/soc-2008-mxcurioni/release/scripts/templates/ui_panel_simple.py

Removed Paths:
-------------
    branches/soc-2008-mxcurioni/release/scripts/templates/panel_simple.py

Property Changed:
----------------
    branches/soc-2008-mxcurioni/
    branches/soc-2008-mxcurioni/intern/audaspace/OpenAL/
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/add_mesh_torus.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/uvcalc_smart_project.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_operators/vertexpaint_dirt.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_armature.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_bone.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_camera.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_empty.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_lamp.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_lattice.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_mesh.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_metaball.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_data_modifier.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_game.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_material.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_particle.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_physics_field.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_physics_fluid.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_physics_smoke.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_texture.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/properties_world.py
    branches/soc-2008-mxcurioni/release/scripts/startup/bl_ui/space_node.py
    branches/soc-2008-mxcurioni/source/blender/editors/render/render_update.c
    branches/soc-2008-mxcurioni/source/blender/editors/uvedit/uvedit_buttons.c


Property changes on: branches/soc-2008-mxcurioni
___________________________________________________________________
Modified: svn:mergeinfo
   - /trunk/blender:34011-38663
   + /trunk/blender:34011-38893

Modified: branches/soc-2008-mxcurioni/CMakeLists.txt
===================================================================
--- branches/soc-2008-mxcurioni/CMakeLists.txt	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/CMakeLists.txt	2011-08-01 20:18:02 UTC (rev 38903)
@@ -1054,20 +1054,34 @@
 	endif()
 endif()
 
+# See TEST_SSE_SUPPORT() for how this is defined.
+
 if(WITH_RAYOPTIMIZATION)
 	if(CMAKE_COMPILER_IS_GNUCC)
-		if(SUPPORT_SSE_BUILD)
-			set(PLATFORM_CFLAGS " -msse ${PLATFORM_CFLAGS}")
-			add_definitions(-D__SSE__ -D__MMX__)
+		set(_sse "-msse")
+		set(_sse2 "-msse2")
+	elseif(MSVC)
+		set(_sse "/arch:SSE")
+		set(_sse2 "/arch:SSE2")
+	else()
+		message(WARNING "SSE flags for this compiler not known")
+		set(_sse)
+		set(_sse2)
+	endif()
+
+	if(SUPPORT_SSE_BUILD)
+		set(PLATFORM_CFLAGS " ${_sse} ${PLATFORM_CFLAGS}")
+		add_definitions(-D__SSE__ -D__MMX__)
+	endif()
+	if(SUPPORT_SSE2_BUILD)
+		set(PLATFORM_CFLAGS " ${_sse2} ${PLATFORM_CFLAGS}")
+		add_definitions(-D__SSE2__)
+		if(NOT SUPPORT_SSE_BUILD) # dont double up
+			add_definitions(-D__MMX__)
 		endif()
-		if(SUPPORT_SSE2_BUILD)
-			set(PLATFORM_CFLAGS " -msse2 ${PLATFORM_CFLAGS}")
-			add_definitions(-D__SSE2__)
-			if(NOT SUPPORT_SSE_BUILD) # dont double up
-				add_definitions(-D__MMX__)
-			endif()
-		endif()
 	endif()
+	unset(_sse)
+	unset(_sse2)
 endif()
 
 if(WITH_IMAGE_OPENJPEG)

Modified: branches/soc-2008-mxcurioni/build_files/cmake/cmake_consistency_check.py
===================================================================
--- branches/soc-2008-mxcurioni/build_files/cmake/cmake_consistency_check.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/build_files/cmake/cmake_consistency_check.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -39,12 +39,12 @@
     file_handle = open(f, 'r')
     data = file_handle.readlines()
     file_handle.close()
-    
+
     l = data[i]
     ws = l[:len(l) - len(l.lstrip())]
-    
+
     data[i] = "%s%s\n" % (ws, text)
-    
+
     file_handle = open(f, 'w')
     file_handle.writelines(data)
     file_handle.close()
@@ -182,13 +182,13 @@
 
                                 if new_path_rel != l:
                                     print("overly relative path:\n  %s:%d\n  %s\n  %s" % (f, i, l, new_path_rel))
-                                    
+
                                     ## Save time. just replace the line
                                     # replace_line(f, i - 1, new_path_rel)
-                                    
+
                             else:
                                 raise Exception("non existant include %s:%d -> %s" % (f, i, new_file))
-                            
+
                         # print(new_file)
 
             global_h.update(set(sources_h))
@@ -206,7 +206,7 @@
                 if ff not in sources_c:
                     print("  missing: " + ff)
             '''
-            
+
             # reset
             sources_h[:] = []
             sources_c[:] = []

Modified: branches/soc-2008-mxcurioni/build_files/cmake/cmake_netbeans_project.py
===================================================================
--- branches/soc-2008-mxcurioni/build_files/cmake/cmake_netbeans_project.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/build_files/cmake/cmake_netbeans_project.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -30,8 +30,19 @@
 Windows not supported so far
 """
 
-from project_info import *
+from project_info import (SIMPLE_PROJECTFILE,
+                          SOURCE_DIR,
+                          CMAKE_DIR,
+                          PROJECT_DIR,
+                          source_list,
+                          is_project_file,
+                          is_c_header,
+                          # is_py,
+                          cmake_advanced_info,
+                          cmake_compiler_defines,
+                          )
 
+
 import os
 from os.path import join, dirname, normpath, relpath, exists
 

Modified: branches/soc-2008-mxcurioni/build_files/cmake/cmake_qtcreator_project.py
===================================================================
--- branches/soc-2008-mxcurioni/build_files/cmake/cmake_qtcreator_project.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/build_files/cmake/cmake_qtcreator_project.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -31,7 +31,17 @@
  python .~/blenderSVN/blender/build_files/cmake/cmake_qtcreator_project.py ~/blenderSVN/cmake
 """
 
-from project_info import *
+from project_info import (SIMPLE_PROJECTFILE,
+                          SOURCE_DIR,
+                          # CMAKE_DIR,
+                          PROJECT_DIR,
+                          source_list,
+                          is_project_file,
+                          is_c_header,
+                          is_py,
+                          cmake_advanced_info,
+                          cmake_compiler_defines,
+                          )
 
 import os
 import sys

Modified: branches/soc-2008-mxcurioni/doc/python_api/examples/bge.constraints.py
===================================================================
--- branches/soc-2008-mxcurioni/doc/python_api/examples/bge.constraints.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/doc/python_api/examples/bge.constraints.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -8,11 +8,11 @@
 
 # get object list
 objects = logic.getCurrentScene().objects
- 
+
 # get object named Object1 and Object 2
 object_1 = objects["Object1"]
 object_2 = objects["Object2"]
- 
+
 # want to use Edge constraint type
 constraint_type = 2
 
@@ -31,7 +31,7 @@
 edge_angle_z = 0.0
 
 # create an edge constraint
-constraints.createConstraint( physics_id_1, physics_id_2,
-                              constraint_type,
-                              edge_position_x, edge_position_y, edge_position_z,
-                              edge_angle_x, edge_angle_y, edge_angle_z )
+constraints.createConstraint(physics_id_1, physics_id_2,
+                             constraint_type,
+                             edge_position_x, edge_position_y, edge_position_z,
+                             edge_angle_x, edge_angle_y, edge_angle_z)

Modified: branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.1.py
===================================================================
--- branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.1.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.1.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -6,29 +6,31 @@
 Controller.
 """
 from bge import logic
-from bge import texture	
+from bge import texture
 
+
 def createTexture(cont):
     """Create a new Dynamic Texture"""
     object = cont.owner
-	
+
     # get the reference pointer (ID) of the internal texture
     ID = texture.materialID(obj, 'IMoriginal.png')
-	
-    # create a texture object 
+
+    # create a texture object
     object_texture = texture.Texture(object, ID)
-	
+
     # create a new source with an external image
     url = logic.expandPath("//newtexture.jpg")
     new_source = texture.ImageFFmpeg(url)
-	
+
     # the texture has to be stored in a permanent Python object
     logic.texture = object_texture
-	
+
     # update/replace the texture
     logic.texture.source = new_source
     logic.texture.refresh(False)
 
+
 def removeTexture(cont):
     """Delete the Dynamic Texture, reversing back the final to its original state."""
     try:

Modified: branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.py
===================================================================
--- branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/doc/python_api/examples/bge.texture.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -9,14 +9,14 @@
 
 cont = logic.getCurrentController()
 obj = cont.owner
-	
-# the creation of the texture must be done once: save the 
+
+# the creation of the texture must be done once: save the
 # texture object in an attribute of bge.logic module makes it persistent
 if not hasattr(logic, 'video'):
-	
+
     # identify a static texture by name
     matID = texture.materialID(obj, 'IMvideo.png')
-		
+
     # create a dynamic texture that will replace the static texture
     logic.video = texture.Texture(obj, matID)
 
@@ -24,7 +24,7 @@
     movie = logic.expandPath('//trailer_400p.ogg')
     logic.video.source = texture.VideoFFmpeg(movie)
     logic.video.source.scale = True
-		
+
     # quick off the movie, but it wont play in the background
     logic.video.source.play()
 

Modified: branches/soc-2008-mxcurioni/doc/python_api/examples/blf.py
===================================================================
--- branches/soc-2008-mxcurioni/doc/python_api/examples/blf.py	2011-08-01 18:47:31 UTC (rev 38902)
+++ branches/soc-2008-mxcurioni/doc/python_api/examples/blf.py	2011-08-01 20:18:02 UTC (rev 38903)
@@ -1,6 +1,7 @@
 """
 Hello World Text Example
 ++++++++++++++++++++++++
+
 Blender Game Engine example of using the blf module. For this module to work we
 need to use the OpenGL wrapper :class:`~bgl` as well.
 """
@@ -11,31 +12,33 @@
 import bgl
 import blf
 
+
 def init():
     """init function - runs once"""
     # create a new font object, use external ttf file
     font_path = logic.expandPath('//Zeyada.ttf')
-	# store the font indice - to use later
+    # store the font indice - to use later
     logic.font_id = blf.load(font_path)
 
-    # set the font drawing routine to run every frame   
+    # set the font drawing routine to run every frame
     scene = logic.getCurrentScene()
-    scene.post_draw=[write]
+    scene.post_draw = [write]
 
+
 def write():
     """write on screen"""
     width = render.getWindowWidth()
     height = render.getWindowHeight()
-    
+
     # OpenGL setup
     bgl.glMatrixMode(bgl.GL_PROJECTION)
     bgl.glLoadIdentity()
     bgl.gluOrtho2D(0, width, 0, height)
     bgl.glMatrixMode(bgl.GL_MODELVIEW)
     bgl.glLoadIdentity()
-    
+
     # BLF drawing routine
     font_id = logic.font_id
-    blf.position(font_id, (width*0.2), (height*0.3), 0)
+    blf.position(font_id, (width * 0.2), (height * 0.3), 0)
     blf.size(font_id, 50, 72)
     blf.draw(font_id, "Hello World")


@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list