tag:blogger.com,1999:blog-7720722570285165075.post2118272594538050911..comments2024-03-27T12:41:03.591+05:45Comments on Code in code::blocks: GLFW Tutorial 4: Texture mapping sample code in OpenGL FrameworkDinesh Subedihttp://www.blogger.com/profile/15921581026092958477noreply@blogger.comBlogger5125tag:blogger.com,1999:blog-7720722570285165075.post-1651801394902329092013-09-06T21:19:09.811+05:452013-09-06T21:19:09.811+05:45With the original code, the memory usage continual...With the original code, the memory usage continually increases because memory is allocated to load the texture on each call of the "display" function. A better method would be to load the texture once in an initialization step and then use that same loaded texture repeatedly for the display. Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-7720722570285165075.post-26715428938157029952012-08-13T20:12:18.935+05:452012-08-13T20:12:18.935+05:45Thanks @HeartyGFX you solved my mistake Thanks @HeartyGFX you solved my mistake Dinesh Subedihttps://www.blogger.com/profile/15921581026092958477noreply@blogger.comtag:blogger.com,1999:blog-7720722570285165075.post-26958453625769935752012-08-13T18:09:33.393+05:452012-08-13T18:09:33.393+05:45Hi,
Thank you, I'll follow the answer.
Actual...Hi,<br /><br />Thank you, I'll follow the answer.<br />Actually, I solved my problem<br />with an inelegant way:<br /><br /> glfwLoadTexture2D( "image.tga", GLFW_BUILD_MIPMAPS_BIT ); <br /> <br /> // Use trilinear interpolation for minification<br /> glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_LINEAR );<br /> // Use bilinear HeartyGFXhttps://www.blogger.com/profile/03079223076688390616noreply@blogger.comtag:blogger.com,1999:blog-7720722570285165075.post-52202982150701831752012-08-13T00:37:44.438+05:452012-08-13T00:37:44.438+05:45I have asked about problem here http://stackoverfl...I have asked about problem here http://stackoverflow.com/questions/11923885/memory-resource-increase-non-stop it might help youDinesh Subedihttps://www.blogger.com/profile/15921581026092958477noreply@blogger.comtag:blogger.com,1999:blog-7720722570285165075.post-54043402738512876842012-08-12T17:32:18.998+05:452012-08-12T17:32:18.998+05:45Hi,
I tried your code about texturing,
but I noti...Hi,<br /><br />I tried your code about texturing,<br />but I noticed a problem.<br /><br />The memory ressource increase non stop.<br />How to fix that?<br /><br />Have a nice day,HeartyGFXhttps://www.blogger.com/profile/03079223076688390616noreply@blogger.com