From 0b650f62a6d185bc56970b3d8a0f8e1830bc3a2d Mon Sep 17 00:00:00 2001 From: Jeffery Myers Date: Thu, 24 Oct 2024 00:06:24 -0700 Subject: [PATCH 1/2] [RTEXTURES] Remove the panorama cubemap layout option (#4425) * Remove the panorama cubemap layout, it was not implemented. Left a todo in the code for some aspiring developer to finish. * Update raylib_api.* by CI --------- Co-authored-by: github-actions[bot] --- parser/output/raylib_api.json | 5 ----- parser/output/raylib_api.lua | 5 ----- parser/output/raylib_api.txt | 3 +-- parser/output/raylib_api.xml | 3 +-- src/raylib.h | 3 +-- src/rtextures.c | 8 +++----- 6 files changed, 6 insertions(+), 21 deletions(-) diff --git a/parser/output/raylib_api.json b/parser/output/raylib_api.json index 9db3d7ac..948ff45e 100644 --- a/parser/output/raylib_api.json +++ b/parser/output/raylib_api.json @@ -2839,11 +2839,6 @@ "name": "CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE", "value": 4, "description": "Layout is defined by a 4x3 cross with cubemap faces" - }, - { - "name": "CUBEMAP_LAYOUT_PANORAMA", - "value": 5, - "description": "Layout is defined by a panorama image (equirrectangular map)" } ] }, diff --git a/parser/output/raylib_api.lua b/parser/output/raylib_api.lua index d5492cb9..fb16decc 100644 --- a/parser/output/raylib_api.lua +++ b/parser/output/raylib_api.lua @@ -2839,11 +2839,6 @@ return { name = "CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE", value = 4, description = "Layout is defined by a 4x3 cross with cubemap faces" - }, - { - name = "CUBEMAP_LAYOUT_PANORAMA", - value = 5, - description = "Layout is defined by a panorama image (equirrectangular map)" } } }, diff --git a/parser/output/raylib_api.txt b/parser/output/raylib_api.txt index f6c79f85..2c107a89 100644 --- a/parser/output/raylib_api.txt +++ b/parser/output/raylib_api.txt @@ -889,7 +889,7 @@ Enum 14: TextureWrap (4 values) Value[TEXTURE_WRAP_CLAMP]: 1 Value[TEXTURE_WRAP_MIRROR_REPEAT]: 2 Value[TEXTURE_WRAP_MIRROR_CLAMP]: 3 -Enum 15: CubemapLayout (6 values) +Enum 15: CubemapLayout (5 values) Name: CubemapLayout Description: Cubemap layouts Value[CUBEMAP_LAYOUT_AUTO_DETECT]: 0 @@ -897,7 +897,6 @@ Enum 15: CubemapLayout (6 values) Value[CUBEMAP_LAYOUT_LINE_HORIZONTAL]: 2 Value[CUBEMAP_LAYOUT_CROSS_THREE_BY_FOUR]: 3 Value[CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE]: 4 - Value[CUBEMAP_LAYOUT_PANORAMA]: 5 Enum 16: FontType (3 values) Name: FontType Description: Font type, defines generation method diff --git a/parser/output/raylib_api.xml b/parser/output/raylib_api.xml index 6de5933d..29689bf6 100644 --- a/parser/output/raylib_api.xml +++ b/parser/output/raylib_api.xml @@ -595,13 +595,12 @@ - + - diff --git a/src/raylib.h b/src/raylib.h index 536b441b..aceb458c 100644 --- a/src/raylib.h +++ b/src/raylib.h @@ -877,8 +877,7 @@ typedef enum { CUBEMAP_LAYOUT_LINE_VERTICAL, // Layout is defined by a vertical line with faces CUBEMAP_LAYOUT_LINE_HORIZONTAL, // Layout is defined by a horizontal line with faces CUBEMAP_LAYOUT_CROSS_THREE_BY_FOUR, // Layout is defined by a 3x4 cross with cubemap faces - CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE, // Layout is defined by a 4x3 cross with cubemap faces - CUBEMAP_LAYOUT_PANORAMA // Layout is defined by a panorama image (equirrectangular map) + CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE // Layout is defined by a 4x3 cross with cubemap faces } CubemapLayout; // Font type, defines generation method diff --git a/src/rtextures.c b/src/rtextures.c index 23b32c1b..ca3ad099 100644 --- a/src/rtextures.c +++ b/src/rtextures.c @@ -4100,7 +4100,6 @@ TextureCubemap LoadTextureCubemap(Image image, int layout) { if ((image.width/6) == image.height) { layout = CUBEMAP_LAYOUT_LINE_HORIZONTAL; cubemap.width = image.width/6; } else if ((image.width/4) == (image.height/3)) { layout = CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE; cubemap.width = image.width/4; } - else if (image.width >= (int)((float)image.height*1.85f)) { layout = CUBEMAP_LAYOUT_PANORAMA; cubemap.width = image.width/4; } } else if (image.height > image.width) { @@ -4114,7 +4113,6 @@ TextureCubemap LoadTextureCubemap(Image image, int layout) if (layout == CUBEMAP_LAYOUT_LINE_HORIZONTAL) cubemap.width = image.width/6; if (layout == CUBEMAP_LAYOUT_CROSS_THREE_BY_FOUR) cubemap.width = image.width/3; if (layout == CUBEMAP_LAYOUT_CROSS_FOUR_BY_THREE) cubemap.width = image.width/4; - if (layout == CUBEMAP_LAYOUT_PANORAMA) cubemap.width = image.width/4; } cubemap.height = cubemap.width; @@ -4133,11 +4131,11 @@ TextureCubemap LoadTextureCubemap(Image image, int layout) { faces = ImageCopy(image); // Image data already follows expected convention } - else if (layout == CUBEMAP_LAYOUT_PANORAMA) + /*else if (layout == CUBEMAP_LAYOUT_PANORAMA) { - // TODO: Convert panorama image to square faces... + // TODO: implement panorama by converting image to square faces... // Ref: https://github.com/denivip/panorama/blob/master/panorama.cpp - } + } */ else { if (layout == CUBEMAP_LAYOUT_LINE_HORIZONTAL) for (int i = 0; i < 6; i++) faceRecs[i].x = (float)size*i; From f80a44c7294e1fe3e0a4c54d97a450c2981f6074 Mon Sep 17 00:00:00 2001 From: Ray Date: Thu, 24 Oct 2024 09:58:37 +0200 Subject: [PATCH 2/2] Update HISTORY.md --- HISTORY.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/HISTORY.md b/HISTORY.md index 035054db..555e81b3 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -471,3 +471,20 @@ Make sure to check raylib [CHANGELOG]([CHANGELOG](https://github.com/raysan5/ray Undoubtedly, this is the **biggest raylib update in 10 years**. Many new features and improvements with a special focus on maintainability and long-term sustainability. **Undoubtedly, this is the raylib of the future**. **Enjoy programming!** :) + +notes on raylib 5.5 +------------------- + +It's been **1 year** since latest raylib release and **11 years** since raylib 1.0 was officially released... + +Some numbers for this release: + + - **+260** closed issues (for a TOTAL of **+1800**!) + - **+700** commits since previous RELEASE (for a TOTAL of **+7670**!) + - **+30** functions ADDED to raylib API (for a TOTAL of **580**!) + - **+110** functions REVIEWED with fixes and improvements + - **+135** new contributors (for a TOTAL of **+635**!) + +Highlights for `raylib 5.5`: + +TODO.