yuzu/src/video_core/renderer_opengl/gl_shader_util.h

29 lines
665 B
C
Raw Normal View History

2020-12-28 15:15:37 +00:00
// Copyright 2014 Citra Emulator Project
// Licensed under GPLv2 or any later version
// Refer to the license.txt file included.
#pragma once
2021-07-09 23:54:15 +02:00
#include <span>
2020-12-28 15:15:37 +00:00
#include <string>
2021-07-09 23:54:15 +02:00
#include <string_view>
2020-12-28 15:15:37 +00:00
#include <vector>
2021-07-09 23:54:15 +02:00
2020-12-28 15:15:37 +00:00
#include <glad/glad.h>
2021-07-09 23:54:15 +02:00
2020-12-28 15:15:37 +00:00
#include "common/assert.h"
#include "common/logging/log.h"
2021-07-09 23:54:15 +02:00
#include "video_core/renderer_opengl/gl_resource_manager.h"
2020-12-28 15:15:37 +00:00
2021-07-09 23:54:15 +02:00
namespace OpenGL {
2020-12-28 15:15:37 +00:00
2021-07-09 23:54:15 +02:00
void AttachShader(GLenum stage, GLuint program, std::string_view code);
2020-12-28 15:15:37 +00:00
2021-07-09 23:54:15 +02:00
void AttachShader(GLenum stage, GLuint program, std::span<const u32> code);
2020-12-28 15:15:37 +00:00
2021-07-09 23:54:15 +02:00
void LinkProgram(GLuint program);
2020-12-28 15:15:37 +00:00
2021-07-09 23:54:15 +02:00
OGLAssemblyProgram CompileProgram(std::string_view code, GLenum target);
2020-12-28 15:15:37 +00:00
2021-07-09 23:54:15 +02:00
} // namespace OpenGL