Savant
Savant copied to clipboard
Substitution patterns for image and video files sink
Closes #609
If the
DIR_LOCATIONhas%src_filename, the Video Files Sink creates only the directory only for the first filename from each source.
Image Files Sink has the same issue.
@tomskikh
Do you mean something like this:
src_location = get_tag_location(frame)
if Patterns.SOURCE_ID in self.location or Patterns.SRC_FILENAME in self.location:
if Patterns.SOURCE_ID in self.location:
base_location = get_location(self.location, frame.source_id, src_location)
else:
self.logger.error(f"{Patterns.SOURCE_ID} is required when {Patterns.SRC_FILENAME} is present.")
return Gst.FlowReturn.ERROR
else:
base_location = os.path.join(self.location, frame.source_id)
@Y-T-G No. Check DIR_LOCATION at the start of the sink: for image files sink in the method main, for video files sink in the script video_files.sh or in the method VideoFilesSink.do_set_property.
Will be fixed in #867 Closed.