Campbell Barton
250109f5ac
add argument so recent bge function mesh.transform_uv() so you can optionally transform between UV1 / UV2
2012-11-10 10:26:39 +00:00
Campbell Barton
fecc3b9d68
add 2 new utility functions to the BGE mesh py api.
...
mesh.transform(matid, matrix)
mesh.transform_uv(matid, matrix, uv_index=-1))
much more efficient then looping over verts in python to transform them.
2012-11-10 09:45:43 +00:00
Campbell Barton
936f0388e8
code cleanup: some warnings and formatting for PyMethodDef's in the BGE.
2012-11-10 05:42:50 +00:00
Mitchell Stokes
f6a110d6ea
BGE: Committing patch [ #32697 ] "New BGE gravity API" by HG1.
...
This patch adds a gravity attribute to KX_Scene.
2012-11-10 03:11:18 +00:00
Campbell Barton
5a29885007
code cleanup: bge static functions & use C++ guarded alloc for the character class.
2012-11-09 23:47:06 +00:00
Campbell Barton
d25b13d13f
code cleanup: double promotion warnings, also allow cmake to build SDL without audaspace.
2012-11-09 16:15:00 +00:00
Campbell Barton
617a73c573
code cleanup: unused defines & some formatting.
2012-11-08 06:46:10 +00:00
Antony Riakiotakis
8d0b2bc17f
Compile fixes for recent boost changes
2012-11-05 15:23:09 +00:00
Mitchell Stokes
b2f837896d
Fix for [ #33090 ] "Segfault/Crash with Empty and Motion Actuator, Keyboard Sensor" reported by Martin Felke (scorpion81).
...
Apparently, not all objects have physics controllers, so now we do a NULL check in KX_ObjectActuator.
2012-11-05 15:13:54 +00:00
Joerg Mueller
5a8d5f77af
Audaspace:
...
Replacing AUD_Reference with boost::shared_ptr.
2012-11-05 14:24:35 +00:00
Mitchell Stokes
f840bd4a9f
BGE: This patch adds a character wrapper (similar to the already implemented vehicle wrapper) to control character physics options. Currently supported options are:
...
* jump() -- causes the character to jump
* onGround -- specifies whether or not the character is on the ground
* gravity -- controls the "gravity" that the character physics uses for the character
More options could be added (such as jump speed, step height, make fall speed, max slope, etc).
2012-11-04 20:56:02 +00:00
Campbell Barton
ff014a3077
code cleanup: cmake - add missing headers, remove directories from source listing.
...
also remove logImageLib.c - empty file.
2012-11-03 15:49:38 +00:00
Campbell Barton
25591e958d
style cleanup: tabs & whitespace
2012-11-03 15:35:03 +00:00
Mitchell Stokes
b6596467d9
BGE: Fix for bug #33025 "Character physics object won't stop moving with simple motion actuator" reported by Jared Smith (jsmithketchup). Characters no longer use a simple translation change for ApplyMovement(), they instead delegate to the character controller's setWalkDirection(). The motion actuator now sets this to (0, 0, 0) on a negative pulse.
2012-11-01 03:11:39 +00:00
Mitchell Stokes
028d5a64fc
BGE: Committing patch #32291 "Updated profiling layout for BGE" from Angus Hollands (agoose77). This patch adds a headers for the profiling information and for the debug properties so they are no longer jumbled together. It also modifies how debug properties are displayed; changes "swap" to "Frametime"; and changes the display from seconds to ms, which is much more useful.
...
In addition to this patch, I've also modified the precision of the numbers displayed in the profiling information to make things a little cleaner.
2012-10-30 22:45:08 +00:00
Campbell Barton
76ba8f017e
code cleanup: remove unused transform snapping code (only use the BVH accelerated version now).
...
and quiet narrowing conversion warning between signed/unsigned int.
2012-10-30 19:27:15 +00:00
Campbell Barton
00acdb6292
remove CD_POLYINDEX customdata layer:
...
reported as [#29376 ] BMESH_TODO: remove tessface CD_ORIGINDEX layer
for a single mesh there could be 3 origindex mappings stored, one on the polygons and 2 on the tessfaces.
(CD_POLYINDEX and CD_ORIGINDEX).
as Andrew suggests, now tessfaces (which are really a cache of polygons), using origindex to point to polygons on
the same derived mesh, and polygons only store the original index values.
2012-10-30 19:20:17 +00:00
Mitchell Stokes
3bf9bb3b13
BGE: Adding support for Bullet's collision masks. Each object now has a collision mask and a collision group. Object A and object B collide if object A's groups is in object B's mask and object B's group is in object A's mask. In other words, the group defines what the object is (collision wise) and the group defines what the object can collide with.
...
The majority of this patch was provided by Kupoman with some edits from me and heavy testing by z0r.
2012-10-30 15:44:16 +00:00
Campbell Barton
5549904171
style cleanup
2012-10-29 02:11:40 +00:00
Campbell Barton
aeba4950c3
style cleanup
2012-10-27 10:42:28 +00:00
Campbell Barton
f70d2c65d8
rename api functions...
...
- minf, maxf, mini, maxi --> min_ff, max_ff, min_ii, max_ii
2012-10-23 13:28:22 +00:00
Campbell Barton
9c58865d20
code cleanup: remove $Id's that crept back in, also osl style edits
2012-10-23 11:47:23 +00:00
Bastien Montagne
b5e85cae70
New "dynamic" i18n menu.
...
Now both UI translation menu (in userprefs) and isocodes are defined in a text file (release/datafiles/locale/languages), parsed at lunchtime. This way:
* No more need to edit Blender code each time we want to add an new language or reorganize the existing menu;
* Translators can easily add a new language for testing, by just editing the text file, so no more need to ask to change Blender code and wait for a new build to see your new translation work in Blender!
Remaining todo:
* Commit i18n py tools
* Update wiki doc!
2012-10-22 14:04:40 +00:00
Campbell Barton
ddc2dbc2a4
style cleanup
2012-10-22 08:15:51 +00:00
Campbell Barton
226a5ee834
remove LOD_Decimator (c++ decimator), now replaced by bmesh decimator. also remove CTR c++ classes that are no longer used.
2012-10-22 02:39:26 +00:00
Campbell Barton
d599b643b7
style cleanup: bge, switch statements mostly.
...
also left bmesh decimator on in previous commit.
2012-10-21 07:58:38 +00:00
Campbell Barton
f3ece5a108
style cleanup: trailing tabs & expand some non prefix tabs into spaces.
2012-10-21 05:46:41 +00:00
Benoit Bolsee
4213eca5fc
BGE VideoTexture: add depth buffer access to ImageViewport and ImageRender.
...
2 new attributes to ImageViewport and ImageRender object:
depth: set to True to retrieve the depth buffer as an array of float
(not suitable for texture source).
zbuff: set to True to retrieve the depth buffer as a grey scale pixel array
(suitable for texture source).
A new mode 'F' is added to VideoTexture.imageToArray() to allow returning the image
buffer as a one dimensional array of float. This mode should only be used to retrieve
the depth buffer of ImageViewport and ImageRender objects.
Example:
viewport = VideoTexture.ImageViewport()
viewport.depth = True
depth = VideoTexture.imageToArray(viewport,'F')
# show depth of bottom left pixel
# 1.0 = infinite, 0.0 = on near clip plane.
print(depth[0])
2012-10-20 22:28:44 +00:00
Campbell Barton
7deb8d8a26
code cleanup: spelling
2012-10-20 20:36:51 +00:00
Campbell Barton
bc8f602601
style cleanup
2012-10-20 18:46:57 +00:00
Campbell Barton
536d9fec80
code cleanup:
...
- move object_iterators.c --> view3d_iterators. (ED_object.h had to include ED_view3d.h which isn't so nice)
- move projection functions from view3d_view.c --> view3d_project.c (view3d_view was becoming a mishmash of utility functions and operators).
- some some cmake includes as system-includes.
2012-10-17 04:13:03 +00:00
Campbell Barton
92862f96dc
code cleanup: use float sizes for function args.
2012-10-15 23:11:59 +00:00
Campbell Barton
504180674e
style cleanup: bge
2012-10-15 04:16:34 +00:00
Campbell Barton
ab86e9593b
add missing redraw notifier for separate UV operator, also some style cleanup and remove unused define.
2012-10-15 03:17:10 +00:00
Campbell Barton
4d4664d98f
code cleanup: check for msvc directly when using warning pragma's.
2012-10-15 02:15:07 +00:00
Campbell Barton
8e01b8959e
style cleanup
2012-10-14 13:08:19 +00:00
Campbell Barton
3a947cf537
code cleanup: remove redundant casts
2012-10-14 08:49:01 +00:00
Mitchell Stokes
64b187a928
Blenderplayer: Fixing a crash on startup when the graphics driver tried to use uninitialized memory. I had fixed this previously in Swiss, but it looks like I missed grabbing the fix when bringing the GetViewPort() changes into trunk.
2012-10-14 04:22:38 +00:00
Campbell Barton
97d4fb4161
code cleanup: make header defines more consistent, JOYSENSOR header guard had a typo too.
2012-10-09 13:36:42 +00:00
Campbell Barton
b1c4809f50
rename BGE KX_GameObject attrs
...
* group -> group_parent
* members -> group_children
so its more clear what direction the relationship is.
2012-10-09 06:03:57 +00:00
Campbell Barton
8d2835b5e5
patch [ #31875 ] Patch to get scene access through a game object
...
from Jay Parker (battery)
2012-10-09 05:58:09 +00:00
Campbell Barton
b16ca24d98
code cleanup: quiet -Wreorder
2012-10-09 03:14:38 +00:00
Mitchell Stokes
244ce92dbd
BGE: Setting up the RAS_ICanvas interface as the primary way to alter the OpenGL
...
viewport. This helps to eliminate OpenGL calls in weird places like the physics
code and to reduce glGet calls, which are expensive.
There should be no functional changes (except maybe a very slight speed improvement).
2012-10-08 03:28:11 +00:00
Mitchell Stokes
99dd59f08c
BGE: Disable depth testing when drawing the overhead profile information in the Blenderplayer. This keeps the text from being blocked by geometry in the scene.
2012-10-08 01:25:21 +00:00
Mitchell Stokes
9fcb7cd520
BGE: When applying movement to an object with the Character physics type, use the btKinematicCharacterController's setWalkDirection() instead of moving the physics object ourselves. This reduces issues with tunneling (the character going through other objects).
2012-10-07 19:10:03 +00:00
Campbell Barton
aedf450746
code cleanup: use checks for empty rather then size in the BGE
2012-10-07 12:28:19 +00:00
Mitchell Stokes
7beff06950
BGE: Committing patch [ #31442 ] "API improvements: Group references python api, for better control over groups and instances" by Martin Sell (moerdn). This patch adds a member and a group property to KX_GameObject:
...
* KX_GameObject.member returns the list of group members if the object is a group object, otherwise None is returned
* KX_GameObject.group returns the group object that the object belongs to or None if the object is not part of a group
2012-10-07 00:09:02 +00:00
Campbell Barton
dc8340fa33
correct some include dirs not being included as SYSTEM paths in cmake.
2012-10-02 03:18:48 +00:00
Campbell Barton
aa49ca25d5
incorrect spelling in comments
2012-09-26 20:05:38 +00:00
Campbell Barton
d08abbee69
add back game engine python api slicing, (was missing / regression, since move to py3x)
...
not many people must have used it since it would crash with non-zero start slice values.
2012-09-25 23:28:15 +00:00