实现 AppleHandler 和 SamsungHandler 类,处理特定于供应商的 HEIC 特性,添加查找嵌入视频的逻辑

This commit is contained in:
Nymiro
2025-10-20 12:10:59 +13:00
parent 8ee1d7984a
commit b4d35521cf
13 changed files with 144 additions and 38 deletions
+1 -2
View File
@@ -1,4 +1,3 @@
# In heic_types.py
import struct
from base import Box # <-- THIS IS THE KEY CHANGE
@@ -29,7 +28,7 @@ class ItemLocationBox(Box):
current_pos = 8
for _ in range(item_count):
item_id = struct.unpack('>H', stream[current_pos : current_pos+2])[0]
current_pos += 4 # Skip item_id and construction_method
current_pos += 2 # Skip construction_method
current_pos += 2 # Skip data_reference_index
current_pos += base_offset_size
extent_count = struct.unpack('>H', stream[current_pos : current_pos+2])[0]