Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
Selection loop would draw the selection ignoring xray.
Now draw in a separate pass after clearing the depth buffer,
as with regular drawing.
Also disable depth sorting,
caller can sort the hit-list by depth if needed.
|
|
Intended to replace legacy GL_SELECT, without the limitations of
sample queries which can't access depth information.
This commit adds VIEW3D_SELECT_PICK_NEAREST and VIEW3D_SELECT_PICK_ALL
which access the depth buffers to detect whats under the pointer,
so initial selection is always the closest item.
The performance of this method depends a lot on the OpenGL
implementations glReadPixels.
Since reading depth can be slow, buffers are cached for object picking
so selecting re-uses depth data, performing 1 draw instead of 3
(for 24, 18, 10 px regions, picking with many items under the pointer).
Occlusion queries draw twice when picking nearest,
so worst case 6x draw calls per selection.
Even with these improvements occlusion queries is faster on AMD hardware.
Depth selection is disabled by default, toggle option under select method.
May enable by default if this works well on different hardware.
Reviewed as D2543
|
|
|
|
|
|
|
|
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D2378
|
|
viewport.
Caused by rBd6cf28c5e15739f864fbf04614c2a50708b4b152, which forgot to
update the GLSL code for the "Light Path" node.
|
|
|
|
|
|
This will make triple buffer used by default for such configuration.
Ideally we would switch to triple buffer on all platforms, but let's
do it in 2.8 branch and don't open can of worms in master now.
This should solve issues like T49945.
|
|
|
|
|
|
This is yet another debug option that allows to render an arbitrary
simulation field by using a color ramp to inspect its voxel values.
Note that when using this, fire rendering is turned off.
Reviewers: plasmasolutions, gottfried
Differential Revision: https://developer.blender.org/D1733
|
|
|
|
|
|
|
|
close D696 by @jwilkins
The matrix mode should always be left in modelview mode, since a lot of code assumes it is before setting a matrix.
|
|
|
|
Material viewport mode
|
|
transparency.
The issue is that we are rendering to a 0..1 clamped sRGB buffer with
unpremultiplied alpha, where the correct thing to do would be to render
to an unclamped linear premultiplied alpha buffer. Then we would just
make fire purely emissive without affecting the alpha channel at all,
but that doesn't work here.
So for now, draw fire and smoke separately using different shaders and
blend modes, like it used to before the smoke programs were rewritten
(see rB0372b642).
|
|
|
|
Reduces noise from --debug-gpu so we can spot serious errors.
Blender 2.7x uses OpenGL 2.1, we don't care if features are deprecated.
I'll re-enable these warnings for blender2.8 after next merge.
|
|
|
|
|
|
Backtrace so we can pinpoint where the GL error came from. Then fflush
on severe errors in case it's severe enough to crash Blender.
|
|
When running blender --debug-gpu
Display which debug facilities are available. One of these, in order of preference:
- OpenGL 4.3
- KHR_debug
- ARB_debug_output
- AMD_debug_output
All messages are logged now, not just errors. Will probably turn some of these off later.
GL_DEBUG_OUTPUT_SYNCHRONOUS lets us break on errors and backtrace to the exact trouble spot.
Callers of GPU_string_marker no longer pass in a message length, just the message itself (null terminated).
Apple provides no GL debug logging features.
|
|
Reported by @panzergame in D1414.
`glDisable` calls with bad enum argument `GL_TEXTURE_2D_MULTISAMPLE` that came from this line:
`tex->target = (n == 1) ? GL_TEXTURE_1D : (samples ? GL_TEXTURE_2D_MULTISAMPLE : GL_TEXTURE_2D);`
Reviewers: brecht
Reviewed By: brecht
Subscribers: AlexKowel, yurikovelenov, panzergame
Differential Revision: https://developer.blender.org/D2145
|
|
It was possible to have missing outlink but GPUNodes in material.
|
|
3D view
There was a misusage of the `outcol` and `texcol` params. The actual
formula should have been:
incol = facm * outcol + fact * ((one - outcol) * texcol * outcol +
outcol * scr);
To make sure the result is consistent with material mode, reuse the
material blend function (mix_soft), similarly to what most other texture
blend modes do.
|
|
|
|
A bit work in progress, currently the following limitations:
- Texture shading only, Material shading will come later
- No UVs subdivision yet
- Always uses active UV and currently changing active UV will
not properly update the viewport.
Well, need to start somewhere :)
|
|
|
|
|
|
|
|
Since moving to MLoopTri this is no longer needed.
|
|
Two were actual bugs, though they existed only in unused code:
* In Freestyle it was unintentionally copying a scene rather than referencing it.
* In BLI_array_store_is_valid there was use of uninitialized memory.
|
|
This patch is another step to achieve BI and it's Viewport consistency for cubemap textures.
{F318879}
To test world_space_shading flag D2072 is required.
Alexander (Blend4Web Team)
Reviewers: campbellbarton, brecht
Subscribers: homyachetser, Evgeny_Rodygin, AlexKowel, yurikovelenov
Differential Revision: https://developer.blender.org/D2074
|
|
Environment lighting (aka ambient) is a key component of any renderer.
It's implemented like the Environment lighting of BI render for Approximate Gather mode. It support "Sky Color" and "White" Environment lighting modes.
It would be great if the user could see actual lighting conditions right in the Blender viewport instead of waiting for the renderer to complete the final image, exporting for external renderer or for a game engine.
Before:
{F113921}
After:
{F113922}
Example file: {F319013}
Original author: valentin_b4w
Alexander (Blend4Web Team)
Reviewers: valentin_b4w, campbellbarton, merwin, brecht
Reviewed By: brecht
Subscribers: panzergame, youle, duarteframos, AlexKowel, yurikovelenov, dingto, Evgeny_Rodygin
Projects: #rendering, #opengl_gfx
Differential Revision: https://developer.blender.org/D810
|
|
Missing from fix for T48555.
Unfortunately duplicates code.
|
|
This avoids bad-level calls.
|
|
|
|
|
|
|
|
|
|
Also add utility functions: GPU_basic_shader_bind_enable/disable
so we don't have to get the previous state every time and manipulate it
|
|
The purpose of the patch is to replace deprecated glShadeModel.
To decrease glShadeModel calls I've set GL_SMOOTH by default
Reviewers: merwin, brecht
Reviewed By: brecht
Subscribers: blueprintrandom, Evgeny_Rodygin, AlexKowel, yurikovelenov
Differential Revision: https://developer.blender.org/D1958
|
|
Please do not do cleanups in minimal configuration, doing that has been
proven to only cause issues without solving anything meaningful ;)
|