mirror of
https://github.com/id-Software/DOOM-3-BFG.git
synced 2025-03-14 06:34:10 +00:00
Minor fixes related to jpeg/png libs -> stb changes
This commit is contained in:
parent
2478622e7c
commit
5ce9a3b1a6
3 changed files with 3 additions and 4 deletions
|
@ -281,12 +281,11 @@ if(APPLE)
|
|||
set(CMAKE_FIND_FRAMEWORK LAST)
|
||||
endif()
|
||||
|
||||
# SRS - search for system zlib only if we have not already searched via system libpng
|
||||
if(USE_SYSTEM_ZLIB)
|
||||
find_package(ZLIB)
|
||||
endif()
|
||||
|
||||
if (USE_SYSTEM_ZLIB AND ZLIB_FOUND)
|
||||
if(ZLIB_FOUND)
|
||||
include_directories(${ZLIB_INCLUDE_DIRS})
|
||||
set(ZLIB_LIBRARY ${ZLIB_LIBRARIES})
|
||||
else()
|
||||
|
|
|
@ -894,7 +894,7 @@ static int stbi_write_hdr_core( stbi__write_context* s, int x, int y, int comp,
|
|||
#ifdef __STDC_LIB_EXT1__
|
||||
len = sprintf_s( buffer, sizeof( buffer ), "EXPOSURE= 1.0000000000000\n\n-Y %d +X %d\n", y, x );
|
||||
#else
|
||||
len = sprintf( buffer, "EXPOSURE= 1.0000000000000\n\n-Y %d +X %d\n", y, x );
|
||||
len = snprintf( buffer, sizeof( buffer ), "EXPOSURE= 1.0000000000000\n\n-Y %d +X %d\n", y, x );
|
||||
#endif
|
||||
s->func( s->context, buffer, len );
|
||||
|
||||
|
|
|
@ -847,7 +847,7 @@ bool R_ReadPixelsRGB8( nvrhi::IDevice* device, CommonRenderPasses* pPasses, nvrh
|
|||
|
||||
// SRS - Save screen shots to fs_savepath on macOS (i.e. don't save into an app bundle's basepath)
|
||||
#if defined(__APPLE__)
|
||||
R_WritePNG( fullname, static_cast<byte*>( pData ), 4, desc.width, desc.height, true, "fs_savepath" );
|
||||
R_WritePNG( fullname, static_cast<byte*>( pData ), 4, desc.width, desc.height, "fs_savepath" );
|
||||
#else
|
||||
R_WritePNG( fullname, static_cast<byte*>( pData ), 4, desc.width, desc.height, "fs_basepath" );
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue