Commit Graph

47254 Commits

Author SHA1 Message Date
Antony Riakiotakis
b5b359b48f Warning messagebox for windows when an unsupported implementation of
OpenGL is detected:

Hoping to decrease the frequency of by far one of the most frequent bug
reports by windows users.

There is some reorganization of the GHOST API to allow easy addition of
further OpenGL options in the future. The change is not propagated too
deep to keep the size of the patch managable. We might reorganize things
here later.

For OpenGL we do two checks here:
One is a combination of GDI generic renderer or vendor microsoft
corporation and OpenGL version 1.1. This means the system does not
use GPU acceleration at all. We warn user to install a graphics
driver and of cases where this might happen (remote connection, using
blender through virtual machine)

The other one just checks if OpenGL version is less than 1.4 (we can
easily change that in the future of course) and warns that it is
deprecated.

Both cases will still let blender startup correctly but users should now
have a clear idea of the system being unsupported.

A user preference flag is provided to turn the warning off.

Now stop posting those bug reports without installing a driver first -
please?
2015-02-25 13:51:53 +01:00
Campbell Barton
37556d9a9a Fix T43798: Individual origins disabled object PET 2015-02-25 13:41:02 +11:00
Jeroen Bakker
565df1559f T43771: Fix
There is a difference between the socket order of the BokehBlur node and
the BokehBlur operation. Socket[2] and Socket[3] have switched their
order.
2015-02-24 20:28:12 +01:00
Antony Riakiotakis
6ddd2549ed Fix T43535 - weight paint issues
Two issues in this report:

* Shift-F key conflict between painting and selecting mirrored bone
(moved select mirrored to ctrl-shift-F)
* It was possible to display texture overlay in weight painting, even
though the mode does not support textures yet.
2015-02-24 20:12:49 +01:00
Antony Riakiotakis
2dd37614bc Cleanup leftover code from previous commit 2015-02-24 17:28:43 +01:00
Antony Riakiotakis
50e9868abe Fix T43785 crash with border select.
Naming here is slightly misleading. We have:

* Number of elements (objects) that can be picked
* Buffer size
* Number of integers in buffer.

Interestingly enough, bufsize in OpenGL (as far as I could find in
examples on the web) and in most of the code refers to the latter and
actual buffer size is only used whenever we do allocations on the heap.
Added an extra defines here to make things a bit clearer:

* MAXPICKELEMS refers to the number of objects that can be picked
* MAXPICKBUF   refers to the number of integers in the selection buffer

Also made all buffers use MAXPICKBUF where some used MAXPICKBUF * 4.
That means that some parts of blender will use less space for selection
now. MAXPICKBUF is set to 10000 for 2500 object selection, which can be
changed at any time, but I think 10000 integers on the stack touches the
borders of uglyland anyway.
2015-02-24 17:19:07 +01:00
Antony Riakiotakis
340b76b42c Patch D843 by Alexander Romanov, fixes to the naming of the material
node so it's more similar to the names in the material properties
2015-02-24 16:15:46 +01:00
Campbell Barton
831a111353 Fix T43792: Connect faces fails with ngons
Complex ngons that intersected the path multiple times would fail to connect.

Now find closest intersections in both directions.
2015-02-25 00:08:39 +11:00
Campbell Barton
6c96113d5f Modifier: no need to calloc (immediately filled) 2015-02-25 00:08:38 +11:00
Antony Riakiotakis
07c61e9389 Fix T43743 R key not working after recent rake/random source
refactoring.

Use a new menu instead of old enum key.
2015-02-24 11:56:26 +01:00
Sergey Sharybin
77faefb453 Fix T43634: Selecting 'Drop Color' from spacebar menu causes instant close
This is an internal operator, should not be invoked manually.
2015-02-24 14:38:49 +05:00
Campbell Barton
625101da99 RNA: correct enum flag callback
Was returning NULL, auto-completing:

    bpy.types.Material.bl_rna.properties["type"].

Would crash, accessing 'default_flag', thanks to @lukastoenne for investigating.
2015-02-24 19:45:56 +11:00
Sergey Sharybin
4c75f77669 Fix T43784: Compositing scale node border error
This was still the known issue with pixel center, original commit didn't cover all the
cases by the looks of it.

Should be all fine now, but much more intense testing is welcome.
2015-02-24 12:42:31 +05:00
Campbell Barton
1f527c6033 Fix BKE_mesh_validate_arrays, ignored do_fixes 2015-02-24 13:10:15 +11:00
Campbell Barton
cdd14ea96d Cleanup: use bit-shift for bmesh_elem_check 2015-02-24 13:10:15 +11:00
Campbell Barton
4f86f62f32 RNA: use 0/1 for pose layer operator 2015-02-24 07:43:04 +11:00
Sergey Sharybin
225f68c324 Fix interpolation functions ignoring number of components when doing early output 2015-02-24 00:36:33 +05:00
Antony Riakiotakis
2081fd1d7d Gooseberry request:
Show World will now influence if world is rendered in opengl rendering.

This is a little undefined according to blender history, since sky used
to always be drawn when offscreen rendering, as if "Only Render" was
ticked. Since if we don't draw sky in that case there's no valid color
really (and using theme colors is not so nice) we just draw transparent
background.
2015-02-23 18:49:29 +01:00
Antony Riakiotakis
67fcf5256d Move allocation of imbuf from array to allocimbuf.
Skip allocation of temporary imbuf
2015-02-23 17:19:31 +01:00
Dalai Felinto
249f2b9ccf RNA: use 1/0 for move layers operator
internal api Consistency.

For the records, I suspect there are still a few cases of this. I found
this by chance (moving an object to a different layer), and I ran into
the previous one (fixed by Campbell) as well (by adding a cube).

Anyways, since it only happens when building with crash on asserts is
not a big issue. But by the time we change RNA to use bool instead of
int it would be nice to do a call for test to prevent those breaks.
2015-02-23 12:34:15 -03:00
Antony Riakiotakis
9626f4fdf5 GPU module: get rid of gluscaleimage - game engine also uses that but
commit to remove from there will be done separately due to issues with
linking.
2015-02-23 16:33:18 +01:00
Antony Riakiotakis
1940cf5a0b After discussion on irc change new function to only allocate from a
buffer only. scaling can be done separately
2015-02-23 16:30:37 +01:00
Antony Riakiotakis
041f706506 IMB library: Add function that scales an array of byte or float pixels.
Function just wraps the array in an imbuf and does regular imbuf
scaling.
2015-02-23 15:51:30 +01:00
Sergey Sharybin
eacc3debb7 Fix compilation error after recent GPU debug changes 2015-02-23 18:09:28 +05:00
Bastien Montagne
ced19783fd Fix mismatch (missing 'const' to mactch funcs declarations).
Was breaking windows compile, reported by bdancer over IRC, thanks.

Also, quite some annoying 'unused vars' warnings (debug-only vars).
2015-02-23 13:57:02 +01:00
Antony Riakiotakis
fed61d50c7 Debug GPU functionality from soc-viewport_fx by Jason Wilkins
patch number D706 with changes:

- WITH_GPU_DEBUG just creates a debug context (and enables the debug messaging
system functions) but leaves the checks we had intact. Old patch
added the debug functionality only if we had the flag on to save some
performance.

Rationale here is that we might not want to recompile blender just to get
the extra information, and having users start blender with a -d flag to
get the extra information is also useful for bug reports. Those checks already
existed and most expensive ones are hidden behind a debug mode check
so performance should not be that bad.

- Did some cleanup of existing functionality:
When things go wrong blender side, just print the error,
don't check for GL errors first.

- Did not port changes needed for GLES to regular glew.h

- Got rid of duplicate or very similar new functionality.

Generally, code is more moving things around/cleanup and should work exactly
as before apart from the debug context, so it's safe to add even now.

It also provides a nice substitute function for glu error descriptions
2015-02-23 13:35:57 +01:00
Campbell Barton
34479d8b63 Snap to Active: missing armature/pose/mball/curve
de-duplicate active center calc between transform & snap-to-selected.
2015-02-23 23:05:54 +11:00
Campbell Barton
17b8479101 Fix T43774: Snap to Cursor ignores active pivot 2015-02-23 22:26:19 +11:00
Bastien Montagne
ec36e3ae80 Fix T43776: Rigging : Clear User transform is not working when mesh is in weight paint mode.
Use same trick as for regular 'clear transform' operators to get a valid armature
in weight paint mode (where active object is weight-painted one).
2015-02-23 12:23:13 +01:00
Campbell Barton
8ee2b01b04 Fix T43740: 'Back to Previous' failed on reload
Would restore with the file-selector where the 'info' header should be.
2015-02-23 21:33:14 +11:00
Campbell Barton
b497eae0a8 Screen: remove redundant NULL check in ED_area_prevspace 2015-02-23 21:06:55 +11:00
Campbell Barton
86cfbeec6a Partial fix for T43740
ED_area_data_swap would put the screen in an invalid state and crash.
(SpaceLink.spacetype didn't match ScrArea.type)

However behavior is still odd in the instance of the report.
2015-02-23 20:02:54 +11:00
Campbell Barton
96c452bdf6 Fix T43769: Envmap Texture copy looses image 2015-02-23 18:22:09 +11:00
Campbell Barton
7c03ef295b CustomData: const correctness 2015-02-23 16:17:16 +11:00
Campbell Barton
0c4fb47edd BLI_utildefines: correct comment 2015-02-23 16:17:16 +11:00
Campbell Barton
64b328f22b Edge/Vert Slide: avoid redundant loop angle calls
No need to calculate loop angle for each layer
2015-02-23 15:44:28 +11:00
Campbell Barton
bc876f9ea4 Error in last commit
Accidentally left in malloc/free
2015-02-23 15:40:43 +11:00
Campbell Barton
5a372dbd89 Fix error in recent vert/edge-slide commits
`CustomData_bmesh_interp_n` was expecting the 'dest' arg not to have its offset applied.

This was a bit confusing since the source args have it applied,
and in some cases we only have the destination with the offset.
2015-02-23 13:57:06 +11:00
Campbell Barton
50c977b54d CustomData: replace calloc -> malloc
stack array is uninitialized, relying on calloc here would just hide bugs.
2015-02-23 13:57:06 +11:00
Campbell Barton
d580c90469 CustomData: const correctness for interp() 2015-02-23 13:54:33 +11:00
Campbell Barton
c26fa67bcd BLI_utildefines: add pointer offset macro
Handy since it keeps the type of the original.
2015-02-23 13:50:12 +11:00
Campbell Barton
765b842f95 Subsurf: missing NULL checks on free 2015-02-23 08:34:20 +11:00
Julian Eisel
0f1ffd4792 Fix T43768: Pointcache end frame ignores preview range
Fix for T43768

This way it works consistent with cloth, softbodys, etc.

Reviewers: lukastoenne

Differential Revision: https://developer.blender.org/D1134
2015-02-22 17:14:19 +01:00
Sybren A. Stüvel
6d9c99422b Fix T43748: MouseLook actuator raises an Assert error
An assertion seems to be inverted by mistake, as MT_assert(!m_mouse); is followed
by using m_mouse->XXXX.
2015-02-21 14:39:04 +01:00
Joshua Leung
813dcb9feb GPencil: Another fix for the "big square dots" problem
Strokes containing only a single point are now drawn so that they respect the
pressure values too. Previously, they were getting drawn at a fixed size based
on the thickness of strokes. Thanks to @kekeljevic for posting a screenshot which
made the problem here easy to identify!

(On a side note: Perhaps it's a combination of the drivers I'm using, or the
multisampling goodness at work, but after applying this change, the dots are
now appearing as round circles as originally intended, and can also be scaled
up quite a bit too. And that's for 3D points which couldn't be affected like
this earlier! I'm not sure what's going on here, but whatever it is, I like it ;)
2015-02-22 02:09:52 +13:00
Sergey Sharybin
6ec05eb3e6 Code cleanup: Use bools instead of int 2015-02-21 17:50:05 +05:00
Ines Almeida
3445ff0f93 scene conversion: style cleanup 2015-02-21 12:16:21 +00:00
Ines Almeida
4c0adb95dc gamengine: removing useless comment 2015-02-21 12:16:21 +00:00
Ines Almeida
9bfdcc4d32 gameengine: removing addInitFromFrame hack 2015-02-21 12:16:20 +00:00
Ines Almeida
5785df431b gameengine: dataconversion import and whitespace cleanup 2015-02-21 12:16:20 +00:00