summaryrefslogtreecommitdiff
path: root/src/render/OpenGL.cpp
Commit message (Collapse)AuthorAgeFilesLines
* renderer: more FP16 fixes (#14070)UjinT342026-05-071-17/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * fix fp16 blur with invalidation * restore tonemap code * fix fade outs * add sdr compat for unaware surfaces * use a better work space, not linear, only for sdr * fix hl tf -> wp tf * cache workbuffer descriptions * linear not normalised WIP * clear offload fb * CM math * fix includes * use precalculated cm for shadows * inner glow cm * quad cm * fix unmodified copy * codegen * cache color CM * mark blur dirty when CM/DS changes * avoid icc workbuffer * fp16 blur finish hack * fix output hdr luminances * use srgb for mirroring/sharing with fp16 * defaults people --------- Co-authored-by: Vaxry <vaxry@vaxry.net>
* desktop/window: expand hidden into proper statesVaxry2026-04-291-1/+1
|
* desktop/window: add alpha container for alpha calculationsVaxry2026-04-291-1/+3
|
* config/lua: init lua config manager, use lua if available (#13817)Vaxry2026-04-261-25/+25
| | | Adds a new lua config manager, which will automatically be used if there is a lua config present.
* opengl/shadow: fix shadow offset rendering (#14156)Vaxry2026-04-241-3/+30
|
* opengl: minor egl changes (#14147)Tom Englund2026-04-231-1/+3
| | | | | | | | | | | | | * opengl: explicitly set stencil mask set stencil mask to 0xFF to allow writes, when done set it back to 0x00 to become readonly, avoids potential mishaps. also at the end set the stencil op to GL_KEEP and it will certainly be read only until next time its changed. * opengl: use modern glClearBufferfv over glClear use more modern glClearBufferfv instead, and also clear the entire buffer if a clearpass has been added but no renderdamage exist.
* errorOverlay: modernize, refactor, use GPU rendering (#14122)Vaxry2026-04-191-7/+7
| | | | | | | Improves the overlay's rendering: - GPU accelerated - supports gradients - wraps - cleaner code a bit
* renderer: simplify shadows (#14047)UjinT342026-04-181-13/+16
|
* renderer: Various CM fixes, part 8 of refactors (#13860)UjinT342026-04-161-33/+35
| | | Part 8 of Ujin's refactors.
* notifications: move and small refactor (#14094)Vaxry2026-04-161-1/+1
| | | moves to notification/, and adds a new style manager getter.
* render/opengl: optimize getShaderVariant's map accessVaxry2026-04-041-5/+8
|
* renderer: refactor part 7: api fixes (#13631)UjinT342026-03-281-139/+128
| | | | | | | Part 7 of ujin's refactors --------- Co-authored-by: Vaxry <vaxry@vaxry.net>
* renderer/deco: add glow decoration (#13862)Vaxry2026-03-271-4/+67
|
* renderer: small fixes in OpenGL.cpp and OpenGL.hpp (#13842)Pppp11162026-03-261-9/+21
| | | | | * render: add EGL error details to dmabuf query failures * linux-dmabuf: tighten plane modifier checks and feedback safety
* config: cleanup the entire config infrastructure (#13785)Vaxry2026-03-201-10/+10
| | | | Massively refactors the config infrastructure, sorely needed and will be req'd for the lua stuff
* renderer: fix crash when shader path isn't a file (#13756)nikitax442026-03-191-2/+13
|
* source: c-f for new clang versionVaxry2026-03-151-2/+2
|
* internal: fix relative path header locations (#13650)ItsOhen2026-03-131-3/+3
| | | Or plugins can't build.
* renderer: fix crash on null blur framebuffer during monitor disconnectmatjam2026-03-101-1/+2
| | | | Guard all m_blurFB dereferences against null. The blur framebuffer is reset during monitor disconnect but layer surface snapshots use a simple render path that skips framebuffer allocation.
* renderer: fix crash with nullptr FBs (#13641)UjinT342026-03-091-8/+16
|
* renderer: fix sdr mod (#13630)UjinT342026-03-071-1/+1
|
* renderer: refactor gl renderer (#13488)UjinT342026-03-071-547/+158
|
* renderer: refactor projection setting (#13485)UjinT342026-03-071-78/+25
|
* renderer: move m_renderData to renderer (#13474)UjinT342026-03-071-326/+354
|
* renderer: refactor resources and flags (#13471)UjinT342026-03-071-421/+114
|
* renderer: refactor Texture, Framebuffer and Renderbuffer (#13437)UjinT342026-03-061-88/+116
| | | Part 1 of the renderer refactors
* renderer: shader variants refactor (#13434)UjinT342026-03-061-445/+332
| | | Part 0 of renderer reworks.
* screencopy: fix isOutputBeingSSd (#13586)Vaxry2026-03-051-0/+1
| | | use sessions instead of pending frames
* render/cm: add ICC profile pipeline (#12711)Vaxry2026-03-041-160/+201
| | | Adds an ICC profile pipeline, loading via config and applying via 3D LUTs.
* renderer: better sdr eotf settings (#12812)UjinT342026-02-261-14/+22
|
* event: refactor HookSystem into a typed event bus (#13333)Vaxry2026-02-221-11/+7
| | | | | Refactors the old HookSystem into a typed event bus with clear separation, discovery and types.
* protocols: implement image-capture-source-v1 and image-copy-capture-v1 (#11709)Ikalco2026-02-221-18/+32
| | | Implements the new screencopy protocols
* opengl: add debug:gl_debugging (#13183)Tom Englund2026-02-061-5/+10
| | | | | | | | | | | | | add debug:gl_debugging so we can disable gl debugging entirerly, both glGetError and enabling EGL_KHR_debug has its cost, we still have EXT_create_context_robustness and glGetGraphicsResetStatus that should catch context loss, and is generally cheap to call it only checks a flag set. glGetError might cause a implicit flush to get any pending calls sent to the gpu. however to get EGL_KHR_debug back enabled we now require a restart of the compositor after changing debug:gl_debugging
* renderer: fix screen export back to srgb (#13148)UjinT342026-02-021-21/+23
|
* opengl: set EGL_CONTEXT_RELEASE_BEHAVIOR_KHR if supported (#13114)Tom Englund2026-01-301-0/+7
| | | | | | | | | EGL_CONTEXT_RELEASE_BEHAVIOR_KHR determines what happends with implicit flushes when context changes, on multigpu scenario we change context frequently when blitting content. while we still rely on explicit sync fences, the flush is destroying driver optimisations. setting it to EGL_CONTEXT_RELEASE_BEHAVIOR_NONE_KHR essentially mean just swap context and continue processing on the next context.
* opengl: allow texture filter to be changed (#13078)jmanc32026-01-271-4/+4
| | | | | | | | | | | * opengl: allow texture filter to be changed * format * correct filter * Moved from OpenGL.hpp to Texture.hpp * Shortened names
* renderer: add surface shader variants with less branching and uniforms (#13030)UjinT342026-01-211-35/+121
| | | | | | | | | * shader variant features * getSurfaceShader variant with feats * split surface shaders by features * cleanup old shaders
* renderer: optimise shader usage further, split shaders and add more caching ↵Tom Englund2026-01-171-22/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#12992) * shader: split CM rgba/rgbx into discard ones make it branchless if we have no discards. * shader: ensure we dont stall on vbo uv buffer if we render a new texture before the previous was done gpu wise its going to stall until done, call glBufferData to orphan the data. this allows the driver to return a new memory block immediately if the GPU is still reading from the previous one * protocols: ensure we reset GL_PACK_ALIGNMENT reset GL_PACK_ALIGNMENT back to the default initial value of 4 * shader: use unsigned short in VAO loose a tiny bit of precision but gain massive bandwidth reductions. use GL_UNSIGNED_SHORT and set it as normalized. clamp and round the UV for uint16_t in customUv. * shader: interleave vertex buffers use std::array for fullverts, use a single interleaved buffer for position and uv, should in theory improve cache locality. and also remove the need to have two buffers around. * shader: revert precision drop we need the float precision because we might have 1.01 or similiar floats entering CM shader maths, and rounding/clamping those means the maths turns out wrong. so revert back to float, sadly higher bandwidth usage. * update doColorManagement api * convert primaries to XYZ on cpu * remove unused primaries uniform --------- Co-authored-by: UjinT34 <ujint34@mail.ru>
* core: optimize some common branchesVaxry2026-01-161-11/+11
|
* protocols/cm: Fix image description info events (#12781)UjinT342026-01-131-5/+3
| | | | | | | | | | | | | | | | | | | | | | | * fix image description info events * always send some target primaries * set edid values as target primaries and luminances * init monitor image description * set default luminances for tf * fix BT1886 luminances * fix mastering values and overrides * set maxCLL & maxFALL * typo * add FALL & CLL to preferred HDR image description * fix ref luminances
* renderer: shader code refactor (#12926)Tom Englund2026-01-121-548/+221
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * shader: begin the shader refactor make SShader a class and rename it to CShader, move createprogram, compileshader, logshadererror to CShader. * shader: move uniform creation to CShader move uniform creation to CShader, reduces tons of duplicated effort, however forcing uniform names to be same in all shaders. * shader: move to array based frag handling use an array with an enum so it gets easier dealing with multiple shaders, move creating program to a for loop and array, reduces line of code a lot. * shader: use shared ptr for frags with smart pointers we can now rename useProgram to useShader and return the shader directly, means only place we have to decide the shader frag is when calling useShader. easier for future shader splitting to reduce branching. * shader: move unneded public members to private move structs and uniforms to private add a get/set for initialtime and add a getUniformLocation to make the code tell what its doing, instead of direct array getting when all we wanted to get was its value, also limits the setting of uniformLocations to the createProgram as it should be. * shader: fix style nits set first enum member to 0 , remove extra {} * shader: dont show a failed notif on success the logic got inverted in the refactor here. * shader: split CM shader to rgba/rgbx variants split shader to rgba/rgbx variants, use bool, and reduce branching. * shader: split up blurprepare CM and non CM split up blurprepare, remove skipcm, move gain to gain.glsl. remove ternary operator and reduce branching by using step() and mix() use vec3 for gain, make brightness a cheap mulitplication with max. * shader: split up border to CM/noncm variants splitup border shader to CM/noncm variant, move common used things to border.glsl , there is room for optimisations here but its a complex shader im putting it for future PR. * shader: touchup blurfinish make brightness a cheap multiplication instead of branching. mod is redundant, fract in hash already returns a value in [0.0, 1.0]
* renderer/opengl: invalidate intermediate FBs post render, avoid stencil if ↵Vaxry2026-01-051-57/+38
| | | | possible (#12848)
* opengl: properly combine transforms in renderTextureVaxry2025-12-271-4/+5
| | | | ref #12666
* render/cm: various updates, remove old protocols (#12693)UjinT342025-12-271-44/+46
| | | | | | | | | | | | | * fix named primaries * default to gamma22 * mark mastering primaries as supported * remove xx-cm and frog support * immutable primaries and image descriptions * clang-format
* rules/windowRuleApplicator: fix min/max size effects (#12491)Vaxry2025-12-271-22/+22
| | | fixes #12412
* debug: move to hyprutils' logger (#12673)Vaxry2025-12-181-68/+71
|
* renderer: add zoom with detached camera (#12548)jmanc32025-12-141-15/+3
|
* cm: handle CM for SDR content with cm=hdr, cm_sdr_eotf=2 (#12127)Dominick DiMaggio2025-12-111-1/+3
|
* desktop: cleanup, unify desktop elements as views (#12563)Vaxry2025-12-081-3/+3
|
* renderer/cm: higher-quality tonemapping (#12204)Dominick DiMaggio2025-12-071-8/+20
|