Commit Graph

66955 Commits

Author SHA1 Message Date
Campbell Barton
b27e224276 Mesh Convert: remove meaningless modifier check
Meshes w/o modifiers wouldn't have their derived mesh applied.
Check was to avoid crash but its in fact meaningless,
since the modifier might be disabled, or there may be virtual modifiers.
2017-03-17 10:10:55 +11:00
Campbell Barton
750c0dd4de Fix T50950: Converting meshes fails w/ boolean 2017-03-17 09:58:05 +11:00
Campbell Barton
d4d8da28fc Add BKE_blendfile_userdef_read_from_memory
Needed to read user-preferences from in-memory startup.blend

Also skip data-blocks when reading preferences.
2017-03-17 07:01:48 +11:00
Campbell Barton
b2d3956e7b Add support for loading preference struct
Previously it would always load into 'U' global.
Needed for loading & merging template preferences.
2017-03-17 05:20:50 +11:00
Campbell Barton
db04980678 PyAPI: Menu.path_menu: Add path filter callback
Needed if we want to filter based on filenames (not just extension).
2017-03-17 05:20:50 +11:00
Campbell Barton
f7793bd53c Correct reading missing property 2017-03-17 05:20:50 +11:00
Bastien Montagne
1f65ab606b Fix missing undo pushes in outliner's new datablock management operations.
Not sure why I did not put those from start... Actually *not* having an
undo point here can be problematic, since undoing some previous action
was trying to restore from bad pointer (I think) in UI, generating
asserts.

Note however that it's not a 'pure' undo, in that you may not find your
linked data in exact same state as before deleting it, after an undo,
since it actually implies *reloading* the deleted libraries (and not
restoring from a previously stored memory dump).

Reported by @sergey, thanks.
2017-03-16 17:05:48 +01:00
Bastien Montagne
fa9bd04483 Fix outliner contextual menu allowing to delete indirect libraries.
There is no way currently to prevent the option from showing in menu, so
instead report a warning to user (and curse again current nightmarish
system of operation in outliner...).

Reported by @sergey, thanks.
2017-03-16 17:05:48 +01:00
Sergey Sharybin
0434053f13 Depsgraph: Fixed crash with curve bevel indirect dupligroups
Need to expand all object's dupli-groups, not only the dupli-groups
of objects directly linked to the scene.
2017-03-16 15:35:21 +01:00
Sergey Sharybin
68e58f1991 Depsgraph: Use string and vector in the DEG namespace only 2017-03-16 15:35:21 +01:00
Sergey Sharybin
6d8875bd61 Depsgraph: Don't use explicit values in runtime only enum
Lower risk of forgetting to update some values here.
2017-03-16 15:35:21 +01:00
Campbell Barton
c4e07dd29b Cleanup: differentiate startup/prefs in home-file reading 2017-03-17 00:42:13 +11:00
Campbell Barton
aad9dd2f1b Support passing in UserDef for free function
Needed so we can load and free non-global user preferences.
2017-03-17 00:18:20 +11:00
Sergey Sharybin
1cad64900e Cycles: Define ccl_local variables in kernel functions
Declaring ccl_local in a device function is not supported
by certain compilers.
2017-03-16 11:27:17 +01:00
Sergey Sharybin
1ff753baa4 Cycles: Workaround for compilation error caused by passing KernelGlobals
Pass globals as a bare pointer, same as it sued to be prior to split kernel rework.

AMD CPU platform and Intel OpenCL were complaining about this.

Perhaps we shouldn't pass globals as pointer at all, this isn't something what is
really portable and can cause issues on 32 bit perhaps.
2017-03-16 11:27:17 +01:00
Sergey Sharybin
26620f3f87 Cycles: Avoid some ccl_local in various kernels 2017-03-16 11:27:17 +01:00
Mai Lavelle
4833a71621 Cycles: Adjust global size for OpenCL CPU devices to make them faster 2017-03-16 06:11:42 -04:00
Bastien Montagne
d68a84d1d2 Fix BGE building.
When you use typedef'ed enum, you need to define all supported values
explicitely in enum, else compiler goes grumpy...
2017-03-16 10:30:02 +01:00
Campbell Barton
375ede0f3f Comments: wmOperator.cancel & modal 2017-03-16 06:39:09 +11:00
Campbell Barton
68496c0b38 Missed BGE in recent commit 2017-03-16 06:28:20 +11:00
Campbell Barton
c832354e33 Load user-preferences before startup file
Internal change needed for template support.
Loading the user preferences first so it's possible
for preferences to control startup behavior.

In general it's useful to load preferences before data-files,
so we know security settings for eg.
2017-03-16 04:02:24 +11:00
Sergey Sharybin
c44cdd5905 Cycles: Allow rendering a range of resumable chunks
The range is controlled using the following command line arguments:

  --cycles-resumable-start-chunk
  --cycles-resumable-end-chunk

Those are 1-based index of range for rendering.
2017-03-15 16:00:01 +01:00
Sergey Sharybin
c5dba540d7 Cycles: Use argument parser for resumable render feature
Currently there is no functional changes, but we will be adding
couple more of options here soon.
2017-03-15 16:00:01 +01:00
Dalai Felinto
81dc8dd42a Fix bug on Blender version string
Reported by Pablo Vazquez (venomgfx) over irc.
2017-03-15 15:42:01 +01:00
Dalai Felinto
c6c85a8c6b Move Blender version string handling to its own function
Planning to use this util function in 2.8 for doversioning (to communicate converted layers)
2017-03-15 14:10:20 +01:00
Sergey Sharybin
af1d9ecd40 Fix strict compiler warning in the previous commit 2017-03-15 12:48:07 +01:00
Sergey Sharybin
9ad252d157 Fix T50938: Cache not being reset when changing simulation settings with new depsgraph
The thing i'm really starting to hate is the requirement to specify both
operation code and node type. Seems to be duplicated enums without real
need for that.
2017-03-15 11:10:42 +01:00
Porteries Tristan
6a5487e021 BGE: Fix blenderplayer stub.
Add dummy definition of WM_operator_is_repeat.
2017-03-14 21:17:40 +00:00
Campbell Barton
f13c729b26 WM: free operators when repeating
Needed since the active operator isn't ensured to be the last.
2017-03-15 05:37:42 +11:00
Gaia Clary
647fb6ef1e fix D2552: Collada - Follow up change to complete the fix in rBda6cd7762810 (use unique id for bones with same name in different armatures) 2017-03-14 19:31:25 +01:00
Gaia Clary
4877c9362a Collada simplify: avoid duplicate negation in boolean 2017-03-14 19:31:25 +01:00
Campbell Barton
76ec329dd1 WM: add Operator.is_repeat() check for C & Py
This addresses an issue raised by D2453 -
that there was no way to check if operators are run
multiple times in a row.

Actions are still ignored that don't cause an UNDO event.
2017-03-15 03:57:01 +11:00
Campbell Barton
1208792adb WM: store operators with undo flag
This is needed so we can tell if operators are executed repeatedly.
2017-03-15 03:57:01 +11:00
Campbell Barton
582f9ddeb7 Update path_menu for recent API change 2017-03-15 03:57:01 +11:00
Sergey Sharybin
5ba51de84a Cycles: Cleanup, indentation 2017-03-14 16:54:16 +01:00
Bastien Montagne
43f7d5643f Fix T50926: python crashes with path containing utf8 characters.
Default text encoding is platform-dependent in python, and windows
usually do not use utf-8 as default...
2017-03-14 16:04:45 +01:00
Jon Allee
da6cd77628 fix D2552: Collada - use unique id for bones with same name but in different armatures. Co-authored-by: Gaia <gaia.clary@machiniamtrix.org> 2017-03-14 14:35:51 +01:00
Bastien Montagne
f3ff03b3c1 CLNor: rework threaded computation.
Was using some threaded queue on top of task pool, tssk...

Now using properly task pool directly to crunch chunks of smooth fans.

No noticable changes in speed.

Tried to completely get rid of the 'no threading with few loops' code,
but even just creating/freeing the task pool, without actually pushing
any task, is enough to make code 50% slower in worst case scenario (i.e.
few thousands of simple cube objects).
2017-03-14 12:54:57 +01:00
Bastien Montagne
284701e371 CLNor code: use averaged debug timing. 2017-03-14 12:54:57 +01:00
Bastien Montagne
1410ea0478 Fix T50876: Cycles Crash - Cycles crashes before sampling when certain meshes have autosmooth enabled.
The root of the issue was in custom normal code, so far it assumed that
we could only have one cyclic smooth fan around each vertex, which is...
blatantly wrong (again, the two cones sharing same vertex tip e.g.).

This required a rather deep change in how smooth fans/clnor spaces are processed,
took me some time to find a 'good' solution.

Note that new code is slightly slower than previous one (maybe about 5%),
not much to be done here, am afraid.

Tested against all older report files I could find, seems OK.
2017-03-14 12:54:57 +01:00
Bastien Montagne
521133682c Fix own mistake in recent 'edge split' refactor.
We do can have some vertices to split, while not having any edge (think
about two cones sharing the same tip vertex e.g.).
2017-03-14 12:54:57 +01:00
Mai Lavelle
8dd0355c21 Cycles: Try to avoid infinite loops by catching invalid ray states 2017-03-14 06:22:57 -04:00
Campbell Barton
0ee1cdab7e WM: Option to load startup w/o closing the splash
Not user visible, needed for switching templates.
2017-03-14 21:05:00 +11:00
Campbell Barton
4c5374d46a PyAPI: extend Menu.path_menu
- Add optional 'display_name' callback
  so callers can construct own names.
- Add optional 'prop_filepath' argument
  (for operators that don't use "filepath").
- Add doc-string.
- Use keyword only arguments.
2017-03-14 21:00:55 +11:00
Campbell Barton
810982a95c Fix T50932: depth picking w/ pose-bone constraints 2017-03-14 18:02:27 +11:00
Sergey Sharybin
76acaefdd7 Cycles: Cleanup, wipe obviously outdated parts of split kernel comments 2017-03-13 17:16:16 +01:00
lazydodo
0c72008592 fix msvc warnings about unknown opencl pragmas 2017-03-13 10:08:14 -06:00
Sergey Sharybin
aa36c73c33 Cycles: Add missing header in the file 2017-03-13 16:59:09 +01:00
Germano Cavalcante
2b3cc24388 Fix T50920: Adds missing edges on return of bisect operator 2017-03-13 09:22:11 -03:00
Hristo Gueorguiev
f169ff8b88 Fix T50925: Add AO approximation to split kernel 2017-03-13 11:15:58 +01:00