Code here is a bit weird/simpler than GPU_draw, but we can reuse the API
here, albeit with a few restrictions (no high resolution, custom
filtering mode - which will probably get lost next time blender reloads
textures)
Two areas of the BGE use a hard-coded 60 Hz as frame rate. However, this 60 Hz is just a default setting, and can be changed in the Blender interface.
This setting is now used instead of the hard-coded 60 Hz.
CcdPhysicsEnvironment::SetFixedTimeStep() is actually never called, as we don't even support a true fixed-timestep simulation.
This patch would reassign the relative of all keyblocks to the relative
of the deleted keyblock. And it fixes the misalignement of the index values
after the keyblock is deleted.
Reviewers: campbellbarton
Differential Revision: https://developer.blender.org/D1176
When the multisegment profile joins two unbeveled edges, all in the same
plane, users desire that rather than the current behavior of linear
interpolation between those edges, the profile should curve.
This changes behavior to do that. The old behavior can be obtained
by setting the profile parameter to 0.25, if desired.
Added Shift + Tab for Snap and Ctrl + Shift + Tab for Snap Element Menu (consistent to
3D View)
NOTE: Exit Group is now Ctrl + Tab instead of Shift + Tab
I noticed our version code and subversion got out of sync in the past, maybe
that's what the issue was here.
Deleting the entries from the .xml makes it fall back to the default values.
Added a new "current_lod_level" property to the python api of
KX_GameObject. The property returns the current lod level of the game
object. The purpose of the property is activate logic routines only when
an object is at a certain lod-distance from the camera, avoiding to
separately recomputing the same distance in the logic script. Usage in
python script might look like:
owner = bge.logic.getCurrentController().owner
lod_level = owner.currentLodLevel
if lod_level == 0: ...do something
else: ... object might be too distant
Reviewers: dfelinto, kupoman, moguri
Reviewed By: kupoman, moguri
Subscribers: lordloki
Projects: #game_engine
Differential Revision: https://developer.blender.org/D978
overlay scene
GetGameObjectType is overwritten in KX_FontObject to differentiate a
font object into AddNodeReplicaObject function. Now, in this function,
we add fonts in the appropriate list.
Reviewers: campbellbarton, moguri, dfelinto, lordloki
Reviewed By: lordloki
Subscribers: lordloki
Projects: #game_logic, #game_engine
Differential Revision: https://developer.blender.org/D1130
The idea is pretty simple: instead of making temporary copy of all the
related custom data layers just pass the ownership from the DM to the
mesh.
This is really handy in cases when you've got DM which you need to
convert to Mesh datablock and wouldn't need that DM after conversion
anyway.
Foe example, render database conversion, exporters and even Modifier
Apply will benefit from this option.
Reviewers: campbellbarton
Differential Revision: https://developer.blender.org/D1127
The purpose of this change is to add extra possibility to render engines and
export scripts to reduce peak memory footprint during their operation.
This new argument should be used with care since it'll leave mesh in not really
compatible with blender format, but it's ok to be used on temp meshes.
Unfortunately, it's hard to get scene where it'll show huge benefit because
in my tests with cycles peak memory is reached in MEM_printmemlist_stats().
However, in the file with sintel dragon it gives around 1gig of memory benefit
after removing the polys which would allow other heavy to compute stuff such as
hair (or even pointiness calculation) to not be a peak memory usage.
In any case, this change is nice to have IMO, and only means more parts of
scene export code should be optimized memory-wise.
Reviewers: campbellbarton
Differential Revision: https://developer.blender.org/D1125
Issue this commit is addressed to is that particle system and particle modifier
will contain caches once derived mesh was requested and this cached data will
never be freed.
This could easily lead to unwanted memory peaks during synchronization stage
of rendering.
The idea is to have RNA function in object which would free caches which can't
be freed otherwise. This function is not intended to deal with derived final
since it might be used by other objects (for example by object with boolean
modifier).
This cache freeing is only happening in the background rendering and locked
interface rendering.
From quick tests with victor file this change reduces peak memory usage by
command line rendering by around 6% (1780MB vs. 1883MB). For rendering from
the interface it's about 12% (1763MB vs. 1998MB).
Reviewers: campbellbarton, lukastoenne
Differential Revision: https://developer.blender.org/D1121
This commit makes some preliminary fixes and tweaks aimed to make blender
compilable with C++11 feature set. This includes:
- Build system attribute to enable C++11 featureset.
It's for sure default OFF, but easy to enable to have a play around with
it and make sure all the stuff is compilable before we go C++11 for real.
- Changes in Compositor to use non-named cl_int structure fields.
This is because __STRICT_ANSI__ is defined by default by GCC and OpenCL
does not use named fields in this case.
- Changes to TYPE_CHECK() related on lack of typeof() in C++11
This uses decltype() instead with some trickery to make sure returned type
is not a reference.
- Changes for auto_ptr in Freestyle
This actually conditionally switches between auto_ptr and unique_ptr since
auto_ptr is deprecated in C++11. Seems to be not strictly needed but still
nice to be ready for such an update anyway/
This all based on changes form depsgraph_refactor branch apart from the weird
changes which were made in order to support MinGW compilation. Those parts of
change would need to be carefully reviewed again after official move to gcc49
in MinGW.
Tested on Linux with GCC-4.7 and Clang-3.5, other platforms are not tested and
likely needs some more tweaks.
Reviewers: campbellbarton, juicyfruit, mont29, lukastoenne, psy-fi, kjym3
Differential Revision: https://developer.blender.org/D1089
The issue was caused by missing relations between smoke domain and flow/source
objects. This happened because smoke's modifier only iterated base objects and
ignored cases when flow/source could be linked to scene via dupli-group and
does not have real base.
The same seems to be still needed for fluid and dynamic paint modifiers,
will do it as a separate commit.
Reviewers: campbellbarton
Differential Revision: https://developer.blender.org/D1172
Currently, for animated textures we were allowing 16x16 tiles but we can reproduce 128 frames only.
Reviewers: moguri, sergey, campbellbarton
Reviewed By: sergey, campbellbarton
Differential Revision: https://developer.blender.org/D1164
This patch avoids looping over bhead's linked list when looking up values by name.
Used during appaned and library loading.
Gives noticeable overall speedup loading files that used libraries. (nearly 2x on some Mango files)