Skip to content
This repository was archived by the owner on Mar 19, 2025. It is now read-only.

Commit 6d50bd5

Browse files
committed
test.pl generate mipmaps for textures
1 parent 5dec82b commit 6d50bd5

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

test.pl

+3
Original file line numberDiff line numberDiff line change
@@ -586,6 +586,7 @@ sub ourBuildTextures
586586
0, $Tex_Format, $Tex_Size, 0);
587587
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR);
588588
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR);
589+
glGenerateMipmapEXT(GL_TEXTURE_2D);
589590

590591
# Bind texture/frame/render buffers
591592
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, $FrameBufferID);
@@ -742,6 +743,8 @@ sub cbRenderScene
742743
#glutSolidTeapot(0.25);
743744
glutWireTeapot(0.25);
744745
glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, 0);
746+
glBindTexture(GL_TEXTURE_2D, $TextureID_FBO);
747+
glGenerateMipmapEXT(GL_TEXTURE_2D);
745748

746749
if ($hasFragProg)
747750
{

0 commit comments

Comments
 (0)