https://github.com/hasferrr/video-chapter-generator
XML file chapter generator for MKV video file.
https://github.com/hasferrr/video-chapter-generator
mkvtoolnix python xml-generator
Last synced: 11 months ago
JSON representation
XML file chapter generator for MKV video file.
- Host: GitHub
- URL: https://github.com/hasferrr/video-chapter-generator
- Owner: hasferrr
- Created: 2022-12-04T04:56:39.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2024-06-06T02:37:18.000Z (about 2 years ago)
- Last Synced: 2025-07-19T13:50:44.262Z (11 months ago)
- Topics: mkvtoolnix, python, xml-generator
- Language: Python
- Homepage:
- Size: 401 KB
- Stars: 6
- Watchers: 1
- Forks: 4
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Video Chapter Generator
(Python Script) This script consumes **input.csv** file and produces a video chapter file for the MKV format video **output.xml**

## Usage
```bash
python app.py file.csv output.xml
```
## Description
### Input
The contents of the input file must be exactly as in the file [test.csv](example/test.csv)
- 1st column: timestamp
- 2nd column: chapters name
```c
00:00:00,Introduction
00:00:24,Object-Oriented Programming
00:01:00,Tuples
00:18:39,Dictionaries
00:26:45,Classes and Objects
00:39:18,Instance Methods
00:59:49,Validating Attributes
01:04:25,The String Method
01:11:13,Custom Methods
01:20:43,"Properties, Getters, and Setters"
01:42:33,Types and Classes
01:50:29,Class Methods
02:21:10,Inheritance
02:35:29,Operator Overloading
02:50:03,Conclusion
```
### Process
**input.csv** file will be processed or formatted into an **output.xml** file for the chapter file.
### Output
Example output file: [test-output.xml](example/test-output.xml)
```xml
1
123456789012345678
3000000001
00:00:00.000000000
Introduction
und
und
...
3000000015
02:50:03.000000000
Conclusion
und
und
```
### MKV
The output is in the form of an **output.xml** file that can be embedded/merged into an **MKV** format video file.
See :
- [MKVToolNix GUI](https://mkvtoolnix.download/)
- [mkvmerge documentation](https://mkvtoolnix.download/doc/mkvmerge.html)