python格式化整数
这是我从BMD Hyperdeck中获得的请求,它包含SD卡上的视频文件和视频的长度。我需要每个文件的长度,在我的代码列表中分开。这样的方法是什么?
b'206 disk list:\r\nslot id: 1\r\n1: Timecode.mp4 H.264 1080p25 00:01:00:00\r\n2: Video_1.mp4 H.264 1080p25 00:00:09:07\r\n3: Video_2.mp4 H.264 1080p25 00:00:07:04\r\n4: Video_3.mp4 H.264 1080p25 00:00:10:19\r\n5: Video_4.mp4 H.264 1080p25 00:00:04:16\r\n6: Video_5.mp4 H.264 1080p25 00:00:05:21\r\n\r\n'
This is the Request I get from an BMD Hyperdeck, it contains the Video-files on the SD-Cards an the lengths of the Videos. I need the lengths of every file, separate in a List for my Code. What would be the right way to something like this?
b'206 disk list:\r\nslot id: 1\r\n1: Timecode.mp4 H.264 1080p25 00:01:00:00\r\n2: Video_1.mp4 H.264 1080p25 00:00:09:07\r\n3: Video_2.mp4 H.264 1080p25 00:00:07:04\r\n4: Video_3.mp4 H.264 1080p25 00:00:10:19\r\n5: Video_4.mp4 H.264 1080p25 00:00:04:16\r\n6: Video_5.mp4 H.264 1080p25 00:00:05:21\r\n\r\n'
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这可以使用正则表达式和
Findall
来实现:This can be achieved using the regular expressions and
findall
: