def _imported_module(self):
"""Load the module this adapter points at."""
pyname = os.path.splitext(os.path.basename(self.module_abs_path()))[0]
pydir = os.path.dirname(self.module_abs_path())
(file_obj, pathname, description) = imp.find_module(pyname, [pydir])
with file_obj:
# this will reload the module if it has already been loaded.
mod = imp.load_module(
"opentimelineio.adapters.{}".format(self.name),
file_obj,
pathname,
description
)
return mod
python_plugin.py 文件源码
python
阅读 19
收藏 0
点赞 0
评论 0
评论列表
文章目录