mirror of
https://github.com/microsoft/DirectXTex.git
synced 2025-12-06 15:21:43 +01:00
Code review fix for PNG Auxiliary (#643)
This commit is contained in:
parent
c027648890
commit
74f9b02475
@ -164,7 +164,7 @@ namespace
|
||||
if( png_get_gAMA( st, info, &gamma ) )
|
||||
{
|
||||
// If gamma == 1.0, then the data is internally linear.
|
||||
if( abs( gamma - 1.0 ) > 1e6 )
|
||||
if( abs( gamma - 1.0 ) > 1e-6 )
|
||||
png_set_gamma( st, screen_gamma, gamma );
|
||||
}
|
||||
}
|
||||
@ -216,7 +216,7 @@ namespace
|
||||
if( png_get_gAMA( st, info, &gamma ) )
|
||||
{
|
||||
// This PNG is explicitly linear.
|
||||
if( abs( gamma - 1.0 ) <= 1e6 )
|
||||
if( abs( gamma - 1.0 ) <= 1e-6 )
|
||||
return linear;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user