mirror of
https://github.com/leozide/leocad
synced 2024-11-17 07:47:55 +01:00
Fixed mipmap generation bug.
This commit is contained in:
parent
5cd24e9921
commit
92dc1315f5
1 changed files with 2 additions and 1 deletions
|
@ -102,13 +102,14 @@ bool lcTexture::Load(Image* images, int NumLevels, int Flags)
|
|||
|
||||
for (int Level = 1; ((Width != 1) || (Height != 1)); Level++)
|
||||
{
|
||||
int RowStride = Width * Components;
|
||||
|
||||
Width = lcMax(1, Width >> 1);
|
||||
Height = lcMax(1, Height >> 1);
|
||||
|
||||
if (NumLevels == 1)
|
||||
{
|
||||
GLubyte *Out, *In;
|
||||
int RowStride = Width * Components;
|
||||
|
||||
In = Out = (GLubyte*)Data;
|
||||
|
||||
|
|
Loading…
Reference in a new issue