Skip to content

Commit

Permalink
Fix: [Server][VideoStream] 'pkt_dts' プロパティがないフレームがある録画でのエラーを修正
Browse files Browse the repository at this point in the history
  • Loading branch information
tsukumijima committed Nov 18, 2023
1 parent da7fd5c commit 68bacf5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/app/streams/VideoStream.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ async def getVirtualPlaylist(self) -> str:
# キーフレームの DTS (秒換算) を算出
keyframe_dts_second_list = [
int(frame['pkt_dts']) / ts.HZ # pkt_dts_time は ffprobe 側で丸められているので使わない
for frame in frames if int(frame['key_frame']) == 1
for frame in frames if 'pkt_dts' in frame and int(frame['key_frame']) == 1
]
print('keyframe_dts_second_list: ', end = '')
print(keyframe_dts_second_list)
Expand Down

0 comments on commit 68bacf5

Please sign in to comment.