Skip to content

Commit 19f9573

Browse files
ntrrgcmildsunrise
authored andcommitted
Use tabs consistently
Replace usage of spaces in code with tabs.
1 parent c3f16b5 commit 19f9573

File tree

3 files changed

+21
-21
lines changed

3 files changed

+21
-21
lines changed

boxes.py

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -937,15 +937,15 @@ def parse_udta_box(ps: Parser):
937937
raise AssertionError(f'Optional udta trailer must be a single 32-bit zero, found: {trailer}')
938938

939939
def parse_dcom_box(ps: Parser):
940-
ps.field('compression_method', ps.fourcc())
940+
ps.field('compression_method', ps.fourcc())
941941

942942
def parse_cmvd_box(ps: Parser):
943-
ps.field('uncompressed_size', ps.int(4))
944-
compressed_bytes = ps.field_dump('compressed_bytes')
945-
import zlib
946-
uncompressed_bytes = zlib.decompress(compressed_bytes)
947-
sub_ps = Parser(memoryview(uncompressed_bytes), 0, ps.indent)
948-
parse_boxes(sub_ps)
943+
ps.field('uncompressed_size', ps.int(4))
944+
compressed_bytes = ps.field_dump('compressed_bytes')
945+
import zlib
946+
uncompressed_bytes = zlib.decompress(compressed_bytes)
947+
sub_ps = Parser(memoryview(uncompressed_bytes), 0, ps.indent)
948+
parse_boxes(sub_ps)
949949

950950
# EMSG
951951

parser_tables.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -330,10 +330,10 @@
330330
'mdta': ('QuickTimeMetadataBox', 'Box'),
331331
'gmhd': ('BaseMediaInformationHeaderBox', 'Box'),
332332
'gmin': ('BaseMediaInfoBox', 'Box'),
333-
'ftab': ('FontTableBox', 'Box'),
334-
'cmov': ('CompressedMovieBox', 'Box'),
335-
'dcom': ('DataCompressionBox', 'Box'),
336-
'cmvd': ('CompressedMovieDataBox', 'Box'),
333+
'ftab': ('FontTableBox', 'Box'),
334+
'cmov': ('CompressedMovieBox', 'Box'),
335+
'dcom': ('DataCompressionBox', 'Box'),
336+
'cmvd': ('CompressedMovieDataBox', 'Box'),
337337
}),
338338
({
339339
'title': 'Video File Format Specification',
@@ -343,7 +343,7 @@
343343
# class names guessed; the F4V spec doesn't give boxes names other than their FourCC's
344344
'chpl': ('ChapterListBox', 'FullBox'),
345345
}),
346-
({
346+
({
347347
'name': 'ISO/IEC 23009-1',
348348
'title': 'Information technology — Dynamic adaptive streaming over HTTP (DASH) — Part 1: Media presentation description and segment formats',
349349
'alias': 'DASH',

tests/update-usage.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,17 @@
99

1010
# we could also import options.py and do parser.format_help(), but I like the wrapping...
1111
helpstr = run(["./mp4parser.py", "--help"],
12-
check=True, capture_output=True, encoding="utf-8").stdout
12+
check=True, capture_output=True, encoding="utf-8").stdout
1313

1414
helpstr = f'```\n{helpstr}```\n'
1515

1616
with open('README.md', 'r+') as f:
17-
text = list(f)
18-
idx1 = text.index('<!-- BEGIN USAGE -->\n')
19-
idx2 = text.index('<!-- END USAGE -->\n')
20-
assert idx1 < idx2
21-
text = text[:idx1+1] + [helpstr] + text[idx2:]
22-
f.seek(0)
23-
f.truncate(0)
24-
f.write(''.join(text))
17+
text = list(f)
18+
idx1 = text.index('<!-- BEGIN USAGE -->\n')
19+
idx2 = text.index('<!-- END USAGE -->\n')
20+
assert idx1 < idx2
21+
text = text[:idx1+1] + [helpstr] + text[idx2:]
22+
f.seek(0)
23+
f.truncate(0)
24+
f.write(''.join(text))
2525

0 commit comments

Comments
 (0)