ozmartian / vidcutter

A modern yet simple multi-platform video cutter and joiner.
GNU General Public License v3.0
1.8k stars 136 forks source link

Unable to open .TS video files #215

Open GR2I opened 5 years ago

GR2I commented 5 years ago

Starting with version 4.0.0 and following one's vidcuter cannot open files suffixed .ts Must keep using version 3.5.0 to succeed. I' m running Windows 10 x64 version 1809 The video's i'm trying to open are on external devices such as hard disks or USB Keys. Please advise Thanks G. Recher

geosone commented 3 years ago

even with the actual 6.0.0 opening ts files from tv recorder there is no timetable or similar to see

geosone commented 3 years ago

`2021-02-17 17:54 - vidcutter.libs.videoservice - INFO - /usr/bin/ffprobe -hide_banner -v error -show_streams -show_format -of json "/home/mario/Filme/Dr. Quinn - Ärztin aus Leidenschaft/Dr. Quinn - Ärztin aus Leidenschaft_2021-02-17_14531552.ts" 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] Testing FBO format rgba16f 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] Using FBO format rgba16f. 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] No advanced processing required. Enabling dumb mode. 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] Loading hwdec driver 'vaapi-egl' 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render/vaapi-egl] VAAPI hwdec only works with OpenGL or Vulkan backends. 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] Loading failed. 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] Loading hwdec driver 'vdpau-gl' 2021-02-17 17:54 - vidcutter.libs.mpvwidget - INFO - [libmpv_render] Loading failed. 2021-02-17 17:54 - vidcutter.libs.videoservice - INFO - cmd output: { "streams": [ { "index": 0, "codec_name": "h264", "codec_long_name": "H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10", "profile": "High", "codec_type": "video", "codec_time_base": "1/50", "codec_tag_string": "[27][0][0][0]", "codec_tag": "0x001b", "width": 720, "height": 576, "coded_width": 720, "coded_height": 576, "has_b_frames": 2, "sample_aspect_ratio": "16:11", "display_aspect_ratio": "20:11", "pix_fmt": "yuv420p", "level": 30, "color_range": "tv", "color_space": "bt470bg", "color_transfer": "bt470bg", "color_primaries": "bt470bg", "chroma_location": "left", "field_order": "tt", "refs": 1, "is_avc": "false", "nal_length_size": "0", "id": "0x13d8", "r_frame_rate": "25/1", "avg_frame_rate": "25/1", "time_base": "1/90000", "start_pts": 3913102580, "start_time": "43478.917556", "duration_ts": 336758400, "duration": "3741.760000", "bits_per_raw_sample": "8", "disposition": { "default": 0, "dub": 0, "original": 0, "comment": 0, "lyrics": 0, "karaoke": 0, "forced": 0, "hearing_impaired": 0, "visual_impaired": 0, "clean_effects": 0, "attached_pic": 0, "timed_thumbnails": 0 } }, { "index": 1, "codec_name": "eac3", "codec_long_name": "ATSC A/52B (AC-3, E-AC-3)", "codec_type": "audio", "codec_time_base": "1/48000", "codec_tag_string": "EAC3", "codec_tag": "0x33434145", "sample_fmt": "fltp", "sample_rate": "48000", "channels": 2, "channel_layout": "stereo", "bits_per_sample": 0, "dmix_mode": "-1", "ltrt_cmixlev": "-1.000000", "ltrt_surmixlev": "-1.000000", "loro_cmixlev": "-1.000000", "loro_surmixlev": "-1.000000", "id": "0x13d9", "r_frame_rate": "0/0", "avg_frame_rate": "0/0", "time_base": "1/90000", "start_pts": 3913015271, "start_time": "43477.947456", "duration_ts": 336767040, "duration": "3741.856000", "bit_rate": "96000", "disposition": { "default": 0, "dub": 0, "original": 0, "comment": 0, "lyrics": 0, "karaoke": 0, "forced": 0, "hearing_impaired": 0, "visual_impaired": 0, "clean_effects": 1, "attached_pic": 0, "timed_thumbnails": 0 }, "tags": { "language": "deu" } }, { "index": 2, "codec_name": "dvb_teletext", "codec_long_name": "DVB teletext", "codec_type": "subtitle", "codec_tag_string": "[6][0][0][0]", "codec_tag": "0x0006", "id": "0x13dd", "r_frame_rate": "0/0", "avg_frame_rate": "0/0", "time_base": "1/90000", "start_pts": 3913016180, "start_time": "43477.957556", "duration_ts": 336765600, "duration": "3741.840000", "disposition": { "default": 0, "dub": 0, "original": 0, "comment": 0, "lyrics": 0, "karaoke": 0, "forced": 0, "hearing_impaired": 0, "visual_impaired": 0, "clean_effects": 0, "attached_pic": 0, "timed_thumbnails": 0 }, "tags": { "language": "ger" } }, { "index": 3, "codec_tag_string": "[5][0][0][0]", "codec_tag": "0x0005", "id": "0x13de", "r_frame_rate": "0/0", "avg_frame_rate": "0/0", "time_base": "1/90000", "start_pts": 3913015271, "start_time": "43477.947456", "duration_ts": 336845709, "duration": "3742.730100", "disposition": { "default": 0, "dub": 0, "original": 0, "comment": 0, "lyrics": 0, "karaoke": 0, "forced": 0, "hearing_impaired": 0, "visual_impaired": 0, "clean_effects": 0, "attached_pic": 0, "timed_thumbnails": 0 } } ], "format": { "filename": "/home/mario/Filme/Dr. Quinn - Ärztin aus Leidenschaft/Dr. Quinn - Ärztin aus Leidenschaft_2021-02-17_14531552.ts", "nb_streams": 4, "nb_programs": 1, "format_name": "mpegts", "format_long_name": "MPEG-TS (MPEG-2 Transport Stream)", "start_time": "43477.947456", "duration": "3742.730100", "size": "851202524", "bit_rate": "1819425", "probe_score": 50 } } 2021-02-17 17:54 - vidcutter.libs.videoservice - INFO - Munch({'streams': [Munch({'index': 0, 'codec_name': 'h264', 'codec_long_name': 'H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10', 'profile': 'High', 'codec_type': 'video', 'codec_time_base': '1/50', 'codec_tag_string': '[27][0][0][0]', 'codec_tag': '0x001b', 'width': 720, 'height': 576, 'coded_width': 720, 'coded_height': 576, 'has_b_frames': 2, 'sample_aspect_ratio': '16:11', 'display_aspect_ratio': '20:11', 'pix_fmt': 'yuv420p', 'level': 30, 'color_range': 'tv', 'color_space': 'bt470bg', 'color_transfer': 'bt470bg', 'color_primaries': 'bt470bg', 'chroma_location': 'left', 'field_order': 'tt', 'refs': 1, 'is_avc': 'false', 'nal_length_size': '0', 'id': '0x13d8', 'r_frame_rate': '25/1', 'avg_frame_rate': '25/1', 'time_base': '1/90000', 'start_pts': 3913102580, 'start_time': '43478.917556', 'duration_ts': 336758400, 'duration': '3741.760000', 'bits_per_raw_sample': '8', 'disposition': Munch({'default': 0, 'dub': 0, 'original': 0, 'comment': 0, 'lyrics': 0, 'karaoke': 0, 'forced': 0, 'hearing_impaired': 0, 'visual_impaired': 0, 'clean_effects': 0, 'attached_pic': 0, 'timed_thumbnails': 0})}), Munch({'index': 1, 'codec_name': 'eac3', 'codec_long_name': 'ATSC A/52B (AC-3, E-AC-3)', 'codec_type': 'audio', 'codec_time_base': '1/48000', 'codec_tag_string': 'EAC3', 'codec_tag': '0x33434145', 'sample_fmt': 'fltp', 'sample_rate': '48000', 'channels': 2, 'channel_layout': 'stereo', 'bits_per_sample': 0, 'dmix_mode': '-1', 'ltrt_cmixlev': '-1.000000', 'ltrt_surmixlev': '-1.000000', 'loro_cmixlev': '-1.000000', 'loro_surmixlev': '-1.000000', 'id': '0x13d9', 'r_frame_rate': '0/0', 'avg_frame_rate': '0/0', 'time_base': '1/90000', 'start_pts': 3913015271, 'start_time': '43477.947456', 'duration_ts': 336767040, 'duration': '3741.856000', 'bit_rate': '96000', 'disposition': Munch({'default': 0, 'dub': 0, 'original': 0, 'comment': 0, 'lyrics': 0, 'karaoke': 0, 'forced': 0, 'hearing_impaired': 0, 'visual_impaired': 0, 'clean_effects': 1, 'attached_pic': 0, 'timed_thumbnails': 0}), 'tags': Munch({'language': 'deu'})}), Munch({'index': 2, 'codec_name': 'dvb_teletext', 'codec_long_name': 'DVB teletext', 'codec_type': 'subtitle', 'codec_tag_string': '[6][0][0][0]', 'codec_tag': '0x0006', 'id': '0x13dd', 'r_frame_rate': '0/0', 'avg_frame_rate': '0/0', 'time_base': '1/90000', 'start_pts': 3913016180, 'start_time': '43477.957556', 'duration_ts': 336765600, 'duration': '3741.840000', 'disposition': Munch({'default': 0, 'dub': 0, 'original': 0, 'comment': 0, 'lyrics': 0, 'karaoke': 0, 'forced': 0, 'hearing_impaired': 0, 'visual_impaired': 0, 'clean_effects': 0, 'attached_pic': 0, 'timed_thumbnails': 0}), 'tags': Munch({'language': 'ger'})}), Munch({'index': 3, 'codec_tag_string': '[5][0][0][0]', 'codec_tag': '0x0005', 'id': '0x13de', 'r_frame_rate': '0/0', 'avg_frame_rate': '0/0', 'time_base': '1/90000', 'start_pts': 3913015271, 'start_time': '43477.947456', 'duration_ts': 336845709, 'duration': '3742.730100', 'disposition': Munch({'default': 0, 'dub': 0, 'original': 0, 'comment': 0, 'lyrics': 0, 'karaoke': 0, 'forced': 0, 'hearing_impaired': 0, 'visual_impaired': 0, 'clean_effects': 0, 'attached_pic': 0, 'timed_thumbnails': 0})})], 'format': Munch({'filename': '/home/mario/Filme/Dr. Quinn - Ärztin aus Leidenschaft/Dr. Quinn - Ärztin aus Leidenschaft_2021-02-17_14531552.ts', 'nb_streams': 4, 'nb_programs': 1, 'format_name': 'mpegts', 'format_long_name': 'MPEG-TS (MPEG-2 Transport Stream)', 'start_time': '43477.947456', 'duration': '3742.730100', 'size': '851202524', 'bit_rate': '1819425', 'probe_score': 50})}) 2021-02-17 17:54 - root - CRITICAL - File "/usr/lib/python3.7/site-packages/vidcutter/videocutter.py", line 811, in openMedia self.loadMedia(filename) File "/usr/lib/python3.7/site-packages/vidcutter/videocutter.py", line 989, in loadMedia self.videoService.setMedia(self.currentMedia) File "/usr/lib/python3.7/site-packages/vidcutter/libs/videoservice.py", line 94, in setMedia [stream for stream in self.media.streams if stream.codec_type == codec_type.lower()]) File "/usr/lib/python3.7/site-packages/vidcutter/libs/videoservice.py", line 94, in [stream for stream in self.media.streams if stream.codec_type == codec_type.lower()]) File "/usr/lib/python3.7/site-packages/vidcutter/libs/munch.py", line 104, in getattr raise AttributeError(k)

2021-02-17 17:54 - root - CRITICAL - <class 'AttributeError'>: codec_type `

berndf commented 1 year ago

I had the same problem and it was fixed by pull request https://github.com/ozmartian/vidcutter/pull/381 for me - I'd vote for merging it!