Skip to content

Commit

Permalink
v1.2.2 | 2024/08/09 13:09 | Added more precision options to ABS-Fract…
Browse files Browse the repository at this point in the history
…al explorer, increasing the maximum zoom along with improving performance.
  • Loading branch information
ZERICO2005 committed Aug 9, 2024
1 parent 5f6285d commit a7b6c5f
Show file tree
Hide file tree
Showing 16 changed files with 1,120 additions and 1,062 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
desktop.ini
.vscode
.vs
imgui.ini
.cache
.cache
out
CMakeSettings.json
22 changes: 11 additions & 11 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "./bin")
# GCC quadmath __float128
set(FEATURE_Float128 "")

# Requires libqd.a
# (Deprecated) Requires libqd.a
# set(FEATURE_LIBQD "")

# MPFR converts between dekker-floats and strings
# MPFR converts between coordinates and strings
set(FEATURE_FloatMPFR "")

# GPU Rendering (OpenCL 1.2 or later)
Expand All @@ -35,9 +35,6 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "./bin")
# Requires libquadmath.a
# set(STATIC_OpenCV_Scaler "")

# Defines the NDEBUG macro to disable <cassert>
# target_compile_definitions(${PROJECT_NAME} PRIVATE NDEBUG)

# Long compile times! Optimizes and reduces the size of the binary for release
# set(COMPILE_FLTO "")

Expand All @@ -54,7 +51,7 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "./bin")
set(LIBRARY_OPT_FLAG -O3)
# -Ofast appears to have a noticable speedup compared to -O3 for SSE2 and AVX rendering.
set(RENDER_CPU_OPT_FLAG -Ofast)
set(MARCH_FLAGS -msse2)
set(MARCH_FLAGS -msse3)

# Source Files
file(GLOB_RECURSE SRC_FILES
Expand All @@ -70,11 +67,13 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "./bin")
endif()



file(GLOB SRC_AVX_FILES "${SRC_DIR}/render_CPU/frac_Multi_AVX.cpp")
set_source_files_properties(SOURCE ${SRC_AVX_FILES} PROPERTY COMPILE_FLAGS "-mavx ${RENDER_CPU_OPT_FLAG}")
file(GLOB SRC_AVX_FILES "${SRC_DIR}/render_CPU/frac_Multi_SSE2.cpp")
set_source_files_properties(SOURCE ${SRC_AVX_FILES} PROPERTY COMPILE_FLAGS "${RENDER_CPU_OPT_FLAG}")
file(GLOB SRC_AVX_FILES "${SRC_DIR}/render_CPU/frac_Multi_AVX.cpp")
set_source_files_properties(SOURCE ${SRC_AVX_FILES} PROPERTY COMPILE_FLAGS "-mavx ${RENDER_CPU_OPT_FLAG}")
file(GLOB SRC_AVX_FILES "${SRC_DIR}/render_CPU/frac_Multi_Float64x2_AVX.cpp")
set_source_files_properties(SOURCE ${SRC_AVX_FILES} PROPERTY COMPILE_FLAGS "-mavx ${PROGRAM_OPT_FLAG}")


# Icon
set(ICON_FILE "./icons/ABS-Icon.o")
Expand All @@ -89,6 +88,9 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "./bin")
# Packages and Macros
find_package(SDL2 REQUIRED)

# Defines the NDEBUG macro to disable <cassert>
# target_compile_definitions(${PROJECT_NAME} PRIVATE NDEBUG)

if(DEFINED FEATURE_Float80)
target_compile_definitions(${PROJECT_NAME} PRIVATE Enable_Float80)
endif()
Expand Down Expand Up @@ -170,8 +172,6 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "./bin")

# Compile Options

set(MARCH_FLAGS -msse3 -mavx)

set(WARNING_FLAGS
-Wall -Wextra -Wshadow
-Werror=infinite-recursion
Expand Down
10 changes: 8 additions & 2 deletions docs/Build-Instructions.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Build Instructions<br>
ABS-Fractal-Explorer v1.2.1 rev-2
ABS-Fractal-Explorer v1.2.2

Updated: 2024/06/09
Updated: 2024/08/09

You can read this guide:
https://github.com/ZERICO2005/ABS-Fractal-Explorer/wiki/How-to-Compile
Expand All @@ -16,9 +16,15 @@ Enables 80bit floats (`long double` or `__float80`) for extra precision. Used to
## Float128
Enables 128bit floats (quadmath.h) for extra precision. Used to store cordinates if it is the highest available precision.

## libqd
(Deprecated) Experimental double-double/quad-double float support. May require some manual configuration to enable it as a rendering mode.

## OpenCL
Enables OpenCL GPU rendering

## MPFR
Used to convert between coordinates and strings

## WindowsFileIO
(Not implemented in v1.2.1 rev-2)<br>
Uses the Windows file dialogs instead of the generic ones
Expand Down
13 changes: 12 additions & 1 deletion docs/Libraries-Used.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,22 @@ Used for GPU rendering
https://gcc.gnu.org/onlinedocs/libquadmath/
Used for high precision 128bit float calculations

## MPFR
Used for converting between coordinates and strings with greater accuracy.

## libQD
https://www.davidhbailey.com/dhbsoftware/
Used for experimental quad-double and double-double arithmetic support.

## LIB-Dekker-Float
https://github.com/ZERICO2005/LIB-Dekker-Float
A header-only library I wrote for the Dekker float implementations used in ABS-Fractal-Explorer. Float64x2 is roughly the same speed as dd_real in libQD, while Float64x2 AVX is ~3.3x faster for rendering fractals.

## STB Image
https://github.com/nothings/stb
Used for writing PNG/JPG images

## OpenCV
https://opencv.org/
Used for frame scaling in custom versions of ABS-Fractal-Explorer
Used for frame scaling in some versions of ABS-Fractal-Explorer

8 changes: 5 additions & 3 deletions docs/README.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ABS-Fractal-Explorer v1.2.1 (Revision-2) (Windows 10 Edition)
zerico2005 | 2024/06/09
ABS-Fractal-Explorer v1.2.2 (Windows 10 Edition)
zerico2005 | 2024/08/09

ABS-Fractal-Explorer will allow you to explore hundereds of different Mandelbrot variants. From Quadratic to Sextic fractals, there is always something new and novel to explore!

Expand Down Expand Up @@ -30,7 +30,9 @@ Controls (Full controls/keybinds are in the Key-binds Menu):
;": Inc/dec supersampling (Renders at higher quality but is much slower)
M : fp32 GPU rendering (10^5.7 max zoom, fastest)
N : fp64 CPU rendering (10^14.4 max zoom)
B : fp80 CPU rendering (10^17.7 max zoom)
B : fp80 CPU rendering (10^17.8 max zoom)
Rctrl: fp64x2 CPU rendering (10^30.7 max zoom)
View the rendering menu for more precision options.
Julia-Sets:
C: Toggle Julia Sets
V: Toggle Starting Z-Value
Expand Down
5 changes: 5 additions & 0 deletions docs/Update-Log.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
ABS-Fractal-Explorer Update-Log

# v1.2.2 (2024/08/09)
* Added Dekker floats, increasing the maximum precision from 10^32.5 to 10^36.7
* Precisions added: Float32x2 (10^12.6), Float64x2 (10^30.7), Float80x2 (10^36.7)
* General improvements and bug fixes.

# v1.2.1 (Revision-2) (2024/06/09)
* Corrected color averaging algorithm

Expand Down
14 changes: 8 additions & 6 deletions src/Program_Def.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,12 @@
#else

int FloatCoordinate_snprintf(char* buf, size_t len, const char* format, fpCord cord) {
#if defined(Enable_Float128)
#if defined(Enable_Float80)
return Float80x2_snprintf(buf, len, format, cord);
#elif defined(Enable_Float128)
return quadmath_snprintf(buf, len, format, (fp128)cord);
#else
return snprintf(buf, len, format, cord);
return Float64x2_snprintf(buf, len, format, cord);
#endif
}

Expand Down Expand Up @@ -174,12 +176,12 @@
}

fpCord stringTo_FloatCoordinate(const char* nPtr, char** endPtr) {
#if defined(Enable_Float128)
#if defined(Enable_Float80)
return (fpCord)stringTo_Float80x2(nPtr, endPtr);
#elif defined(Enable_Float128)
return (fpCord)stringTo_Float128(nPtr, endPtr);
#elif defined(Enable_Float80)
return (fpCord)stringTo_Float80(nPtr, endPtr);
#else
return (fpCord)stringTo_Float64(nPtr, endPtr);
return (fpCord)stringTo_Float64x2(nPtr, endPtr);
#endif
}

Expand Down
6 changes: 3 additions & 3 deletions src/Program_Def.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,11 +37,11 @@
/* Version */

#define PROGRAM_NAME "ABS-Fractal-Explorer"
#define PROGRAM_DATE "2024/08/08" /* YYYY/MM/DD */
#define PROGRAM_DATE "2024/08/09" /* YYYY/MM/DD */
#define PROGRAM_V_MAJOR 1
#define PROGRAM_V_MINOR 2
#define PROGRAM_V_PATCH 1
#define PROGRAM_V_TAG "(Revision-12)"
#define PROGRAM_V_PATCH 2
#define PROGRAM_V_TAG ""
#define PROGRAM_VERSION STR_N(PROGRAM_V_MAJOR) "." STR_N(PROGRAM_V_MINOR) "." STR_N(PROGRAM_V_PATCH) " " PROGRAM_V_TAG

/* Float80 and Float128 */
Expand Down
Loading

0 comments on commit a7b6c5f

Please sign in to comment.