Commit Graph

37889 Commits

Author SHA1 Message Date
Sergey Sharybin
845aea6864 Clip editor prefetch changes
Made it an operator instead of automatic prefetching.
Filling the whole memory with frames is not always
desired behavior.

Now prefetching is available via P-key, or from Clip
panel in toolbox or from Clip menu.

Also enabled prefetching for non-proxied movies.
2013-04-04 09:50:38 +00:00
Campbell Barton
ef1af9f9c4 fix [#34802] Individual Transformation Confusing in Edit Mode
Individual transformation now works in editmode mesh faces/edge, armature bones and metaballs.
2013-04-04 09:20:46 +00:00
Campbell Barton
82636ab0fb improved method of getting the tangent axis from a bmesh triangle,
rather then getting the longest edge, get the edge which which is most different from the 2 others ends up giving more useful results: for an isosceles triangle it returns the base weather its longer or shorter then the other sides.
2013-04-04 08:47:07 +00:00
Campbell Barton
66aed41d75 fix [#34860] View in Weight Painting mode no longer rotates around active bone 2013-04-04 04:26:13 +00:00
Campbell Barton
2804caff4c code cleanup: use bools, (float)sin/(float)cos -> sinf/cosf, more meaningful var names. 2013-04-04 04:22:38 +00:00
Mitchell Stokes
966e86cd2d Fix for [#34754] "Revision 55527 provokes glitchy GLSL shadow map rendering" reported by Alain Ducharme. Per material uniforms and per object uniforms are now better separated. 2013-04-04 03:55:43 +00:00
Campbell Barton
7bbaf4853a code cleanup: use bools in UI and WM code, quiet some shadow warnings, remove unused function uiEmboss() 2013-04-04 02:05:11 +00:00
Brecht Van Lommel
47fffc86bc Fix #34625: duplivert/face rendering with modifier could crash accessing UV and
generated coordinates on the original mesh, after the change that made duplis
take modifiers into account.
2013-04-03 20:10:08 +00:00
Sergey Sharybin
e6a16e585c Apparently zoom in clip editor was broken
Also silenced some warnings in glutil.
2013-04-03 16:21:14 +00:00
Sergey Sharybin
9c49e71216 Bunch of fixes for GLSL display transform
- GLSL shader wasn't aware of alpha predivide option,
  always assuming alpha is straight. Gave wrong results
  when displaying transparent float buffers.

- GLSL display wasn't aware of float buffers with number
  of channels different from 4, crashing when trying to
  display image with different number of channels.

  This required a bit larger changes, namely now it's
  possible to pass format (GL_RGB, GL_RGBAm GL_LUMINANCE)
  to glaDrawPixelsTex, This also implied adding format to
  glaDrawPixelsAuto and modifying all places where this
  functions are called.

  Now GLSL will handle both 3 and 4 channels buffers,
  single channel images are handled by CPU.

- Replaced hack for render result displaying with a bit
  different hack.

  Namely CPU conversion will happen only during render,
  once render is done GLSL would be used for displaying
  render result on a screen.

  This is so because of the way renderer updates parts
  of the image -- it happens without respect to active
  render layer in image user. This is harmless because
  only display buffer is modifying, but this is tricky
  because we don't have original buffer opened during
  rendering.

  One more related fix here was about when rendering
  multiple layers, wrong image would be displaying when
  rendering is done. Added a signal to invalidate
  display buffer once rendering is done (only happens
  when using multiple layers). This solves issue with
  wrong buffer stuck on the display when using regular
  CPU display space transform and if GLSL is available
  it'll make image displayed with a GLSL shader.

- As an additional change, byte buffers now also uses
  GLSL display transform.

  So now only dutehr and RGB curves are stoppers for
  using GLSL for all kind of display transforms.
2013-04-03 15:59:54 +00:00
Campbell Barton
03b07a719f code cleanup: unused functions 2013-04-03 15:04:24 +00:00
Brecht Van Lommel
13ec0cd6c3 Fix #34856: crash passing an object rather than a mesh to bpy.data.mesh.remove(),
this should give an error message but it didn't.
2013-04-03 13:43:12 +00:00
Lukas Toenne
07677e836f Fix for old compatibility issue: 2.59.2 do_versions was not handling all local node trees (world and lamp missing). 2013-04-03 11:36:48 +00:00
Campbell Barton
d407aeecc7 code cleanup: use more (blender) conventional naming for group functions.
also change dump_rna2xml.py to dump bpy.data by default.
2013-04-03 11:28:42 +00:00
Campbell Barton
efa4c5be4b new ruler option to be able to interactively measure surface thichness as you drag the ruler about.
Request from Bart Veldhuizen.

Access with Shift+Drag
2013-04-03 10:45:13 +00:00
Campbell Barton
9a901691ee pass snap arguments so the ruler doesn't have to temp overwrite scene vars.
also expose snapObjectsRayEx() for more convenient ray-casting about the scene.
2013-04-03 09:48:21 +00:00
Lukas Toenne
bb4ab6a007 Fix #33628, Segmentation fault after pasting a closed group of nodes into an open group. Finally now there is a proper check for pasting nodes into groups. It uses the poll_instance callback of node types to determine if a node can be added into a specific node tree. Currently this is only implemented for group nodes and does a recursive check to avoid pasting a node group into itself (on any level, also nested groups). 2013-04-03 09:10:29 +00:00
Sergey Sharybin
bfeef2f5f0 Fix/Workaround #34854: render buffer update writes to wrong layer
Was caused by recent change in image_buffer_rect_update which
was writing data to ibuf-rect_float. Apparently, this buffer
could point to different render layer than came from RenderResult.

Made quick fix for this, which ends up in skipping float buffer
update in image_buffer_rect_update and skipping GLSL when image
has both byte and float buffers.

This will bring speed down a bit, but slower blender is better
than broken blender.

Proper fix will arrive later this week.
2013-04-03 09:08:02 +00:00
Lukas Toenne
9512ae1a4a Fix #34838, Can not append mesh from 2.5 (Crash in Nodes). The compatibility code for node group socket indices was assuming the new group node types even for 2.56.2 files, before these node groups had actually been converted ... Needs to use old way of identifying node group links (fromnode/tonode == NULL) instead of input/output node types. 2013-04-03 08:25:29 +00:00
Lukas Toenne
3092b24ef2 Fix for missing integer 'type' of the virtual extension socket in group nodes. This could lead to crash in node groups when trying to undefined stack values of the extension socket. type just needs to be set to SOCK_CUSTOM==-1, so the BI execution knows not to look for a stack entry. 2013-04-03 07:56:36 +00:00
Dan Eicher
de0b017127 Cleanup outliner_dropzone code
* deduplicated a bunch of code and moved it into outliner_dropzone_find()
 * moved all the per-dropzone checks into the poll functions
 * one functional change, disable drop parenting on self & self->parent

The basic assumption: if poll() == true then outliner_dropzone_find() will return a valid TreeElement
2013-04-03 07:42:56 +00:00
Campbell Barton
beb4d385bb use floats for transform snapping distance comparisons 2013-04-03 07:36:37 +00:00
Campbell Barton
fc3c13c309 fix [#34825] Transparent background of Empty Images clips objects behind them away when Empty is not selected
allow 'Transparency' option to be used on empty-images.
2013-04-03 05:16:15 +00:00
Campbell Barton
6ee5b2d40c fix [#34850] "x" to clear ID prop fields is too close to the right border 2013-04-03 05:02:33 +00:00
Campbell Barton
a5bd9cbb93 fix [#34847] Box selecting shape keys of a mask causes crash 2013-04-03 03:25:26 +00:00
Campbell Barton
ff7b353ce6 style cleanup 2013-04-03 01:36:00 +00:00
Campbell Barton
6a47f756a6 remove workaround for [#34346], checked on applying this workaround for armatures too but it happens in more cases then I originally thought.
for now users of opensource Nouveau and ATI drivers can't use multiple windows, the bug needs to be fixed in the driver.
2013-04-03 01:35:24 +00:00
Brecht Van Lommel
498983a9a4 Fix #34759: cycles texture influence for particles not shown correct when switching
to a different texture slot.
2013-04-02 18:19:37 +00:00
Brecht Van Lommel
902eb76f49 Fix #34849: crash in operator search menu, due to brush stencil poll
function not checking NULL pointer.
2013-04-02 18:19:35 +00:00
Sergey Sharybin
ed792b5de0 Box and Ellipse mask nodes will now output shape
even if nothing is attached to input.

They'll use black image with render resolution
as a background if nothing is attached to mask input.

Was a request from 4K ToS project.
2013-04-02 17:56:41 +00:00
Brecht Van Lommel
f7efb51054 Fix #34803: blender internal SSS rendering black/nan with negative texture colors. 2013-04-02 17:49:31 +00:00
Sergey Sharybin
c4780c233e Fix for potential missing draw-update when building without OCIO 2013-04-02 17:39:34 +00:00
Sergey Sharybin
752ad1bc37 More usage of GLSL for color managed image drawing
Uses GLSL for drawing image in Image Editor space.

This requires change in image_buffer_rect_update, so
original float buffer is being updated as well. This
is unlikely be something bad, but will keep an eye
on this change.

Also no byte buffer allocation happens there, this
is so because byte buffer used for display only
and in case of GLSL display such allocation and
partial update is just waste of time.

Also switched OpenGL render from using CPU color
space linearization to GLSL color space transform.
Makes OpenGL rendering pretty much faster (but
still slower than in 2.60).

internal changes:

- Added functions to setup GLSL shader for color
  space conversion in colormanagement.c. Currently
  conversion form a colorspace defined by a role to
  linear space is implemented. Easy to extend to
  other cases.

- Added helper functions to glutil.c which does
  smarter image buffer draw (calling all needed OCIO
  stuff, editors now could draw image buffer with a
  single function call -- all the checks are done in
  glutil.c).

- Also added helper function for buffer linearization
  from a given role to glutil.c. Everyone now able to
  linearize buffer with a single call.

  This function will do nothing is GLSL routines fails
  or not supported.

  And one last this: this function uses offscreen
  drawing, could potentially give issues on some
  cards, also will keep an eye on this.
2013-04-02 17:28:37 +00:00
Sergey Sharybin
f871d9a82f Fixes for recent GLSL display space conversions
- Building without OCIO will give correct results again
- If GLSL failed to compile, fallback to glaDrawPixelsAuto
  will happen.
2013-04-02 17:28:29 +00:00
Ton Roosendaal
726dedafbc More Histogram fixes:
Sequencer histogram was calculating still badly, now it uses a per-color
component counter to calculate the levels (instead of counter for all)
2013-04-02 17:12:21 +00:00
Brecht Van Lommel
dc685bc1c3 Fix #34711: matcap option not showing when switching from cycles material/rendered
draw mode to blender internal.
2013-04-02 16:51:23 +00:00
Brecht Van Lommel
0aada35e93 Fix #34788, #34744: GLSL error, #version line needs to be at the top of the shader
and this wasn't the case anymore after recent changes.
2013-04-02 16:37:31 +00:00
Ton Roosendaal
00a1dca612 Removed leftover debug print. 2013-04-02 13:15:12 +00:00
Antony Riakiotakis
dbfadcad61 Fix compilation on MinGW(64/32)
Also, add appropriate lib paths for recent OpenCollada for mingw32 (coming soon to an svn server near you)
2013-04-02 13:07:01 +00:00
Ton Roosendaal
5105ddae74 Missing GLEW path in CMake, fixes compile error in OS X. 2013-04-02 12:54:47 +00:00
Ton Roosendaal
58530a5aff Usability fix, for color grading.
The Scopes and Histogram (Image editor, Sequencer) were not updating on
changes in color or display settings. 

- Missing notifiers for refreshing
- Missing code to draw correct for managed byte buffers.
2013-04-02 12:41:11 +00:00
Ton Roosendaal
a78aa15cd6 Key mapping conflict for 'find node' versus 'add socket link' (noodle).
Historically, F shortcut was for 'add edge/face' in Blender.
In Node editor, F makes a noodle, ctrl+f made a noodle replace too.

To keep ALT+F work for "Unattach from frame", the solution I now propose
is to make CTRL+F for finding nodes, and SHIFT+F for 'add noodle with replace'.
2013-04-02 12:38:05 +00:00
Lukas Toenne
8abfaf880d Fix for #34756 and #34810, crashes when dropping nodes onto noodles and a related forward compatibility bug.
Added a sanity check to the ED_node_link_insert function to ensure it exits gracefully if no suitable sockets can be found. This was the problem with custom pynodes, which don't define the 'type' DNA of old sockets. The operator will have to be generalized for future nodes, but for now just not crashing seems good enough.

Script node crashes in #34810 were caused by uninitialized 'type' integer as well. This is now done in the set_typeinfo function for sockets (like for trees and nodes too), to avoid any potential remaining issues of this kind. Note that new files need to be loaded and saved again once to be forward compatible again.
2013-04-02 11:59:27 +00:00
Campbell Barton
37bf7dd98a draw helper lines for inset and bevel operators, the mouse distance from the selection center was used, but often it was hard to tell where this was and you'd have to guess.
adds ED_region_draw_mouse_line_cb() generic draw callback for mouse helper lines.
2013-04-02 10:48:11 +00:00
Bastien Montagne
932820499a Usual typo fixing... 2013-04-02 07:27:39 +00:00
Joshua Leung
186f0e241e Compile fix: size_t (required by BLI_string.h) was undefined 2013-04-02 03:51:42 +00:00
Brecht Van Lommel
07d027b102 Fix FFMPEG build error with older versions after planar formats commit. 2013-04-01 20:51:52 +00:00
Brecht Van Lommel
de9dffc61e Cycles: initial subsurface multiple scattering support. It's not working as
well as I would like, but it works, just add a subsurface scattering node and
you can use it like any other BSDF.

It is using fully raytraced sampling compatible with progressive rendering
and other more advanced rendering algorithms we might used in the future, and
it uses no extra memory so it's suitable for complex scenes.

Disadvantage is that it can be quite noisy and slow. Two limitations that will
be solved are that it does not work with bump mapping yet, and that the falloff
function used is a simple cubic function, it's not using the real BSSRDF
falloff function yet.

The node has a color input, along with a scattering radius for each RGB color
channel along with an overall scale factor for the radii.

There is also no GPU support yet, will test if I can get that working later.

Node Documentation:
http://wiki.blender.org/index.php/Doc:2.6/Manual/Render/Cycles/Nodes/Shaders#BSSRDF

Implementation notes:
http://wiki.blender.org/index.php/Dev:2.6/Source/Render/Cycles/Subsurface_Scattering
2013-04-01 20:26:52 +00:00
Joerg Mueller
8588fec935 FFMPEG: adding support for ffmpeg planar formats also to writeffmpeg.c. 2013-04-01 15:31:27 +00:00
Ton Roosendaal
c35dec60b5 Node editing feature:
New operator "Find Node".
Opens search menu, and allows to find a node based on name or label.

On selecting name, menu selects/activates the node and moves the view to it.

Shortcut: ALT+F 
Menu: Node editor, "Select"
2013-04-01 15:07:22 +00:00