@@ -47,7 +47,7 @@ def __init__(self, video, base, skip, output):
47
47
self .metadata_path = self ._get_metadata_path ()
48
48
self ._perform_skip ()
49
49
50
- with Progress ("Extracting frames" , "Frames have been extracted " ):
50
+ with Progress ("Extracting the frames by the given interval " ):
51
51
self .extract_frames ()
52
52
53
53
def _get_metadata_path (self ):
@@ -103,14 +103,15 @@ def prepare_frames(self):
103
103
master = Image .new (mode = "RGBA" , size = next (thumbnails ))
104
104
master_path = os .path .join (self .thumbnail_dir , extract_name (self .filepath ) + ".png" )
105
105
106
- with Progress ("Processing frames" , "Frames have been merged into one " ) as progress :
106
+ with Progress ("Preprocessing the frames before merging " ) as progress :
107
107
for frame , * _ , x , y in thumbnails :
108
- progress .update ("Processing '%s'" % frame )
108
+ offset = extract_name (frame ).replace ("-" , ":" ).split ("." )[0 ]
109
+ progress .update ("Processing [bold]%s[/bold] frame" % offset )
109
110
with Image .open (frame ) as image :
110
111
image = image .resize ((self .width , self .height ), Image .ANTIALIAS )
111
112
master .paste (image , (x , y ))
112
113
113
- progress . update ("Saving the result '%s'" % master_path )
114
+ with Progress ("Saving the result at '%s'" % master_path ):
114
115
master .save (master_path )
115
116
116
117
def generate (self ):
@@ -123,7 +124,7 @@ def format_time(secs):
123
124
route = os .path .join (prefix , extract_name (self .filepath ) + ".png" )
124
125
route = pathlib .Path (route ).as_posix ()
125
126
126
- with Progress ("Generating thumbnail metadata" , "Thumbnail metadata has been generated" ) as progress :
127
+ with Progress ("Saving thumbnail metadata at '%s'" % self . metadata_path ) as progress :
127
128
for _ , start , end , x , y in self .thumbnails ():
128
129
progress .update ("Generating metadata for '%s'" % route )
129
130
thumbnail_data = "%s --> %s\n %s#xywh=%d,%d,%d,%d\n \n " % (
0 commit comments