Skip to content
GitLab
    • Explore Projects Groups Snippets
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • P PyAV
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 37
    • Issues 37
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 26
    • Merge requests 26
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • PyAV
  • PyAV
  • Merge requests
  • !686

Add color_range to CodecContext/Frame

  • Review changes

  • Download
  • Email patches
  • Plain diff
Open Johan Jeppsson requested to merge github/fork/johanjeppsson/main into main 5 years ago
  • Overview 5
  • Commits 1
  • Pipelines 1
  • Changes 6

Hi!

I recently found PyAv, and I am very impressed with how flexible and powerful it is compared to my old go-to-solution, which was calling ffmpeg with a subprocess call! :)

I realized that the color_range option was not implemented so I gave it a shot. Specifically, this can be needed when the default color range for YUV (0-255 or 16-235) needs to be overridden for a codec.

Since I am not deeply familiar with PyAV or the FFmpeg source code, my approach might not be the way to go, and if so I'm happy to update it based on your suggestions. In particular, the change in reformatter.pyx doesn't seem like the right solution to me. As far as I can tell it works as intended, but it definitely has a smell to it...

Also, some tests should probably also be added for this. I don't know if it's enough to test that the color_range property is set as expected when provided as an option, or if some decoding with different color_ranges are preferable?

Change-Id: I42451b3b84ea7ca4ae645566d1ef4709e0326f92

Loading
Loading

Activity


  • Jeremy Lainé
    Jeremy Lainé @jlaine started a thread on an outdated change in commit 0e5806ab 4 years ago
    Last updated by Johan Jeppsson 4 years ago
  • Jeremy Lainé
    Jeremy Lainé @jlaine started a thread on commit cfac5fd0 4 years ago
    Last updated by Jeremy Lainé 4 years ago
    av/video/reformatter.pxd
    9 9
    10 10 cdef _reformat(self, VideoFrame frame, int width, int height,
    • Jeremy Lainé
      Jeremy Lainé @jlaine · 4 years ago
      Contributor

      Is it possible to enforce keywords-only arguments in Cython? With the ever-increasing number of options I'm afraid this is going to turn into a footgun. Thoughts @mikeboers ?

    • Jeremy Lainé
      Jeremy Lainé @jlaine · 4 years ago
      Contributor

      .. and my question was a bit stupid, _reformat is purely internal, the user-facing API is reformat which is just regular Python

  • Administrator mentioned in issue #257 (closed) 3 years ago

    mentioned in issue #257 (closed)

  • Jeremy Lainé added changes requested label 3 years ago

    added changes requested label

  • Administrator restored source branch github/fork/johanjeppsson/main 2 years ago

    restored source branch github/fork/johanjeppsson/main

Please register or sign in to reply
0 Assignees
None
Assign to
0 Reviewers
None
Request review from
Labels
3
Docker Issue: Bug OpenAPI Generator Online
3
Docker Issue: Bug OpenAPI Generator Online
    Assign labels
  • Manage project labels

Milestone
3.0.0
3.0.0 (expired)
None
Time tracking
No estimate or time spent
Lock merge request
Unlocked
0
0 participants
Reference: OpenAPITools/openapi-generator!58
Source branch: github/fork/johanjeppsson/main

Menu

Explore Projects Groups Snippets