Open peterstamps opened 9 months ago
Hi peterstamps, Can you share info/link on the image encoding for the raw .ts ? I would like to get an image without ffmpeg or jpeg compression.
I changed the convert.py and downloader.py (bot attached) a little and added a variable to the def function(s) called method. method == "ffmpeg" means that I use the original and get the .mp4 output method == "raw" means I get the .ts output (see line 24 in convert.py)
Also in Downloader I changed something. Search for "method" and some comments with "peter" in it.
That is how it got .ts raw files. Pretty simple at the end.
Op wo 22 mei 2024 om 12:23 schreef Manuel YGUEL @.***>:
Hi peterstamps, Can you share info/link on the image encoding for the raw .ts ? I would like to get an image without ffmpeg or jpeg compression.
— Reply to this email directly, view it on GitHub https://github.com/JurajNyiri/pytapo/issues/94#issuecomment-2124445020, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAW36FV2ZGYSAJ6TUNDVYR3ZDRW33AVCNFSM6AAAAABAF2ILZWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMRUGQ2DKMBSGA . You are receiving this because you authored the thread.Message ID: @.***>
@peterstamps feel free to open PR
I have modified/tweaked the convert.py and downloader.py and provide the functions with a variable called method. When method == 'raw' the convert.py module saves the raw .ts version downloaded from Tapo and skips the ffmpeg conversion to .mp4. When method == 'ffmpeg' the usual .mp4 will be created. On Ubuntu and also Windows 10/11 you can simply view the .ts file and hear the audio as well. On Ubuntu mpv Media Player, SMPlayer, VLC work with the .ts file.
So a conversion is not (always) per se needed.
Thanks when you build it in as a config option.