#include "shaders/program_manager.hpp" #include "shaders/metal_program_params.hpp" #include "shaders/metal_program_pool.hpp" #include "drape/metal/metal_base_context.hpp" namespace gpu { void ProgramManager::InitForMetal(ref_ptr context) { ASSERT(dynamic_cast(context.get()) != nullptr, ()); ref_ptr metalContext = context; m_pool = make_unique_dp(metalContext->GetMetalDevice()); m_paramsSetter = make_unique_dp(); ref_ptr metalPool = make_ref(m_pool); metalContext->SetSystemPrograms(metalPool->GetSystemProgram(SystemProgram::ClearColor), metalPool->GetSystemProgram(SystemProgram::ClearDepth), metalPool->GetSystemProgram(SystemProgram::ClearColorAndDepth)); } } // namespace gpu