Commit Graph

36209 Commits

Author SHA1 Message Date
Campbell Barton
b27854bd47 use booleans for bmesh api. 2013-01-14 16:42:43 +00:00
Brecht Van Lommel
d0621c1dae Fix #33863: cycles viewport render crash entering edit mode on an object with
a subsurf modifier.
2013-01-14 16:05:47 +00:00
Sergey Sharybin
5781859753 Dosvidanya, old compositor!
You served well and now desired retirement, but you'll always live in our hearts.

And for sure -- monument!

       +-------------------------------------------+
      /   ++==+   .  ..   .   ...    .  ..     .  /
     /   //    ++==++  ++  ++     ++==++ ++==++  /
    /   //    //  //  //\\//\\   //  // //  //  /
   /   ++==+ ++==++  //      \\ //==++ ++==++  /
  /  .    ...   ..    .       //  ..  ...     /
 +-------------------------------------------+

Some notes:
- Removed all code which was from inside ifdef WITH_COMPOSITOR_LEGACY
- Removed some functions which were used by old compositor only but
  weren't ported to new color management
- Removed WITH_COMPOSITOR_LEGACY from build systems
- node_composite_util.h was in fatc used by compo nodes specification
  files, so added it back to cmake.

  Could be cleaned up by moving header files to files where they're
  actually needed but would consider this is a separate task.

- Should be no functional changes!
2013-01-14 15:53:17 +00:00
Brecht Van Lommel
9e612235e2 Fix cycles hair in a dupligroup not showing in the correct location for viewport
rendering.
2013-01-14 13:05:01 +00:00
Campbell Barton
fae67b6fb3 fix own bug, edge crease and bevel weights lost on undo. 2013-01-14 12:14:08 +00:00
Campbell Barton
ba78e3e312 no need to call BLI_countlist on idproperty groups when comparing. 2013-01-14 12:02:10 +00:00
Campbell Barton
3475f5137a fix fox AddonPreferences not getting registered automatically and leak when removing the addon (wasnt freeing ID-props). 2013-01-14 10:36:43 +00:00
Campbell Barton
9f2e845181 code cleanup: use BMW_begin insode for loops body. 2013-01-14 09:53:56 +00:00
Campbell Barton
d476113c05 fix [#33847] Ctrl+L doesnt works in edge selection mode
own bug caused be changes to selection flushing.
2013-01-14 08:32:02 +00:00
Campbell Barton
e0388a881b fix for own error with unwrap selection checking uvedit_have_selection() failed with no UV layer.
also add some safety checks for BM_ELEM_CD_GET_* macros.
2013-01-14 08:02:06 +00:00
Campbell Barton
b3f52205f2 draw vector icons using the the scaled width,height. The buttons window context arrow wasn't scaling with the DPI. 2013-01-13 18:21:47 +00:00
Campbell Barton
023e7f489c fix for building with cycles. 2013-01-13 16:42:02 +00:00
Campbell Barton
4f2a65d34c remove TRANSFORM_OT_snap_type, use WM_OT_context_menu_enum instead.
add Ctrl+Shift+Tab shortcut for selecting snap type to the UV editor too.

also added icon drawing to WM_OT_context_menu_enum() so it gets the icons from the enum to draw them in the menu.
2013-01-13 16:18:35 +00:00
Antony Riakiotakis
4f938bbbfe Add terminate call for crash handler for windows. Also add inactive code
to do backtrace flushing. This code will need DbgHelp.lib which we may
want to only include for debug builds if at all.
2013-01-13 15:01:34 +00:00
Bastien Montagne
f561fb5e7a Stupid keyboard should know what coders want to type ! (i.e. another typo fix in UI messages :p ) 2013-01-13 14:52:31 +00:00
Campbell Barton
14925a8e51 optimization for calcNonProportionalEdgeSlide(), avoid matrix multiply for each vertex. 2013-01-13 14:49:04 +00:00
Campbell Barton
587b91be4a transform feature - G-key during transform toggles slide (edge slide or vertex slide), similar to how trackbacll rotate toggles. 2013-01-13 14:22:37 +00:00
Campbell Barton
af5d994b15 add new vertex slide transform operator, different from the existing vertex slide tool based on user feedback.
- no 2-step select edge, then slide.  Instead you can slide and select the edge at the same time.
- ability to slide multiple verts at one.

supports proportional option for vertex slide and flipping, both matching edge slide functionality.
2013-01-13 14:08:53 +00:00
Ton Roosendaal
ef5a41a89d Three fixes;
- Previous commit had a line of code of WIP project in it... tss

- Packed Library data was not freed

- Removed recent (post 2.65a) code to exclude packed data from Undo system.
  It's internal data thats part of file spec, errors happen for example on
  restoring quit.blend or temp saves.
2013-01-13 12:25:56 +00:00
Ton Roosendaal
6e990de9b0 Usability:
Using Proxy Armature on groups: an Undo now doesn't force a complete re-evalution
of this system anymore, so posing works similar as for regular (non linked)
armatures - an undo step goes back to the previous pose.

Before, an undo made the entire armature go to rest pose. Bad bad :)

I need animators to carefully check - report back if there's other issues!
Tested on Gilga character from Tube Open Movie.
2013-01-13 11:31:01 +00:00
Bastien Montagne
61b9f39fc7 Even though we want to get rid of this legacy compo soon, code should compile as long as it is here! :) 2013-01-13 08:38:14 +00:00
Campbell Barton
80f0bfe483 code cleanup: rename transform Slide operations to EdgeSlide. 2013-01-13 05:19:47 +00:00
Campbell Barton
06dd4fa40c bge track-to actuator: reverse the order of the cross product rather then negating. 2013-01-13 03:48:48 +00:00
Mitchell Stokes
1e5ea3e5c4 BGE: Fix from HG1 for bug [#32831] "TrackTo aktuator +X direction not working correct" reported by HG1.
Looks like a vector needed to be inverted for the +X calculation.
2013-01-12 23:48:40 +00:00
Campbell Barton
c045cf2c0d fix [#33846] Points of Curves in Vector Curves node can't have negative X or Y values/. 2013-01-12 20:19:58 +00:00
Mitchell Stokes
4bd3477e29 BGE: Adding preliminary alpha shadow support for Simple shadow maps. They do not work in the viewport nor do they work for Variance shadow maps. 2013-01-12 20:01:58 +00:00
Campbell Barton
3225131223 speedup for EDBM_uv_vert_map_create(), reduce customdata lookups. also remove redundant check for hidden faces. 2013-01-12 20:01:09 +00:00
Campbell Barton
460bb787e2 minor speedup for construct_param_handle_subsurfed() break out of texface_from_original_index() early and dont get the offset for each vertex. 2013-01-12 19:46:27 +00:00
Campbell Barton
889a940cef reduce customdata lookups for UV drawing and tools. 2013-01-12 19:39:03 +00:00
Campbell Barton
9c003a36d6 patch from Harley Acheson to remove multiple inline defines. 2013-01-12 17:12:48 +00:00
Ton Roosendaal
fa759d8ffd Mac HiDPI ("retina") handling:
OK - so you have this nice crisp screen, and still you want to add extra 
monitors to the laptop! That means Blender should switch back and forth to HiDPI 
modes, when you move a window to another monitor.

This code makes the pixelsize scale factor a window property, and handles
an event when a window moves to another monitor. It then changes the
native pixelsize nicely and refreshes entire UI.

You can also have one Blender window on high, and other on low resolution.

Stretching a Blender window from 1 monitor to the other works too, but that
is Apple magic handling it.
2013-01-12 17:07:49 +00:00
Campbell Barton
47ee5f56b6 minor cleanup to debug drawing code in the BGE, dont convert strings to STR_String, only to get them back as regular strings. 2013-01-12 16:49:37 +00:00
Campbell Barton
68d83f4140 quiet compiler warning with string formatting in CParser::Term 2013-01-12 15:32:05 +00:00
Campbell Barton
c93e127e7a code cleanup: style and replace (float)sin, (float)cos with sinf, cosf 2013-01-12 14:28:23 +00:00
Sergey Sharybin
aab01c86cf Patch #33837: ffmpeg1.1 and libav9.1 compatibility update
Patch makes it possible to compile blender with recent ffmpeg
and libav libraries, mainly by getting rid of deprecated API.

Original patch by Campbell Barton with own modifications to
support compilation with older ffmpeg versions.

This patch could break compatibility of FFV1 videos playing
back in older players, mainly because of alpha support changes.
Preserving compatibility with such players became a headache
and think it's high time to get rid of workarounds here.
2013-01-12 12:51:10 +00:00
Ton Roosendaal
497e6bfff9 Bug fix #33842
Old bug:

Image Editor, Generated Image, use "Replace" operator failed, was mising correct
signal to handle type change to "From File".
2013-01-12 12:46:25 +00:00
Ton Roosendaal
129fb516f4 Security fix:
"Pack Blender Libraries" now first does a check if the .blend files are all used
with relative paths. This to prevent bad things happen on unpacking.
2013-01-12 11:59:22 +00:00
Ton Roosendaal
7db00f0826 Usability:
Ancient annoying thing for zooming in 2d views: when a view was restricted to keep
aspect ratio, it only allowed vertical or horizontal MMB-drag zooms, depending 
portrait or landscape size of editors. Same for trackpad and magic mouse.

Now vertical zoom drag always works for editors like buttons, nodes.
2013-01-12 11:00:27 +00:00
Sergey Sharybin
7a90af7b5a Packed and generated images support for Cycles
This commit adds support of packed and generated images
for Cycles when using SVM backend. Movies are still not
supported. This changes also doesn't touch OSL which is
much less trivial to adopt for any images which are not
saved to disk.

Implementation details:

- When adding images to Image Manager is now possible
  to mark image as builtin. Builtin images will bypass
  OIIO loader and will use special loading callbacks.

- Callbacks are set by Blender Session and they're
  using C++ RNA interface to obtain needed data (pixels,
  dimensions, is_float flag).

- Image Manager assumes file path is used as reference
  to a builtin images, but in fact currently image
  datablock name is used for reference. This makes it
  easy to find an image in BlendData database.

- Added some extra properties to Image RNA:
  * channels, which denotes actual number of channels
    in ImBuf. This is needed to treat image's pixels
    correct (before it wasn't possible because API
    used internal number of channels for pixels which
    is in fact doesn't correlate with image depth)
  * is_float, which is truth if image is stored in
    float buffer of ImBuf.

- Implemented string lookup for C++ RNA collections
  for cases there's no manual lookup function.

OSL is not supported because it used own image loading
and filtering routines and there's seems to be no API
to feed pre-loaded pixels directly to the library.

Think we'll either need to add some API to support
such kind of feeding or consider OSL does not have
support of packed images at all.

Movies are not supported at this moment because of lack
of RNA API to load specified frame. It's not difficult
to solve, just need to consider what to best here:
* Either write some general python interface for ImBuf
  and use it via C++ API, or
* Write a PY API function which will return pixels for
  given frame, or
* Use bad-level BKE_* call

Anyway, small steps, further improvements later.

Reviewed by Brecht, thanks!
2013-01-12 10:59:13 +00:00
Campbell Barton
5e6917a18e patch [#33738] Extend Selection option unified and added to few operators
from Sebastian Nell (codemanx), with minor edits
2013-01-12 10:48:10 +00:00
Campbell Barton
45c453c9b1 replace inline with BLI_INLINE define. 2013-01-12 10:39:09 +00:00
Mitchell Stokes
03df7e9a56 BGE: Fix for [#33839] "a logic.joysticks Crashes BGE" reported by Josiah Lane (solarlune).
On a scene change the SCA_JoystickManager gets destroyed which in turn means all of it's joystick instances are released. Since SCA_PythonJoystick was just using a borrowed reference, this allowed the joystick to be freed. Now the joystick's refcount is incremented so that the SCA_PythonJoystick's joystick reference will survive across scene changes.
2013-01-12 05:44:08 +00:00
Ton Roosendaal
2f4cc3530d Bug fix #33826
Post 2.65a issue

Now scrollbars appear/disappear correctly, a bug in checking if mouse clicks
where on panel headers popped up. That disabled using scrollers next to a
panel header.
2013-01-11 15:19:47 +00:00
Howard Trickey
d1d3384750 Fix knife angle constraint bug #33813 by changing knife mvals to floats.
The problem was that by snapping the integer mouse values to
lines through the previous point, the angle was slightly off.
2013-01-11 14:13:22 +00:00
Campbell Barton
f68e9db583 add padding for node view-all, view-home operators. 2013-01-11 04:34:15 +00:00
Campbell Barton
a4d5ef8c7d fix for bpy.props string get-length callback, PyUnicode_GetLength() isn't a measure of the buffer size. 2013-01-11 04:09:54 +00:00
Campbell Barton
d0569dd68e win32 has no kill, force crash for now, perhaps windows devs can do this more correctly. 2013-01-11 03:26:49 +00:00
Campbell Barton
4d7583b66f code cleanup: warnings, also add check in crash handler that a wmWindowManager is present. 2013-01-11 03:21:24 +00:00
Campbell Barton
65497a25ba fix for error in gradient theme rgba_char_args_set() use, was setting char's to float values. 2013-01-11 03:19:52 +00:00
Alex Fraser
17c428d4df Changing units of stiffness parameter in classical (new) SPH solver: used to be speed of sound squared; now just speed of sound.
The classical SPH solver was not in 2.65, so this change is unlikely to affect many users. But beta users who have been trying it out will need to change the stiffness parameter to sqrt(old value).
2013-01-11 03:06:10 +00:00