mirror of
https://github.com/raysan5/raylib.git
synced 2025-11-12 21:38:47 +00:00
Reviewed formating
This commit is contained in:
@@ -61,7 +61,9 @@
|
|||||||
#elif !defined(HWND) && defined(_MSVC_LANG)
|
#elif !defined(HWND) && defined(_MSVC_LANG)
|
||||||
typedef struct HWND__ *HWND;
|
typedef struct HWND__ *HWND;
|
||||||
#endif
|
#endif
|
||||||
#include "../external/win32_clipboard.h"
|
|
||||||
|
#include "../external/win32_clipboard.h" // Clipboard image copy-paste
|
||||||
|
|
||||||
#define GLFW_EXPOSE_NATIVE_WIN32
|
#define GLFW_EXPOSE_NATIVE_WIN32
|
||||||
#define GLFW_NATIVE_INCLUDE_NONE // To avoid some symbols re-definition in windows.h
|
#define GLFW_NATIVE_INCLUDE_NONE // To avoid some symbols re-definition in windows.h
|
||||||
#include "GLFW/glfw3native.h"
|
#include "GLFW/glfw3native.h"
|
||||||
@@ -1030,10 +1032,10 @@ Image GetClipboardImage(void)
|
|||||||
int width = 0;
|
int width = 0;
|
||||||
int height = 0;
|
int height = 0;
|
||||||
|
|
||||||
fileData = (void*)Win32GetClipboardImageData(&width, &height, &dataSize);
|
fileData = (void *)Win32GetClipboardImageData(&width, &height, &dataSize);
|
||||||
|
|
||||||
if (fileData == NULL) TRACELOG(LOG_WARNING, "Clipboard image: Couldn't get clipboard data.");
|
if (fileData == NULL) TRACELOG(LOG_WARNING, "Clipboard image: Couldn't get clipboard data.");
|
||||||
else image = LoadImageFromMemory(".bmp", (const unsigned char*)fileData, (int)dataSize);
|
else image = LoadImageFromMemory(".bmp", (const unsigned char *)fileData, (int)dataSize);
|
||||||
#else
|
#else
|
||||||
TRACELOG(LOG_WARNING, "GetClipboardImage() not implemented on target platform");
|
TRACELOG(LOG_WARNING, "GetClipboardImage() not implemented on target platform");
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -1486,7 +1486,7 @@ int InitPlatform(void)
|
|||||||
|
|
||||||
platform.hbitmap = CreateDIBSection(
|
platform.hbitmap = CreateDIBSection(
|
||||||
platform.hdcmem, &bmi, DIB_RGB_COLORS,
|
platform.hdcmem, &bmi, DIB_RGB_COLORS,
|
||||||
(void**)&platform.pixels, NULL, 0);
|
(void **)&platform.pixels, NULL, 0);
|
||||||
|
|
||||||
SelectObject(platform.hdcmem, platform.hbitmap);
|
SelectObject(platform.hdcmem, platform.hbitmap);
|
||||||
|
|
||||||
|
|||||||
@@ -1587,7 +1587,7 @@ Music LoadMusicStreamFromMemory(const char *fileType, const unsigned char *data,
|
|||||||
else if ((strcmp(fileType, ".mp3") == 0) || (strcmp(fileType, ".MP3") == 0))
|
else if ((strcmp(fileType, ".mp3") == 0) || (strcmp(fileType, ".MP3") == 0))
|
||||||
{
|
{
|
||||||
drmp3 *ctxMp3 = (drmp3 *)RL_CALLOC(1, sizeof(drmp3));
|
drmp3 *ctxMp3 = (drmp3 *)RL_CALLOC(1, sizeof(drmp3));
|
||||||
int success = drmp3_init_memory(ctxMp3, (const void*)data, dataSize, NULL);
|
int success = drmp3_init_memory(ctxMp3, (const void *)data, dataSize, NULL);
|
||||||
|
|
||||||
if (success)
|
if (success)
|
||||||
{
|
{
|
||||||
@@ -1631,7 +1631,7 @@ Music LoadMusicStreamFromMemory(const char *fileType, const unsigned char *data,
|
|||||||
#if defined(SUPPORT_FILEFORMAT_FLAC)
|
#if defined(SUPPORT_FILEFORMAT_FLAC)
|
||||||
else if ((strcmp(fileType, ".flac") == 0) || (strcmp(fileType, ".FLAC") == 0))
|
else if ((strcmp(fileType, ".flac") == 0) || (strcmp(fileType, ".FLAC") == 0))
|
||||||
{
|
{
|
||||||
drflac *ctxFlac = drflac_open_memory((const void*)data, dataSize, NULL);
|
drflac *ctxFlac = drflac_open_memory((const void *)data, dataSize, NULL);
|
||||||
|
|
||||||
if (ctxFlac != NULL)
|
if (ctxFlac != NULL)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -3750,7 +3750,7 @@ void *rlReadTexturePixels(unsigned int id, int width, int height, int format)
|
|||||||
|
|
||||||
#if defined(GRAPHICS_API_OPENGL_11_SOFTWARE)
|
#if defined(GRAPHICS_API_OPENGL_11_SOFTWARE)
|
||||||
// Copy framebuffer pixel data to internal buffer
|
// Copy framebuffer pixel data to internal buffer
|
||||||
void rlCopyFramebuffer(int x, int y, int width, int height, int format, void* pixels)
|
void rlCopyFramebuffer(int x, int y, int width, int height, int format, void *pixels)
|
||||||
{
|
{
|
||||||
unsigned int glInternalFormat, glFormat, glType;
|
unsigned int glInternalFormat, glFormat, glType;
|
||||||
rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType); // Get OpenGL texture format
|
rlGetGlTextureFormats(format, &glInternalFormat, &glFormat, &glType); // Get OpenGL texture format
|
||||||
|
|||||||
Reference in New Issue
Block a user