Skip to content
Snippets Groups Projects
  1. Mar 18, 2024
  2. Mar 16, 2024
  3. Mar 14, 2024
  4. Mar 11, 2024
  5. Mar 08, 2024
  6. Mar 07, 2024
  7. Mar 06, 2024
  8. Mar 05, 2024
  9. Mar 04, 2024
  10. Mar 02, 2024
  11. Mar 01, 2024
  12. Feb 29, 2024
  13. Feb 21, 2024
    • Niklas Haas's avatar
      options: update for new clearing options · e987124b
      Niklas Haas authored
      e987124b
    • Niklas Haas's avatar
      611a4abb
    • Niklas Haas's avatar
      renderer: refactor background/border clearing options · 36388111
      Niklas Haas authored
      The current behavior is very ad-hoc and presents numerous issues to
      downstream clients. Make this configuration process more straightforward
      by adding an explicit clearing mode enum field to `pl_render_params`,
      which the old override fields are specific instances of.
      
      Notably, this could be extended in the future, e.g. by PL_CLEAR_GRADIENT
      or whatever. (Although this can already be done as of right now by
      setting both clear modes to PL_CLEAR_NONE and using blend_params on top
      of a custom-drawn gradient)
      
      The default of `PL_COLOR_CLEAR` for both is consistent with the current
      status quo, and also presents the least surprising outcome when
      combining transparent/opaque images with transparent/opaque
      framebuffers. This way, the user only gets transparent images output if
      they explicitly opt-in to it, either by setting
      `background_transparency` to 1 (like `plplay` does), or by setting the
      background clearing mode to `PL_CLEAR_SKIP`.
      
      In particular, `border = PL_CLEAR_SKIP` will result in "garbage" pixels
      out of the box, at least on implementations which don't pre-clear
      framebuffers for you.
      
      Supersedes: videolan/libplacebo!637
      36388111
    • Niklas Haas's avatar
      renderer: add pl_frame_clear_tiles · 2b8fd9b0
      Niklas Haas authored
      Analog to pl_frame_clear_rgba. I had to decide carefully whether
      I wanted to preserve the symmetry with `pl_frame_clear_rgba` in taking
      only a `pl_gpu`, or if I should take the whole `pl_renderer` to gain
      access to the internal `pl_dispatch`. But I decided to go with the
      `pl_gpu`, since we might want to move this set of functions to
      a different module in the future. (It's not really renderer-specific)
      
      I also really regret having to go through such hoops every time to get
      the per-plane subsampling ratio. Truthfully, this should probably be
      a helper function.
      
      See-Also: !637
      2b8fd9b0
    • Niklas Haas's avatar
      colorspace: split PL_ALPHA_NONE off from PL_ALPHA_UNKNOWN · 0ee549aa
      Niklas Haas authored
      This field was doing double duty between marking the alpha mode as
      unknown and marking the alpha channel as absent, with inconsistent
      results. In particular, pl_renderer always inferred the alpha channel if
      present in the texture, leaving users with no options for easily
      manually disabling it.
      
      This patch adds PL_ALPHA_NONE to rectify the situation, allowing API
      users to set `target.repr.alpha = PL_ALPHA_NONE` to explicitly disable
      alpha blending even when the target supports it.
      
      See-Also: !637
      0ee549aa
  14. Feb 19, 2024
Loading