2
0
mirror of https://github.com/Laupetin/OpenAssetTools.git synced 2025-09-05 16:27:27 +00:00

refactor: extract image code into single component

This commit is contained in:
Jan
2024-09-27 21:16:29 +02:00
parent a2d70c17ba
commit 2dccd423af
46 changed files with 66 additions and 13 deletions

47
src/ObjImage.lua Normal file
View File

@@ -0,0 +1,47 @@
ObjImage = {}
function ObjImage:include(includes)
if includes:handle(self:name()) then
includedirs {
path.join(ProjectFolder(), "ObjImage")
}
end
end
function ObjImage:link(links)
links:add(self:name())
links:linkto(Utils)
end
function ObjImage:use()
end
function ObjImage:name()
return "ObjImage"
end
function ObjImage:project()
local folder = ProjectFolder()
local includes = Includes:create()
project(self:name())
targetdir(TargetDirectoryLib)
location "%{wks.location}/src/%{prj.name}"
kind "StaticLib"
language "C++"
files {
path.join(folder, "ObjImage/**.h"),
path.join(folder, "ObjImage/**.cpp")
}
vpaths {
["*"] = {
path.join(folder, "ObjImage")
}
}
self:include(includes)
Utils:include(includes)
end