Ecosyste.ms: OpenCollective

An open API service for software projects hosted on Open Collective.

github.com/haasn/libplacebo

Official mirror of libplacebo
https://github.com/haasn/libplacebo

cache: add missing header

No idea how this compiles locally on my end, but I don't care to find
out.

0c2d446ff98405378220eaabf91722b801424112 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/lut: fix texture LUT size generation

Fixes overallocation of ICC 3DLUTs by factor 2x, which also fixes the
icc_load/save legacy fallb...

fb7a6d3853e0a1050da8e69a0ce7fffba0363172 authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: make pl_cache_load() more robust

Guard against num_entries overflow, guard against size overflow.
Omit separate read() call for p...

bcdfb7576f651c69b62c7f5c99da1807ef21a55f authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: defend against array overflow

Extremely hypothetical edge case, but trivial to guard against.

e9a5b89003a4091306ae9be18899d8b7a3d6aa59 authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: fix for 32-bit systems

5dc33f2c13594f54dd9a9d81f7518e381a547f47 authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/plplay: increase default cache size

With xxhash, 50 MB is plenty fast enough compared to the general vulkan
init etc. overhead, and ...

ea91056682d1117a2b70b8a2c17773180aa3ac2c authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: add verbose PL_TRACE logging

To help understand wtf is going on sometimes

909f73bfd6d9630f5329b8f7f0abff36b8fb699b authored over 1 year ago by Niklas Haas <git@haasn.dev>
hash: improve golden ratio constant

Use 64-bit value, since we operate on 64-bit hashes. And give it a name.

9e1f32269e148dc59a68068c7bddaa8904456110 authored over 1 year ago by Niklas Haas <git@haasn.dev>
global: remove MSAN hacks

We no longer support running MSAN without fully instrumented
dependencies at all, either in the ...

2806c27aa9263ca060fa08561a13bfaf439a4a65 authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: add sanity assertion (+ whitespace)

Make sure our cache header has a "good" size, i.e. multiple of uint64_t.
We don't actually care ...

4eb16a202b3cc6234a3e286c83f147ec8fe045cd authored over 1 year ago by Niklas Haas <git@haasn.dev>
vulkan/context: log init times

Since these can be a source of non-negligible startup latency.

f2b6ca0b413cd01d6b6e114474163dbc721af5f6 authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/plplay: drop max object size

xxhash is fast enough to not really worry about a few-MB large objects
slowing down init process.

1a0948af44c0aae5d03bad253f2d1f771d116140 authored over 1 year ago by Niklas Haas <git@haasn.dev>
xxhash: add optional libxxhash implementation of pl_mem_hash

No reason to delete siphash just yet, it can be used as fallback for
systems with xxhash.

Close...

cb1009d1455e64787e52c5c3b6f7042aa37e5c14 authored over 1 year ago by Niklas Haas <git@haasn.dev>
hash: inline pl_mem_hash

In preparation for move to XXH3, which we want to inline always

6136ee11db4b6c8a8cffafc73d999e67b399ea28 authored over 1 year ago by Niklas Haas <git@haasn.dev>
hash: move prototype from pl_string to new header

So we can inline the hash function only into files that actually need
it.

405526c8825cccae7b77a7e641b615115dd719d1 authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: fix deadlock on loading corrupt files

489ef28afc23f4991b78afed4bf421081262766d authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/plplay: add cache statistics UI

For debug purposes.

07fa0f0cdabc8a22f1dc34eb1f8bfc4a25b22322 authored over 1 year ago by Niklas Haas <git@haasn.dev>
dispatch: deprecate pl_dispatch_save/load

Caching is now done directly inside the pl_gpu, via the pl_cache
mechanism. This cache layer is ...

5b3f40072b073cd7f1e06cacc160baefe05b8780 authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos: add missing license headers

8e5bd0d5158272d53143122ba43eb5a8a676f839 authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/plplay: add basic shader caching support

Probably won't work for ICC/3DLUT cache but these probably want their
own custom mechanism anywa...

b38e1c84278e165aafa90101292d40c17e7940a0 authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos: remove old/unused assets

No longer used by any current demo.

fadd5da3365b74be6ddae25ed63a5fd6910a78ea authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/utils: add get_cache_dir helper

378bc6a9f7dde22b4de3e65378563b67540eed80 authored over 1 year ago by Niklas Haas <git@haasn.dev>
gpu: remove pl_pass_params.cached_program

No longer functional after the recent changes to make pl_gpu use
pl_cache directly. No need for ...

1759d2f41e1dc64c7027e9609a2596894a79dc76 authored over 1 year ago by Niklas Haas <git@haasn.dev>
d3d11/pass: switch to pl_cache based caching

Trivial port by just replacing cached_program with
pl_cache_lookup/insert.

The cache key is mad...

6a9d90df3457295786719be27abd6f3ba1519ad4 authored over 1 year ago by Hendrik Leppkes <h.leppkes@gmail.com>
shaders/film_grain_h274: cache grain LUT

This is actually a constant, and could be precomputed and stored inside
static data if we had a ...

8aac9254cfc61147622bd074a80a9a96a4142f32 authored over 1 year ago by Niklas Haas <git@haasn.dev>
d3d11/pass: pl_str_hash(pl_str0()) -> pl_str0_hash

Cosmetic.

c399a21cac272042579eca218663b3fe6a714e7d authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: enable gamut mapping 3DLUT caching

0a2f15837e56d5f9bc8ddce53f941381a7f0b18e authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: switch from update to signature

Slightly more convenient because it will enable caching.

02bacbdb28898de3552c46364a31c51a8a851bff authored over 1 year ago by Niklas Haas <git@haasn.dev>
vulkan/pass: switch to pl_cache based caching

And ignore cached_program entirely.

2ad89fdf1f3978bc25def43df0e5dd78232f01dc authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/dithering: cache blue noise dither matrix

Since this can eat up some nontrivial amounts of compute time.
Just make sure it identifies the ...

c4900a41ca8ccb64f913a02b50d0d67e842a642d authored over 1 year ago by Niklas Haas <git@haasn.dev>
opengl/pass: switch to pl_cache based caching

Following same approach as d3d11. For simplicity, keep the current
gl_cache_header, since we sti...

c1954b7da30911394abee08d7f3087666fb24a1c authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/icc: refactor cache mechanism

Now users can be explicit about which cache they want to use, with the
save/load callbacks being...

11af3487c5378c79ff240d8de11caa61ea76d5b5 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/lut: add ability to cache shader LUTs directly

Currently only enabled when explicitly provided by the caller, to avoid
unexpected surprises. (A...

24e1dbeb66ed5fe3307f85363a412c894c8ec5b2 authored over 1 year ago by Niklas Haas <git@haasn.dev>
gpu: add pl_gpu_set_cache()

Allows attaching custom pl_cache to a pl_gpu.

6f0ec19a77b94421e95c148c689ee8779dc0f48f authored over 1 year ago by Niklas Haas <git@haasn.dev>
tests/cache: add tests for pl_cache mechanism

98978ae7484e1d36c8cd432f5fd808e158553b65 authored over 1 year ago by Niklas Haas <git@haasn.dev>
cache: add common/core caching mechanism

Motivated by https://code.videolan.org/videolan/libplacebo/-/issues/299

This mechanism should b...

8a2af4cc4cf01b430b297336a43a92f12328543c authored over 1 year ago by Niklas Haas <git@haasn.dev>
pl_string: add pl_var_hash

Wrapper around common pl_mem_hash + sizeof idiom

0df53c2e23ab04a4c213085a9aaaef342c8214ff authored over 1 year ago by Niklas Haas <git@haasn.dev>
d3d11/gpu: add missing pl_spirv_destroy call

ccb43419ccff0dc68dae6ed67170e9022ddbd710 authored over 1 year ago by Niklas Haas <git@haasn.dev>
glsl/spirv: API bikeshedding

Make this less stupid, add some typedefs, avoid passing const pointers
to small structs for no r...

943c00dc6789a95783b77498533969cbf3842521 authored over 1 year ago by Niklas Haas <git@haasn.dev>
convert: make fast_float optional dependency if not required

49780733a52d2f74f51c58d9902b47be34983e9a authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
demos/plplay: work around exp10f non-portability

8e70444de99cd41d2df3f1269b5773071c64be4c authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/plplay: adjust polar cutoff slider

To be logarithmic.

090bab5af8cf305211764937ab3840c597ecbdb4 authored over 1 year ago by Niklas Haas <git@haasn.dev>
filters: update ewa_lanczossharp blur value

For consistency and with the value that is actually reproducible

fa6dc83460b88f6e316a7a8b9265d6b7265f6fc6 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
meson: add missing variable

Got lost during rebase or something...

57f520af8bce60e8eac6ce212cad147f58212a5b authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
filters: fix ewa_lanczossharp(est) legacy description

Consistency with the new `description` field.

bc3b89ee637782e93d007845f52c0b7357850d6c authored over 1 year ago by Niklas Haas <git@haasn.dev>
filters: update ewa_lanczos4sharpest blur value

3061a8b607ae2fec8049d84c42bbf4b9b7205553 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
dispatch: disable textureLod() when using non-normal samplers

I'm really unhappy with this solution, but I'm also really unhappy with
the alternatives. I'm st...

e448dc6df210f796aa61c7ff90db493ba7100b95 authored over 1 year ago by Niklas Haas <git@haasn.dev>
ci: remove msan build

It doesn't work correctly. All componentes have to be instrumented for
msan to function properly...

84d39624bd95faa162f7af9949cb7783b33c07fa authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
convert: remove unused code

bc0bc8ec954122ca4aaa564bc686b0eebcd5b951 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
tests/string: add tests for large inputs

7d1bc36cc5de0f82bcca6c7b9b4317c27e26a2d7 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
format: use new pl_str_print/parse

c04cd05a0418a19fb4d2e39cfddd9d2ebd337bea authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
convert: improve ccStrPrintDouble

- don't print insignificant decimal digits
- change how last digit round is performed

Mostly ne...

10502bd3065aa6faa4414466f85bf3ddcbd9e239 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
meson: bump C++ version to 20

259c9a7ebda86682c0faae1a48c4f8731fb7ab57 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
convert: move conversion functions to own file

Will be useful for next commits.

82d21863e1eb71342da65b482ed71e669d9bfead authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
tools/glsl_preproc: use type names instead of suffix

New printer can produce floating point number without fractional part,
so we have to make it cle...

edc923be702308d9e237905a99cdaba084d682b8 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
meson: specify code page with pragma

rc.exe does not support --codepage= syntax and there is no way in meson
to ask what resource com...

d3c109058a31e8a8bdd0b182f2b70a0762620a73 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
shaders: be explicit about the type

940f42e0168c323a8306831fa8ec95d7795c59d2 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
common: exclude atomics in C++

They are not used in C++ code and compatibility with stdatomic.h was
introduced in C++23. For co...

727a5f0b3a8b19134146351b6600bd2e0602b8b7 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
pl_string: add pl_string_print_* and pl_string_parse*

Based on C++ std::from_chars/std::to_chars

For compilers that does not fully support std::from_...

fb4b68c56f679cda6d246fc79f61e0bd914af08f authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
convert: add fast_float submodule

Significantly faster and more robust float conversions. Also reduces
amount of custom code.

Ref...

9b9987cc12b3513ecd48239fdfdc4220bc61260f authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
common: fix include order

Since common.h include pl_*.h to let those headers use
libplacebo/config.h it has to be included...

704e0cc9b7277ab5090c7d65e8882e7e2878d8fa authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
meson: don't declare vulkan headers as dependency

This fixes leaking those headers in pkg-config file while we don't want
to do that. Especially b...

5914fb6d88d829ef5aae840a42f5fe7c133b4853 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
pl_string: fix for C++ compatibility

a2b0b186a851d9cd56b019aebc9616a3ae66c02a authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
meson: add -DNOMINMAX and -DWIN32_LEAN_AND_MEAN for Windows

To include less and not define min/max macros.

b188120883dc74c29b1b74d64015b836960db955 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
meson: set project args also for cpp

We have at least one cpp files (glslang.cc) and soon maybe more.

d4031d7a43729fc402c7e91c383c150affae40c7 authored over 1 year ago by Kacper Michajłow <kasper93@gmail.com>
tests: increase default test timeout to 120s

the nvidia vulkan drivers are so glacially slow at compiling shaders that
I get timeouts when pu...

7737933d2a73e9f9798b602b50d1baa949038cb7 authored over 1 year ago by Niklas Haas <git@haasn.dev>
renderer: default to ewa_lanczossharp

Not only is this generally higher quality, it's also actually *faster*,
because the sharpened ke...

3160c3d7c764fd52120588956a0ec08bd7499f7f authored over 1 year ago by Niklas Haas <git@haasn.dev>
filters: add pl_filter_ewa_lanczossharp(est)

ewa_lanczos4sharpest in particular only looks good when combined with
antiringing, which is why ...

30a4902d1c2b305ce5972d13c1c6800e3e050dcd authored over 1 year ago by Niklas Haas <git@haasn.dev>
options: add antiring options to custom scalers

4632b907b19ff7a6fd2db6256a09b95304f511f5 authored over 1 year ago by Niklas Haas <git@haasn.dev>
filters: add pl_filter_config.antiring

Allows filter presets to already pre-enable anti-ringing. Simplifies
configuration of AR variant...

11771cdd82cec0d2f775553611c276092fb283cf authored over 1 year ago by Niklas Haas <git@haasn.dev>
filters: remove pl_filter_config.filter_scale

Simplification of the math. This is now entirely redundant with
pl_filter_config.blur.

9dd5f65d35aaa30352142ced17026956ad7a4e26 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/sampling: use pl_filter_config.blur instead of filter_scale

They now do exactly the same thing.

cd4266fa862df91371e06d0a0c48a5f2a25caacd authored over 1 year ago by Niklas Haas <git@haasn.dev>
filters: apply blur to window as well

This effectively scales the true filter size by the blur coefficient,
rather than merely scaling...

6144b27fdab28eb266de8f6cd91c903b808682e4 authored over 1 year ago by Niklas Haas <git@haasn.dev>
options: parse floats expressed as fractions

Allows float options to accept values as fractions

d6f1db186d535f3d99d56165bb468de71d58dc6e authored over 1 year ago by llyyr <llyyr.public@gmail.com>
shaders/colorspace: bias PQ deltas for mostly black frames

To avoid triggering huge scene change detections when only a tiny part
of the image contains non...

648efac60cc0ff006897d13af4f327b9a69788c3 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: don't bypass smoothing for black frames

Force them to go through the normal update logic.

45fa8589238fac7b71a84e279e6f7bb8d3f59ee7 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: distinguish between active/total wg count

Slightly more convoluted than the previous approach but lets us know
exactly what percentage of ...

aff8d121f40fa653e7a8ce0e85bcec440bc451ea authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: properly handle pl_buf_read failure

This should not be silently ignored or re-tried later, since it's a
serious error.

c99e3c2b70227ece777ae1e2cc20595fad299f9a authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: don't warn on solid black frame

Since 31082eee7a it's possible for frame_wg_count to not get
incremented, in particular, for all...

08f76b7892ea96c3b9f131b81a55375a7a216853 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: significantly lower default smoothing period

Experimental testing on a variety of scenes revealed a value of 20.0 to
be more generally respon...

ec60dd156b82753a2e2d8a399899244605f4d1bf authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: significantly reduce scene threshold

Based on experimental testing on real content, I determined the "safe"
value for in-scene PQ flu...

0903cbd05d7fc0391cbd99954924a39b855c8a1b authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: remove pl_tone_map_auto

And leave a #define alias in its place. (Probably permanently, since we
can't put a deprecation ...

5f630020046c9b039adc34bf520644b264776606 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: default to pl_tone_map_spline

HDR10+ metadata is buggy enough in practice (and often just
auto-generated by stupid process), t...

9fabc2bc74aa16c14fe7dc996a36b8347dc79bc4 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: exclude black pixels from peak detection

Significantly improves peak detection result on frames containing many
black pixels (e.g. hardco...

31082eee7a6dc800df5bd7db6d115efcaaa2dd8c authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: simplify sh_luma_coeffs signature

No need to repeat this boilerplate.

06be61d72b4ec82e9182a1644b17a72ede536d8e authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: use correct luma coeffs for peak detection

This needs to use the same luma coefficients as the RGB space of the
*encoding*, not the color v...

9a8532bc62fb8afeee941ea17c04eaad9501b318 authored over 1 year ago by Niklas Haas <git@haasn.dev>
options: exclude special options from `preset=` loading

It makes little sense for `preset=default` to override options that
conceptually exist outside t...

31468524661fc5b350ee927d6001aabee4ad437b authored over 1 year ago by Niklas Haas <git@haasn.dev>
renderer: only disable peak detection if HDR10+ OOTF in use

But still prefer peak detection over dynamic per-scene HDR10+ metadata,
since the latter produce...

defc77622910726898d1dcf1357536537f7ca242 authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: simplify auto-TM selection

The `spline` function has become good enough to outperform all of the
other tone-mapping functio...

94dc4cfb15330cb590b20d7308bbf83e9e73b507 authored over 1 year ago by Niklas Haas <git@haasn.dev>
demos/plplay: add detected peak metadata

f1bddda77d759467031c3e38e9acdef55d14a35c authored over 1 year ago by Niklas Haas <git@haasn.dev>
renderer: add pl_renderer_get_hdr_metadata

Mirroring pl_get_detected_hdr_metadata. Heavily requested by users, to
be able to introspect cur...

ec005258d288ac9fbcc915c46a63eed6b9c332bc authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: also constrain output max if no inverse TM

Moves this into the more appropriate plce.

41ed31ed2abd6452ce69a8064d59843f762d36cb authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: properly constrain input peak

To avoid trying to tone-map values significantly below SDR white, even
with inverse tone-mapping...

1a349aeb506054491e5546b6008cb14f42661c52 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: remove minimum_peak

This is the wrong layer to solve this problem, and in particular,
hard-coding SDR 1.0 here preve...

be57a457c4dadb105d7db54a09a64ca6977f4351 authored over 1 year ago by Niklas Haas <git@haasn.dev>
shaders/colorspace: fix order of pl_tone_map_params_infer

Do this before clamping output_max because pl_tone_map_params_infer can
change these parameters.

149a24751aeaf2c109884a03f30f1da4cbbd1dc4 authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: used inferred peak in fix_params()

Since I plan on making pl_tone_map_params_infer() clamp/change these.

106de1aa05be980015398a7b5779673883c1ad61 authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: lower default adaptation strength

With the new dynamic adaptation tuning, we don't need to set such
excessively high adaptation tu...

21b611ecd04befa18c2487b16c186189b4e2e975 authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: add dynamic knee point adaptation tuning

Based on how close the target knee point is towards the 'extreme' values
(min/max knee), we rais...

b2748e6cc63c5cf8cfcebf2eb39f8b993566bf44 authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: reformulate st2094_pick_knee (cosmetic)

This does not change the calculated logic, it just makes the code flow
slightly easier to follow...

86a41224f2e054f856a7ba7574e5320ebc3a161c authored over 1 year ago by Niklas Haas <git@haasn.dev>
tone_mapping: rename duplicate expression (cosmetic)

54c3245b515a9951cbc112ec5fde8b0de21d0fa0 authored over 1 year ago by Niklas Haas <git@haasn.dev>