Commit Graph

14020 Commits (5c59f4261bded3f9f809376338d892b0d7ecbdf4)

Author SHA1 Message Date
Martin Gräßlin 5c59f4261b [effects] Use shader traits API for reflection shader 2016-01-25 14:11:54 +01:00
Martin Gräßlin 6bdef479a9 [effects] Use shader traits API for CubeCap shader 2016-01-25 14:11:54 +01:00
Martin Gräßlin 712e46e468 [effects] Port startupfeedback to shader trait api
The blinking shader is adjusted to use a shader trait vertex shader
and gets generated with a shader trait variant.

Overall the code is simplified to ensure that we always have a shader
bound with the correct mvp matrix when rendering the icon.
2016-01-25 14:11:54 +01:00
Martin Gräßlin f13622a914 [effects] Use shader traits generated shader for invert effect
Source code needs minor adjustment to be compatible with the shader
traits variable naming.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 7facdb67ee [effects] Simplify setting mvp matrix for cursor in zoom effect
Now that we pass the projection matrix with screen paint data we
don't need to calculate our own matrix.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 4e8e0f817f [effects] Drop resetting Generic Shader from zoom effect
No longer needed as during the rendering the Generic Shader is not
used any more. So the zoom effect doesn't affect it.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 4b96370e67 [effects] Use shader traits API in trackmouse 2016-01-25 14:11:54 +01:00
Martin Gräßlin a09ede8cc9 [effects] Use shader traits API to render wallpaper in cube effect 2016-01-25 14:11:54 +01:00
Martin Gräßlin 8d9321ca4c [effects] Use shader traits api in screenedge effect 2016-01-25 14:11:54 +01:00
Martin Gräßlin 700adad9b1 [effects] Use shader traits API for MouseMark effect 2016-01-25 14:11:54 +01:00
Martin Gräßlin 2add89e274 [effects] Use shader trait api in MouseClick 2016-01-25 14:11:54 +01:00
Martin Gräßlin ff9ffe77ba [effects] Use color shader traits in magnifier effect 2016-01-25 14:11:54 +01:00
Martin Gräßlin 6aa19b1587 [effects] Use shader traits in SnapHelper effect
To simplify rendering is moved from postPaintScreen to paintScreen.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 2de0b527d0 [effects] Use shader traits in ShowPaint effect 2016-01-25 14:11:54 +01:00
Martin Gräßlin b757b7e17d [effects] Switch ShowFPS to ShaderTraits based rendering 2016-01-25 14:11:54 +01:00
Martin Gräßlin d76f08e359 Render effect frame with shader trait API 2016-01-25 14:11:54 +01:00
Martin Gräßlin 0d1da1c583 Always set mvp on shader in SceneOpenGL2Window::performPaint
Makes it possible to pass in a shader with a custom fragment shader,
but a normal vertex shader which needs the mvp matrix to be set.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 4b11b7b6b8 [kwineffects] Add a generateCustomShader to ShaderManager
This method allows to generate a shader with ShaderTraits but one
part (e.g. vertex and/or fragment) to be replaced by custom shader
code.

Thus it can be used as a replacement for the load*(ShaderType) variants
and allows more effects to transition to shaders using traits.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 3be6ff9f12 [kwineffects] Pass screen projection matrix to WindowPaintData
The screen projection matrix is needed if an effect wants to customize
the modelview projection matrix while rendering a window and keeping
the currently applied screen projection and transformation.
2016-01-25 14:11:54 +01:00
Martin Gräßlin f284ef814c Pass projection matrix to ScreenPaintData
With this change a new ctor overload is added to ScreenPaintData
which allows passing a projection matrix through the effects. This
allows effects to put up custom shaders with a shared projection matrix
and without having to calculate it themselves.

The projection matrix is a read-only information for the effects. There
is no way to change or overwrite it.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 5657405d32 Use ShaderTraits based shader for paint background
Little bit less usage of old Shader API.
2016-01-25 14:11:54 +01:00
Martin Gräßlin ad7246e010 Create the new projection matrix at start of frame rendering
For both simple and generic rendering the projection is actually the
same. So let's create it at the start of the frame rendering which
allows us to also pass it through the effects.
2016-01-25 14:11:54 +01:00
Martin Gräßlin 778a7fd1a0 [kwinglutils] Add a ShaderTraits variant to ShaderBinder
Simplifies binding a Shader with traits.
2016-01-25 14:11:54 +01:00
Bhushan Shah fbd1122a15 Fix the build 2016-01-20 03:35:32 +05:30
Bhushan Shah bb7674f2b6 Make use of Xinput lib only if we found it
Reviewed by: mgraesslin
2016-01-20 03:05:14 +05:30
Thomas Lübking 1c344c16d9 emit shadeChanged before calculating unshaded size
Otherwise the old (shaded) border sizes will be invoked, causing
a shrinkage of the window

BUG: 357669
FIXED-IN: 5.6
REVIEW: 126671
2016-01-18 22:50:13 +01:00
Thomas Lübking ed1d32288b move doubleclick logic into press event
alignes w/ systemwide behavior and allows elegant fix of
BUG: 357450
FIXED-IN: 5.6
REVIEW: 126631
2016-01-18 22:34:37 +01:00
Thomas Lübking 95cbd7c1b3 prevent nullptr dereferentiation
BUG: 357032
FIXED-IN: 5.6
REVIEW: 126787
2016-01-18 22:34:26 +01:00
Thomas Lübking c7aefc6b6b skip SWAP_BEHAVIOR_PRESERVED for supportsBufferAge
pointless and unsupported on latter MESA/DRI3
http://lists.freedesktop.org/archives/mesa-dev/2015-November/100869.html

Thanks to Uriy Zhuravlev for reporting and investigation

BUG: 356992
CCBUG: 356882
FIXED-IN: 5.5.4
REVIEW: 126783
2016-01-18 22:32:10 +01:00
l10n daemon script e65f7a349f SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-01-18 14:17:07 +00:00
Thomas Lübking e73e331f35 use XCB_CURRENT_TIME for NET::TakeFocusProtocol
The only clients that really seem to rely on it are
Java and they're apparently "broken", resp. extremely
picky on the tiemstamp and probably happily refuse focus
if it's *not* equal to the current server time (ie. anything else
happens at this moment) and overmore feel oblieged to act as WM
by juggling around VDs at all.

BUG: 347153
FIXED-IN: 5.6
REVIEW: 126753
2016-01-15 22:00:10 +01:00
Thomas Lübking 87795eef2a Actually keep the expandedGeometry alive
... until the effects handled the deletion

BUG: 318322
BUG: 320892
BUG: 344359
REVIEW: 126323

FIXED-IN: 5.6
2016-01-15 01:37:51 +01:00
Thomas Lübking f918bc3367 fix build of rules kcm
REVIEW: 126733
2016-01-14 23:40:44 +01:00
Thomas Lübking 69aa80750f force restart on crash
We don't want to actively release claims on segfaults, but then
drkonqi can stop us while we're still holding the WM privs.

=> If KWin performs a crash-restart, it forcefully takes WM privs
(since the old instance shall be replaced for quite sure)

BUG: 348834
BUG: 353030
BUG: 353428

REVIEW: 126741
FIXED-IN: 5.6
2016-01-14 23:40:27 +01:00
Thomas Lübking 57c9aa9fc0 update expanded geometry when slide is done
In addition it's required to keep the expandedGeometry alive until
the effects handled the deletion

BUG: 318322
BUG: 320892
BUG: 344359
REVIEW: 126323

FIXED-IN: 5.6
2016-01-14 23:37:13 +01:00
Martin Gräßlin 5a31618461 Use XInput for "polling" the mouse positing
Replaces the timer based polling approach. If XInput is available we
listen for the RawMotion event on the root window and use this to
trigger a mouse pointer position.

BUG: 357692
FIXED-IN: 5.6.0
REVIEW: 126733
2016-01-14 17:25:04 +01:00
l10n daemon script 9bf7ad4a9f SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-01-12 12:09:37 +00:00
Martin Gräßlin e861c5f185 Merge branch 'Plasma/5.5' 2016-01-11 13:22:26 +01:00
Martin Gräßlin a18177cc24 [backends/drm] Set mode when changing from/to a gbm buffer
Tiling configurations of DRM and GBM buffers differ, so we need to
explicitly set the mode when it changes.

BUG: 357543
FIXED-IN: 5.5.4
2016-01-11 12:53:14 +01:00
l10n daemon script 096b61ee44 SVN_SILENT made messages (.desktop file) 2016-01-10 14:47:34 +00:00
l10n daemon script aa0f2c88f0 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2016-01-10 11:46:53 +00:00
Andreas Hartmetz 2eac7634cc Remove saving and loading (and client matching by) WM_COMMAND.
This legacy session management scheme using the WM_COMMAND property
seems to be called XSM. It is very, very legacy because it was
superseded by XSMP in 1993(!).

By inspecting ~/.config/session/kwin_[...] I could see that Firefox
still sets WM_COMMAND, but nothing else in a regular session with
some applications.
As one of the last applications to switch to XSMP session management,
I guess Firefox keeps doing that because it still needs to work on,
say, Solaris, anyway, so why not set WM_COMMAND on Linux as well.
The WM_COMMAND set by Firefox looks like "wmCommand8=firefox\s" in
the kwin session file. It doesn't actually contain a session
identifier. But then, Firefox only has one session per user anyway.

This goes together with commit 5f0ca1305db4a925 in plasma-workspace /
ksmserver to remove legacy session management support.

I've talked about my plan to do this on IRC with Martin so hopefully
it's okay to just do this now.
2016-01-09 03:53:47 +01:00
Jonathan Riddell 0c5bed27de Update version number for 5.5.3
GIT_SILENT
2016-01-06 11:29:25 +00:00
Dāvis Mosāns 3e255e6969 Remove KWIN_BUILD_COVERAGE
It's provided by ECM BUILD_COVERAGE

REVIEW: 126628
2016-01-05 17:10:23 +02:00
l10n daemon script e616d7e143 SVN_SILENT made messages (.desktop file) 2015-12-30 12:19:00 +00:00
l10n daemon script aff81afd27 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2015-12-30 09:40:57 +00:00
l10n daemon script 87ccc5010a SVN_SILENT made messages (.desktop file) 2015-12-29 13:53:25 +00:00
l10n daemon script a10ed44aa0 SVN_SILENT made messages (.desktop file) - always resolve ours
In case of conflict in i18n, keep the version of the branch "ours"
To resolve a particular conflict, "git checkout --ours path/to/file.desktop"
2015-12-29 11:30:35 +00:00
Michael Pyne bcc36b87fb Avoid undefined behavior in nearestPowerOfTwo.
The way nearestPowerOfTwo is currently defined allows for the possibility of
left-shifting an int by 32 bits or more, which is undefined behavior on
platforms where int is 32 bits, and is something that can happen here if `s`
is equal to 31 by the end of the loop. Noted by Coverity as CID 1291191.

This patch takes an algorithm to perform the same operation from Hank Warren
Jr.'s book "Hacker's Delight", which should avoid UB.

REVIEW:126540
2015-12-28 17:08:15 -05:00
Michael Pyne 4957c18a44 Widen int to qint64 before multiplication, not after.
Noted by Coverity, CID 1334968.
2015-12-27 21:56:09 -05:00