Skip to content
This repository has been archived by the owner on Apr 5, 2024. It is now read-only.

Change video resolution #85

Open
cbarratt opened this issue Nov 6, 2020 · 1 comment
Open

Change video resolution #85

cbarratt opened this issue Nov 6, 2020 · 1 comment

Comments

@cbarratt
Copy link

cbarratt commented Nov 6, 2020

Is it possible at all to change the video resolution? It appears to be drastically low quality :( I was hoping for some environment variable to use for this

@sinclairnick
Copy link

in app/server.py change lines 15-16

        self.cap.set(3, 640)
        self.cap.set(4, 480)

640 = width
480 = height

If you want them to be environment variables, do something like

import os
...
CAP_WIDTH = os.environ.get("CAP_WIDTH", 640)
CAP_HEIGHT = os.environ.get("CAP_HEIGHT", 480)
...
        self.cap.set(3, CAP_HEIGHT)
        self.cap.set(4, CAP_WIDTH)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants