i have a script, read this carefully i have fix something
- User
i have a script, read this carefully i have fix something
- Assistant
Of course! Please provide the script you'd like me to review, and let me know what specific issues or areas you'd like help with.
- User
- Assistant
Your script appears to be a Tkinter-based application for selecting and cropping areas of video frames and optionally flipping them horizontally. I’ve reviewed your code and here are a few suggestions and considerations that might improve the functionality or maintainability of your script:
- User
when i want to crop multiple long size videos, i get these errors Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'E:/3 sis bbc/videos/1.mp4': Metadata: major_brand : isom minor_version : 512 compatible_brands: isomiso2avc1mp41 encoder : Lavf58.45.100 Duration: 00:26:31.59, start: 0.000000, bitrate: 1161 kb/s Stream #0:00x1: Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(progressive), 496x882 [SAR 495:496 DAR 55:98], 1089 kb/s, 29.97 fps, 29.97 tbr, 30k tbn (default) Metadata: handler_name : VideoHandler vendor_id : [0][0][0][0] Stream #0:10x2: Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 64 kb/s (default) Metadata: handler_name : SoundHandler vendor_id : [0][0][0][0] Stream mapping: Stream #0:0 (h264) -> crop:default hflip:default -> Stream #0:0 (libx264) Stream #0:1 -> #0:1 (aac (native) -> aac (native)) Press [q] to stop, [?] for help [Parsed_crop_0 @ 000001d286881e80] Invalid too big or non positive size for width '688' or height '1138' [Parsed_crop_0 @ 000001d286881e80] Failed to configure input pad on Parsed_crop_0 [fc#0 @ 000001d2850e7f40] Error reinitializing filters! [fc#0 @ 000001d2850e7f40] Task finished with error code: -22 (Invalid argument) [fc#0 @ 000001d2850e7f40] Terminating thread with return code -22 (Invalid argument) [vost#0:0/libx264 @ 000001d285104940] Could not open encoder before EOF [vost#0:0/libx264 @ 000001d285104940] Task finished with error code: -22 (Invalid argument) [vost#0:0/libx264 @ 000001d285104940] Terminating thread with return code -22 (Invalid argument) [out#0/mp4 @ 000001d285108f40] Nothing was written into output file, because at least one of its streams received no packets. frame= 0 fps=0.0 q=0.0 Lsize= 0KiB time=N/A bitrate=N/A speed=N/A [aac @ 000001d286265c40] Qavg: 3401.810 Conversion failed! Error: 'NoneType' object has no attribute 'decode'
- Assistant
- User
you can add a feature so that it dont exceed limit even i select some more area...
- Assistant
- User
kindly provide me full script
- Assistant
- User
if go for cropping large size videos i get these errors again 30k tbn (default) Metadata: handler_name : VideoHandler vendor_id : [0][0][0][0] Stream #0:10x2: Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 64 kb/s (default) Metadata: handler_name : SoundHandler vendor_id : [0][0][0][0] Stream mapping: Stream #0:0 (h264) -> crop:default hflip:default -> Stream #0:0 (libx264) Stream #0:1 -> #0:1 (aac (native) -> aac (native)) Press [q] to stop, [?] for help [Parsed_crop_0 @ 00000157ca81ad00] Invalid too big or non positive size for width '702' or height '1162' [Parsed_crop_0 @ 00000157ca81ad00] Failed to configure input pad on Parsed_crop_0 [fc#0 @ 00000157c90b7f40] Error reinitializing filters! [fc#0 @ 00000157c90b7f40] Task finished with error code: -22 (Invalid argument) [fc#0 @ 00000157c90b7f40] Terminating thread with return code -22 (Invalid argument) [vost#0:0/libx264 @ 00000157c90d4940] Could not open encoder before EOF [vost#0:0/libx264 @ 00000157c90d4940] Task finished with error code: -22 (Invalid argument) [vost#0:0/libx264 @ 00000157c90d4940] Terminating thread with return code -22 (Invalid argument) [out#0/mp4 @ 00000157c90d8f40] Nothing was written into output file, because at least one of its streams received no packets.
- Assistant
- User
i already told you that modify the script so that if i select larger area it automatically fix the selection
- Assistant
- User
one think I want to remind you that each of the my videos may contain different different resolutions
- Assistant