diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2017-11-15 12:46:19 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2017-11-15 12:46:19 +0300 |
commit | 2a7f8d3cb332055f026cd09933136d6981b585e7 (patch) | |
tree | ae93233578e32570c1f5d47f83dd0b81a9bfefb9 /source | |
parent | 44517c5f2177d1f260ba691fb59fbacfef576915 (diff) | |
parent | 556b13f03e561b54d4f0186e207f080c786f8b66 (diff) |
Merge branch 'master' into blender2.8
Conflicts:
source/blender/blenlib/BLI_math_matrix.h
source/blender/blenlib/intern/math_matrix.c
source/blender/blenlib/intern/rand.c
source/blender/editors/animation/anim_channels_edit.c
source/blender/makesrna/intern/rna_mask.c
Diffstat (limited to 'source')
19 files changed, 50 insertions, 44 deletions
diff --git a/source/blender/alembic/intern/abc_mball.h b/source/blender/alembic/intern/abc_mball.h index 4fdc1d7b882..e657711059e 100644 --- a/source/blender/alembic/intern/abc_mball.h +++ b/source/blender/alembic/intern/abc_mball.h @@ -25,7 +25,7 @@ #include "abc_object.h" -struct AbcMeshWriter; +class AbcMeshWriter; struct Main; struct MetaBall; struct Object; diff --git a/source/blender/blenkernel/intern/bmfont.c b/source/blender/blenkernel/intern/bmfont.c index 79b3f89da20..8018629ef2a 100644 --- a/source/blender/blenkernel/intern/bmfont.c +++ b/source/blender/blenkernel/intern/bmfont.c @@ -52,11 +52,10 @@ #include "MEM_guardedalloc.h" #include "IMB_imbuf_types.h" -#include "BKE_bmfont.h" -#include "BKE_bmfont_types.h" - #include "BLI_utildefines.h" +#include "BKE_bmfont.h" +#include "BKE_bmfont_types.h" #include "BKE_global.h" void printfGlyph(bmGlyph *glyph) diff --git a/source/blender/blenkernel/intern/freestyle.c b/source/blender/blenkernel/intern/freestyle.c index e45a938a4fc..686fe3bda93 100644 --- a/source/blender/blenkernel/intern/freestyle.c +++ b/source/blender/blenkernel/intern/freestyle.c @@ -34,14 +34,14 @@ #include "DNA_freestyle_types.h" #include "DNA_group_types.h" -#include "BKE_freestyle.h" -#include "BKE_library.h" -#include "BKE_linestyle.h" - #include "BLI_blenlib.h" #include "BLI_math.h" #include "BLI_string_utils.h" +#include "BKE_freestyle.h" +#include "BKE_library.h" +#include "BKE_linestyle.h" + // function declarations static FreestyleLineSet *alloc_lineset(void); static void copy_lineset(FreestyleLineSet *new_lineset, FreestyleLineSet *lineset, const int flag); diff --git a/source/blender/blenkernel/intern/outliner_treehash.c b/source/blender/blenkernel/intern/outliner_treehash.c index 3e99dbe37ca..d9a602aa41e 100644 --- a/source/blender/blenkernel/intern/outliner_treehash.c +++ b/source/blender/blenkernel/intern/outliner_treehash.c @@ -29,14 +29,14 @@ #include <stdlib.h> #include <string.h> -#include "BKE_outliner_treehash.h" - #include "BLI_utildefines.h" #include "BLI_ghash.h" #include "BLI_mempool.h" #include "DNA_outliner_types.h" +#include "BKE_outliner_treehash.h" + #include "MEM_guardedalloc.h" typedef struct TseGroup { diff --git a/source/blender/blenlib/BLI_threads.h b/source/blender/blenlib/BLI_threads.h index 0b1b4d8ee8c..60da6b39cbe 100644 --- a/source/blender/blenlib/BLI_threads.h +++ b/source/blender/blenlib/BLI_threads.h @@ -111,8 +111,10 @@ void BLI_mutex_unlock(ThreadMutex *mutex); /* Spin Lock */ -#ifdef __APPLE__ +#if defined(__APPLE__) typedef OSSpinLock SpinLock; +#elif defined(_MSC_VER) +typedef volatile int SpinLock; #else typedef pthread_spinlock_t SpinLock; #endif diff --git a/source/blender/blenlib/intern/rand.c b/source/blender/blenlib/intern/rand.c index 9ab39dda9d0..1a178db1413 100644 --- a/source/blender/blenlib/intern/rand.c +++ b/source/blender/blenlib/intern/rand.c @@ -453,4 +453,4 @@ void BLI_hammersley_2D_sequence(unsigned int n, double *r) r[s * 2 + 0] = (double)(s + 0.5) / (double)n; r[s * 2 + 1] = radical_inverse(s); } -}
\ No newline at end of file +} diff --git a/source/blender/blenlib/intern/threads.c b/source/blender/blenlib/intern/threads.c index abf611d1245..fbb64f3ece2 100644 --- a/source/blender/blenlib/intern/threads.c +++ b/source/blender/blenlib/intern/threads.c @@ -472,8 +472,10 @@ void BLI_mutex_free(ThreadMutex *mutex) void BLI_spin_init(SpinLock *spin) { -#ifdef __APPLE__ +#if defined(__APPLE__) *spin = OS_SPINLOCK_INIT; +#elif defined(_MSC_VER) + *spin = 0; #else pthread_spin_init(spin, 0); #endif @@ -481,8 +483,14 @@ void BLI_spin_init(SpinLock *spin) void BLI_spin_lock(SpinLock *spin) { -#ifdef __APPLE__ +#if defined(__APPLE__) OSSpinLockLock(spin); +#elif defined(_MSC_VER) + while (InterlockedExchangeAcquire(spin, 1)) { + while (*spin) { + /* pass */ + } + } #else pthread_spin_lock(spin); #endif @@ -490,23 +498,24 @@ void BLI_spin_lock(SpinLock *spin) void BLI_spin_unlock(SpinLock *spin) { -#ifdef __APPLE__ +#if defined(__APPLE__) OSSpinLockUnlock(spin); +#elif defined(_MSC_VER) + _ReadWriteBarrier(); + *spin = 0; #else pthread_spin_unlock(spin); #endif } -#ifndef __APPLE__ void BLI_spin_end(SpinLock *spin) { - pthread_spin_destroy(spin); -} +#if defined(__APPLE__) +#elif defined(_MSC_VER) #else -void BLI_spin_end(SpinLock *UNUSED(spin)) -{ -} + pthread_spin_destroy(spin); #endif +} /* Read/Write Mutex Lock */ diff --git a/source/blender/editors/animation/anim_channels_edit.c b/source/blender/editors/animation/anim_channels_edit.c index 580cfaa48c7..80a388408a5 100644 --- a/source/blender/editors/animation/anim_channels_edit.c +++ b/source/blender/editors/animation/anim_channels_edit.c @@ -37,7 +37,6 @@ #include "BLI_blenlib.h" #include "BLI_utildefines.h" #include "BLI_listbase.h" -#include "BKE_library.h" #include "DNA_anim_types.h" #include "DNA_object_types.h" @@ -54,6 +53,7 @@ #include "BKE_fcurve.h" #include "BKE_gpencil.h" #include "BKE_context.h" +#include "BKE_library.h" #include "BKE_mask.h" #include "BKE_global.h" #include "BKE_scene.h" diff --git a/source/blender/editors/object/object_ops.c b/source/blender/editors/object/object_ops.c index 07922f2d3b2..c87df877d5c 100644 --- a/source/blender/editors/object/object_ops.c +++ b/source/blender/editors/object/object_ops.c @@ -378,13 +378,6 @@ void ED_keymap_object(wmKeyConfig *keyconf) kmi = WM_keymap_add_item(keymap, "OBJECT_OT_scale_clear", SKEY, KM_PRESS, KM_ALT, 0); RNA_boolean_set(kmi->ptr, "clear_delta", false); - kmi = WM_keymap_add_item(keymap, "OBJECT_OT_location_clear", GKEY, KM_PRESS, KM_ALT | KM_SHIFT, 0); - RNA_boolean_set(kmi->ptr, "clear_delta", true); - kmi = WM_keymap_add_item(keymap, "OBJECT_OT_rotation_clear", RKEY, KM_PRESS, KM_ALT | KM_SHIFT, 0); - RNA_boolean_set(kmi->ptr, "clear_delta", true); - kmi = WM_keymap_add_item(keymap, "OBJECT_OT_scale_clear", SKEY, KM_PRESS, KM_ALT | KM_SHIFT, 0); - RNA_boolean_set(kmi->ptr, "clear_delta", true); - WM_keymap_verify_item(keymap, "OBJECT_OT_origin_clear", OKEY, KM_PRESS, KM_ALT, 0); kmi = WM_keymap_add_item(keymap, "OBJECT_OT_delete", XKEY, KM_PRESS, 0, 0); diff --git a/source/blender/editors/sculpt_paint/paint_curve.c b/source/blender/editors/sculpt_paint/paint_curve.c index 0ee78d61fb8..337f7a1ef2b 100644 --- a/source/blender/editors/sculpt_paint/paint_curve.c +++ b/source/blender/editors/sculpt_paint/paint_curve.c @@ -33,13 +33,13 @@ #include "DNA_space_types.h" #include "DNA_view3d_types.h" +#include "BLI_math_vector.h" +#include "BLI_string.h" + #include "BKE_context.h" #include "BKE_main.h" #include "BKE_paint.h" -#include "BLI_math_vector.h" -#include "BLI_string.h" - #include "ED_paint.h" #include "ED_view3d.h" diff --git a/source/blender/makesrna/intern/rna_cachefile.c b/source/blender/makesrna/intern/rna_cachefile.c index 0e59c3784bc..c0aa1f2a9f4 100644 --- a/source/blender/makesrna/intern/rna_cachefile.c +++ b/source/blender/makesrna/intern/rna_cachefile.c @@ -34,10 +34,10 @@ #ifdef RNA_RUNTIME -#include "BKE_cachefile.h" - #include "BLI_string.h" +#include "BKE_cachefile.h" + #include "DEG_depsgraph.h" #include "WM_api.h" diff --git a/source/blender/makesrna/intern/rna_mask.c b/source/blender/makesrna/intern/rna_mask.c index 1c7e6fb9587..564232c3dd4 100644 --- a/source/blender/makesrna/intern/rna_mask.c +++ b/source/blender/makesrna/intern/rna_mask.c @@ -52,14 +52,14 @@ #ifdef RNA_RUNTIME +#include "BLI_math.h" + #include "DNA_movieclip_types.h" #include "BKE_mask.h" #include "DEG_depsgraph.h" -#include "BLI_math.h" - #include "RNA_access.h" #include "WM_api.h" diff --git a/source/blender/makesrna/intern/rna_sculpt_paint.c b/source/blender/makesrna/intern/rna_sculpt_paint.c index 0c0cfe24d63..fd2ac7595e2 100644 --- a/source/blender/makesrna/intern/rna_sculpt_paint.c +++ b/source/blender/makesrna/intern/rna_sculpt_paint.c @@ -27,6 +27,8 @@ #include <stdlib.h> +#include "BLI_utildefines.h" + #include "RNA_define.h" #include "RNA_enum_types.h" @@ -46,7 +48,6 @@ #include "WM_api.h" #include "WM_types.h" -#include "BLI_utildefines.h" #include "bmesh.h" static const EnumPropertyItem particle_edit_hair_brush_items[] = { diff --git a/source/blender/makesrna/intern/rna_smoke.c b/source/blender/makesrna/intern/rna_smoke.c index 7c0c5267daf..8c2a09f1186 100644 --- a/source/blender/makesrna/intern/rna_smoke.c +++ b/source/blender/makesrna/intern/rna_smoke.c @@ -29,6 +29,9 @@ #include <stdlib.h> #include <limits.h> +#include "BLI_sys_types.h" +#include "BLI_threads.h" + #include "RNA_define.h" #include "RNA_enum_types.h" @@ -38,8 +41,6 @@ #include "BKE_smoke.h" #include "BKE_pointcache.h" -#include "BLI_threads.h" - #include "DNA_modifier_types.h" #include "DNA_object_force.h" #include "DNA_object_types.h" diff --git a/source/blender/physics/intern/eigen_utils.h b/source/blender/physics/intern/eigen_utils.h index e4a4f306aeb..8a5a9dbf5e9 100644 --- a/source/blender/physics/intern/eigen_utils.h +++ b/source/blender/physics/intern/eigen_utils.h @@ -32,7 +32,7 @@ * \ingroup bph */ -#ifdef __GNUC__ +#if defined(__GNUC__) && !defined(__clang__) # pragma GCC diagnostic push /* XXX suppress verbose warnings in eigen */ # pragma GCC diagnostic ignored "-Wlogical-op" diff --git a/source/blender/physics/intern/implicit_eigen.cpp b/source/blender/physics/intern/implicit_eigen.cpp index ff4c705ed61..afe1b441632 100644 --- a/source/blender/physics/intern/implicit_eigen.cpp +++ b/source/blender/physics/intern/implicit_eigen.cpp @@ -39,7 +39,7 @@ #ifdef __GNUC__ # pragma GCC diagnostic push /* XXX suppress verbose warnings in eigen */ -# pragma GCC diagnostic ignored "-Wlogical-op" +//# pragma GCC diagnostic ignored "-Wlogical-op" #endif #ifndef IMPLICIT_ENABLE_EIGEN_DEBUG diff --git a/source/blender/python/intern/bpy_rna_array.c b/source/blender/python/intern/bpy_rna_array.c index 3e147d29c90..e0ca3634261 100644 --- a/source/blender/python/intern/bpy_rna_array.c +++ b/source/blender/python/intern/bpy_rna_array.c @@ -28,13 +28,14 @@ #include <Python.h> +#include "BLI_utildefines.h" + #include "RNA_types.h" #include "bpy_rna.h" #include "BKE_global.h" -#include "MEM_guardedalloc.h" -#include "BLI_utildefines.h" +#include "MEM_guardedalloc.h" #include "RNA_access.h" diff --git a/source/blender/render/intern/source/render_result.c b/source/blender/render/intern/source/render_result.c index 631503bdad5..9ad5d73fc55 100644 --- a/source/blender/render/intern/source/render_result.c +++ b/source/blender/render/intern/source/render_result.c @@ -36,7 +36,6 @@ #include "MEM_guardedalloc.h" -#include "BKE_appdir.h" #include "BLI_utildefines.h" #include "BLI_listbase.h" #include "BLI_hash_md5.h" @@ -45,6 +44,7 @@ #include "BLI_string.h" #include "BLI_threads.h" +#include "BKE_appdir.h" #include "BKE_image.h" #include "BKE_global.h" #include "BKE_main.h" diff --git a/source/tools b/source/tools -Subproject b11375e89061303401376f7aeae42ac2fd64692 +Subproject 9ea62ef860cde8eb313b74cd1b23ca5a0734eef |