- 1 Blender 2.76: Game Engine
- 1.1 Camera lens shift
- 1.2 Physics engine changes
- 1.3 2D Filter
- 1.4 Python API changes
- 1.5 KX_GameObject.getActionName()
- 1.6 Add alpha to coverage render mode
- 1.7 Game Publishing Addon
- 1.8 Compatibility Issues
Blender 2.76: Game Engine
Camera lens shift
The Blender camera supports lens shift in order to produce architecture-like two vanishing point renders and to match projector offsets. Until now, BGE applications relying on those parameters had to resort to manually defining their projection matrices.
We now fully support the Blender camera lens shift (vertical and horizontal), so that what you see in the Blender viewport will be what you see in the game. (D1379). This is particularly important for video projection projects, where you need to mimic the digital projector offset with the game camera.
Physics engine changes
- Angular velocity clamping is now possible (D1365), for an example see D1365-limit-angular-velocity.blend.
- UI fix: velocity clamping now shows actual units as configured in the Blender scene panel, rather than raw Blender Units. (23aa425cd9097)
- 2D Filter now supports integer properties as uniforms (D1370).
Python API changes
New bge.app python submodule
A new module (bge.app) has been added to access application values that remain unchanged during runtime. It provides similar -- but BGE-oriented -- features as the bpy.app submodule.
bge.app contains the following attributes:
version: The Blender/BGE version as a tuple of 3 ints, eg. (2, 75, 1).
version_string: The Blender/BGE version formatted as a string, eg. "2.75 (sub 1)".
version_char: The Blender/BGE version character (for minor releases).
has_texture_ffmpeg: True if the BGE has been built with FFmpeg support, enabling use of bge.texture.ImageFFmpeg and bge.texture.VideoFFmpeg.
has_joystick: True if the BGE has been built with joystick support.
has_physics: True if the BGE has been built with physics support.
KX_BlenderMaterial (specular, diffuse…)
Material settings can be edited in python. The new attributes in KX_BlenderMaterial are:
- alpha (float)
- hardness (float)
- emit (float)
- specularIntensity (float)
- diffuseIntensity (float)
- specularColor (mathutils Color)
- diffuseColor (mathutils Color)
An example is show in file : D1298-materialsettings.blend.
(see commit 145ab8c49efe0de188a55f4c682dd5fcf916f105)
getAnimRecordFrame() gets the current frame number used for recording animations. This number is incremented automatically by Blender when the "Record animation" feature is turned on.
setAnimRecordFrame(framenr) sets that frame number, in case you want to override it. (see commit ba5807c2710939 and D1449). An example is shown in D1449-animrecordframe.blend.
These features allow you to record extra data into F-Curves, beyond what is already stored by the "Record Animation" feature.
getActionName(layer=0) gets the current action played for a specific layer. It allow you to know which action is played currently. Example file getActionName.blend
(see commit 23f54076db6d241af2a8f9404ab5f5b8072a4db0
Add alpha to coverage render mode
Convert the pixel alpha value to a "coverage value" to determine how many samples will be influenced by this pixel. Using alpha-to-coverage will anti-aliased alpha mask edge and produce some smooth result when drawing foliage, trees, bushes. To use it go in material UI menu, game settings panel and set Alpha blend mode to "Alpha Anti-Aliasing" (see commit 749f346ce077f9616a47c03cac03f8537274efc4)
Game Publishing Addon
The addon is now out of beta and benefits of subtle UI changes, moving the platforms "publish" option and assets path chooser inside of their respective lists widgets.
It also underwent some minor changes internally, fixing an issue with the "lib" folder (missing while downloading or manually adding builds to platforms list) and various code clean ups.
- Linked object layers are now respected in the Blenderplayer (see commit 44384c698d394f6e7ed17b61e8406c867488aef9)