小编Nin*_*ang的帖子

OpenGL 纹理状态使用警告:

OpenGL 向我发送垃圾邮件错误Severity: GL_DEBUG_SEVERITY_LOW, Source: GL_DEBUG_SOURCE_API, Type: GL_DEBUG_TYPE_OTHER Texture state usage warning: The texture object (1) bound to texture image unit 0 does not have a defined base level and cannot be used for texture mapping. 或仅在glDrawElements. 原因是为我的游戏引擎设置纹理。

我试图设置glPixelStorei(GL_UNPACK_ALIGNMENT, 1);. 其他解决方案是胡说八道或理论上的。其他解决方案是指与我的问题类似的问题/答案。

在从中型游戏引擎中煞费苦心地剥离 opengl 代码后,这里是代码:

#include <iostream>
#include <GLFW/glfw3.h>
#include <glad/glad.h>
#include <glm/glm.hpp>
#include <string>
#include <stb_image.h>
#include <cstring>

#include <stdint.h>
#include <string>

typedef uint64_t uint64;
typedef uint32_t uint32;
typedef uint16_t uint16;
typedef uint8_t uint8;

typedef int64_t …
Run Code Online (Sandbox Code Playgroud)

c++ opengl

-1
推荐指数
1
解决办法
1122
查看次数

标签 统计

c++ ×1

opengl ×1