set(MODULE_NAME visual_elements)

list(APPEND visual_elements_LIB_INCLUDES
    basic_shapes/RectangleNode.h
    basic_shapes/RectangleNode.cpp
    basic_shapes/CircleNode.h
    basic_shapes/CircleNode.cpp
    basic_shapes/LineNode.h
    basic_shapes/LineNode.cpp
	basic_shapes/PolygonNode.h
	basic_shapes/PolygonNode.cpp
    scene/Scene.h
    scene/Scene.cpp
	scene/SceneInfo.h
    scene/SceneModel.h
    scene/SceneModel.cpp
    scene/SceneItem.h
    scene/SceneItem.cpp
    scene/SceneText.h
    scene/SceneText.cpp
	svg/SvgNode.h
	svg/SvgNode.cpp
	svg/SvgDocument.h
    svg/SvgWriter.h
	svg/SvgReader.h
	svg/SvgPainter.h
	svg/SvgPainter.cpp
    svg/SvgShapeElement.h
    svg/SvgElement.h
	svg/SvgTextElement.h
	svg/SvgTextElement.cpp
    svg/elements/SvgShapeElements.h
    svg/SvgDocument.cpp
	svg/SvgReader.cpp
    svg/SvgWriter.cpp
    svg/SvgShapeElement.cpp
    svg/SvgElement.cpp
    svg/elements/SvgShapeElements.cpp
    nodes/MaterialNode.h
    nodes/MaterialNode.cpp
	nodes/PathNode.h
	nodes/PathNode.cpp
	nodes/ImageNode.h
	nodes/ImageNode.cpp
	nodes/LineEndNode.h
	nodes/LineEndNode.cpp
    nodes/MeshNode.h
    nodes/MeshNode.cpp
    nodes/TextNode.h
    nodes/TextNode.cpp
    nodes/GridNode.h
    nodes/GridNode.cpp
    nodes/GeometryNode.h
    nodes/GeometryNode.cpp
    nodes/AbstractVisualNode.h
    nodes/AbstractVisualNode.cpp
	Material.h
	BasicMaterial.h
	BasicMaterial.cpp
    Texture.cpp
)

add_library(${MODULE_NAME} SHARED ${visual_elements_LIB_INCLUDES})

target_include_directories(${MODULE_NAME} PUBLIC
                          ${CMAKE_CURRENT_SOURCE_DIR}
                          ${CMAKE_CURRENT_SOURCE_DIR}/basic_shapes
                          ${CMAKE_CURRENT_SOURCE_DIR}/scene
                          ${CMAKE_CURRENT_SOURCE_DIR}/nodes
						  ${CMAKE_CURRENT_SOURCE_DIR}/svg
                          ${CMAKE_CURRENT_SOURCE_DIR}/svg/elements
                          )

target_link_libraries(${MODULE_NAME} PUBLIC core geometry fonts mesh image)

set_property(TARGET ${MODULE_NAME} PROPERTY FOLDER src/rendering)
set_target_properties( ${MODULE_NAME} PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON ) 
