MCPcopy Create free account
hub / github.com/OpenShot/libopenshot / get_file_extension

Method get_file_extension

src/Clip.cpp:561–570  ·  view source on GitHub ↗

Get file extension

Source from the content-addressed store, hash-verified

559
560// Get file extension
561std::string Clip::get_file_extension(std::string path)
562{
563 // Return last part of path safely (handle filenames without a dot)
564 const auto dot_pos = path.find_last_of('.');
565 if (dot_pos == std::string::npos || dot_pos + 1 >= path.size()) {
566 return std::string();
567 }
568
569 return path.substr(dot_pos + 1);
570}
571
572// Adjust the audio and image of a time mapped frame
573void Clip::apply_timemapping(std::shared_ptr<Frame> frame)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected