-
-
Notifications
You must be signed in to change notification settings - Fork 183
0.1.5
Planar reflection and refraction is a technique simulating the reflection or refraction of a mirror (plane) using a screen based rendering of the scene giving the feeling of infinite mirror.
The render method is used when selecting mapping to PLANE
in the texture panel under the Environment Map
sub panel. When this option is selected the UI is generally the same as for cube maps excepted the new option named Rendering Mode
. This option is used to choose between reflection and refraction.
Because there's two kind of environment maps, BL_Texture.cubeMap
is renamed BL_Texture.renderer
. This attribute return a KX_CubeMap
or the new KX_PlanarMap
. These both classes use a common class named KX_TextureRenderer
which contains all the attributes of the previous KX_CubeMap
. Only KX_PlanarMap
have a new attribute:
KX_PlanarMap.normal
This attribute is the planar normal relative to the viewpoint object. Else the normal is the Z axis of the viewpoint object.
See also: KX_TextureRenderer, KX_PlanarMap, BL_Texture. See also: #acdbcc2
The GLSL text editor syntax coloration is improved to highlight GLSL basic funxtions as texture2D
, mix
.
2D filters can now render to a custom off screen instead of the system off screen used as input textures for the next filter. This method is used to share the work made by a filter into multiple other filters by storing its result. This off screen is created and owned by filters calling the function:
KX_2DFilter.addOffScreen(slots, depth=False, width=-1, height=-1, hdr=bge.render.HDR_NONE, mipmap=False)
Once this, the off screen can be accessed through KX_2DFilter.offScreen
, the returned value is a KX_2DFilterOffScreen
.
This class contains the bind codes for the attachments (colors and depth) and the dimensions of the off screen.
offScreen.width
offScreen.height
offScreen.colorBindCodes
offScreen.depthBindCode
Finally, the bind code are passed to the next 2d filters using the function KX_2DFilter.setTexture
.
For example:
filter0 = scene.filterManager.getFilter(0)
filter1 = scene.filterManager.getFilter(1)
filter0.addOffScreen(1)
filter1.setTexture(0, filter0.offScreen.colorBindCodes[0], "texture")
Sample blurring to a custom off screen and mipmapping blurring to screen.
See also: KX_2DFilter and KX_2DFilterOffScreen.
The user can select to generate mipmap levels for the rendered textures passed to a filter by checking the option Use MipMap
in the 2d filter actuator. Else the python API offer a attribute named KX_2DFilter.mipmap
.
Lod factor is accessible into the UI for cameras, objects and texture renderers (cube map and planar map), this value is put under the Level Of Details
panel placed into the object panel for objects and in the camera panel for camera, or in case of texture renderer into the Environment Map
sub panel.
The lod factor is used to scale the distance between the object and the camera to simulate a camera zoom.
Mist render can be disabled into the viewport thanks to an UI option named World Mist
added in the Display
panel showed when pressing the key T.
With the implementation of the reflection and refraction, real time texture can not assume that the image size is always respecting the cube map ratio. So the resize became optional and is applied when pressing the button Resize
in the texture panel, else the size of the image is displayed with a red background if it is invalid. These two features are used only in case of cube maps.
Some joysticks are not natively supported because they miss in the database used for the mapping of the joysticks. Even that, the user can specify the mapping into a console environment variable and now into a file named gamecontrollerdb.txt
placed in the current directory of the blender or the blenderplayer.
The file should follow the format:
8f0e1200000000000000504944564944,Acme,platform:Windows,x:b2,a:b0,b:b1,y:b3,back:b8,start:b9,dpleft:h0.8,dpdown:h0.4,dpright:h0.2,dpup:h0.1,leftshoulder:b4,lefttrigger:b5,rightshoulder:b6,righttrigger:b7,leftstick:b10,rightstick:b11,leftx:a0,lefty:a1,rightx:a3,righty:a2,
See also: #d735cc2
Duplication of an armatures with their constraints was an old bug in BFBGE, this bug is now fixed in UPBGE. So if a group object, containing an armatures and the objects used for the constraints of the armature, is duplicated, all the objects used as targets by the constraints will be re-linked correctly and will became independent of the other target objects.
See also: #222220b
- Refactor rasterizer off screen management. (see #aa4b6a0)
- Use pimpl idiom for RAS_OpenGLRasterizer. (see #849d065)
- Move debug draw function into RAS_IRasterizer. (see #385f613)
- Use MT_Vector for RAS_IRasterizer::Set[AmbientColor/Fog] arguments. (see #e6eaa10)
- Temporarly remove parallax uv shift option. (see #b6e7205)
- Restore UpdateIPO with mutex. (see #2b3405a)
- Replace NULL with nullptr. (see #712a0e2)
- Fix bounding box of duplicated game objects. (see #cc1f990)
- Fix upbge version check. (see #75bf230)
- Disable automatic warning in debug mode. (see #b983699)
- Avoid merge object of a batch group into an other batch group. (see #d1beb87)
- Check for invalid id.lib in GetFontId. (see #fd8ef93)
- Fix missing switch case break for blenderplayer 'a' option. (see #a68564c)
- Fix string to float conversions execptions. (see #668ccf0)
- Add a check for empty value in property sensor. (see #72c54dd)
- Fix loading of font for object in linked libraries. (see #6f8c7af)
- Fix buffer allocation in IMB_allocFromBuffer. (see #9c5581b)
- Fix place of keyboard.active_events deprecated message. (see #419566e)
- Fix wireframe color. (see #16914be)
- Fix replication of bounding box. (see #d23520c)
- Set duplicated armatures in animated object list. (see #08e344d)
- Fix documentation for deprecated joystick.[hatValues/numHats]. (see #ea680e3)
- Fix projection matrix update in ImageMirror. (see #80fde92)
- Remove BLI_assert in RAS_Shader::RAS_Uniform constructor. (see #983a224)
- Fix python API documentation of KX_2DFilter.setTexture (see #e9da7af)
- Fix parent windows id passed to createWindow. (see #33cc843)
- Fix tSDL_GameControllerAddMappingsFromRW declaration. (see #82f77aa)