• src/conio/scale.c

    From Deuc¿@VERT to Git commit to main/sbbs/master on Sunday, April 30, 2023 23:55:12
    https://gitlab.synchro.net/main/sbbs/-/commit/3d8c103ac68b26d823749c94
    Modified Files:
    src/conio/scale.c
    Log Message:
    Fix off-by-one error and increase precision

    Cleans up artifacts in interpolated values nicely.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Monday, May 01, 2023 09:16:26
    https://gitlab.synchro.net/main/sbbs/-/commit/2d915f2b0149c11b98b68d5d
    Modified Files:
    src/conio/scale.c
    Log Message:
    Scaling optimizations

    Use weight == 0 instead of int == double when deciding to copy pixel
    When interpolating width, do it by column, not row

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Monday, July 03, 2023 22:58:58
    https://gitlab.synchro.net/main/sbbs/-/commit/476f5e8a5f2b11e42c5e19dc
    Modified Files:
    src/conio/scale.c
    Log Message:
    UBSan claims this is undefined behaviour...

    I don't believe them, but I'll fix it anyway.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Tuesday, October 22, 2024 13:51:54
    https://gitlab.synchro.net/main/sbbs/-/commit/19e20fd9e27799f0c9bc77bd
    Modified Files:
    src/conio/scale.c
    Log Message:
    Decorate some arguments to allow compiler to optimize harder

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Tuesday, October 22, 2024 14:35:00
    https://gitlab.synchro.net/main/sbbs/-/commit/30a163fae2b0e9fe34f08acb
    Modified Files:
    src/conio/scale.c
    Log Message:
    Don't use the C99 restrict keyword because MSVC is apparently still
    more than 25 years behind the C standard.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Monday, November 04, 2024 19:49:46
    https://gitlab.synchro.net/main/sbbs/-/commit/80b9fccc77dbfe64da1ff062
    Modified Files:
    src/conio/scale.c
    Log Message:
    Add most const decorations.

    Not sure what macOS is doing, but it looks like something weird is
    happening in interpolate_width... maybe some unexpected integer
    promotion?

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Deuc¿@VERT to Git commit to main/sbbs/master on Tuesday, November 05, 2024 09:13:24
    https://gitlab.synchro.net/main/sbbs/-/commit/76d03c231fcf2d6bd76a2bef
    Modified Files:
    src/conio/scale.c
    Log Message:
    Use uint64_t instead of double for interpolation.

    More effort to fix the macOS issue. This could potentially result
    in slight problens with the rightmost pixel, but will protect
    against any weird FP issues and -ffast-math concerns.

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net