Commit Graph

63540 Commits

Author SHA1 Message Date
LibretroAdmin e7f3432e48 Replace some trivial strlcat usage - use return value of preceding
strlcpy then simply append the extension to it at this location
2022-08-04 03:45:09 +02:00
github-actions eab5898790 Fetch translations from Crowdin 2022-08-04 00:11:40 +00:00
LibretroAdmin 32314eddaf (video_crt_switch.c) Get rid of unnecessary strlen 2022-08-04 00:10:19 +02:00
LibretroAdmin ec4c15e8e4 (gfx_widget_load_content_animation) Cleanups - one strlen instead of two,
NULL termination of some strings is not necessary since it gets passed to
strlcpy and/or fill_pathname_join anyway
2022-08-04 00:00:21 +02:00
LibretroAdmin f4c22cb236 (file_path.c) fill_pathname_join - do away with one less strlcat 2022-08-03 23:54:10 +02:00
LibretroAdmin 819337d5d4 video_shader_get_type_from_ext - get rid of unnecessary strlen 2022-08-03 23:35:16 +02:00
LibretroAdmin c240340c91 (vfs_implementation.c) We need to include stdstring.h for string_is_empty 2022-08-03 19:49:02 +02:00
LibretroAdmin 53d2fdbd97 net_http_urlencode - avoid one strlen call by clever use of strlcpy
return value and some subtraction arithmetic
2022-08-03 15:53:12 +02:00
LibretroAdmin 8e6369ef33 (vfs_implementation.c) An unnecessary repeated conditional removed 2022-08-03 15:19:54 +02:00
LibretroAdmin 7871e9fbc1 retro_vfs_file_open_impl - bunch of inefficiencies here:
- was doing a strlen first on path to calculate the length
- stored at least three local variables for string constants
- did another memcmp check after doing the length comparison conditional first
Simplify all this into a simple string comparison checking if the
path starts with the string 'vfsonly://' and/or 'cdrom://' -
avoid both strlen and memcmp cost. Also removed the need for
stdstring.h header include - just translated STRLEN_CONST into
(sizeof(x)-1) - no header file dependency for the only usage of stdstring.h
in this file
2022-08-03 15:07:02 +02:00
LibretroAdmin 02df727cb2 Avoid strtof() since it's C99/POSIX. Go for strtod followed by float
cast since it should be almost identical
2022-08-03 14:07:32 +02:00
github-actions 16930150f8 Fetch translations from Crowdin 2022-08-03 00:13:16 +00:00
LibretroAdmin 01a7f2010d Buildfix for tvOS - tvOS apparently doesn't build in all the menu
drivers which is how this error was found
2022-08-02 23:26:34 +02:00
LibretroAdmin 08cc1c986a
Refactor file path special (#14275)
* First pass - unique variable names

* (file_path_special.c) fill_pathname_application_special() - no longer
a recursive function, other optimizations

* Buildfix

* Put another HAVE_XMB ifdef around xmb_theme_ident

* Remove unused variables

* Remove more unused variables and use fill_pathname_join instead of strlcpy
at the end
2022-08-02 20:57:55 +02:00
LibretroAdmin bde84b926f fill_pathname_application_special - redo string concatenation for
Ozone icons - avoid fill_pathname_slash when possible and use
fill_pathname_join instead - avoids the strlen cost
2022-08-02 18:47:34 +02:00
LibretroAdmin 6dd52d9bb1 Get rid of more boilerplate code in file_path_special.c 2022-08-02 18:05:51 +02:00
LibretroAdmin 556e6702ef Start downscaling on file_path_special.c 2022-08-02 17:54:38 +02:00
LibretroAdmin 70ca20fbf9 (MaterialUI) Fix earlier mistakes made (cd04f770b9) -
we need two separate icon paths cached - one for MaterialUI and one for Ozone (the system
icons)x
2022-08-02 17:25:52 +02:00
LibretroAdmin 7a993a5951
Count amount of characters window title has so that we can (#14274)
return the value when calling video_driver_get_window_title -
this is so we can prevent strlen calls in x11_common.c
2022-08-02 17:00:33 +02:00
LibretroAdmin 3c7fa43f29 (Windows/Linux) Fix windows title regressions 2022-08-02 16:35:50 +02:00
LibretroAdmin 33c9f56df0 (RPNG) PNG decoder - proper namespacing of functions, general cleanups 2022-08-02 15:55:26 +02:00
LibretroAdmin 342d3da620 (RPNG optimizations)
- Use memcpy to inflate_buf into array
- Some miscellaneous tweaks
2022-08-02 15:17:37 +02:00
Cthulhu-throwaway 8105688a99
(Netplay) Show client slowdown information (#14272) 2022-08-02 13:31:55 +02:00
LibretroAdmin e6f3a387b2 png_reverse_filter_copy_line - optimization - paeth would always return
'b' input value (and input is unsigned, so abs would have no effect), so
get rid of the paeth function call for the first loop iteration
2022-08-02 13:22:13 +02:00
LibretroAdmin 78f4e0abda C89_BUILD buildfix 2022-08-02 11:34:41 +02:00
LibretroAdmin a974cef001 (sinc resampler) Simplifications - call besseli0 directly instead of
through kaiser_window_function wrapper function - get rid of some unnecessary
sqrtf calls and such, some other small opts
2022-08-02 11:29:05 +02:00
LibretroAdmin 605c4608d9 Optimize fill_pathname_join - avoid the call to fill_pathname_slash()
which would have an implicit strlen cost
2022-08-01 22:14:26 +02:00
LibretroAdmin 9d66e2d5e1 General cleanups -
* struct was erroneously named 'catagory' - changed to 'category'
* Removed some strlcpys that were just setting the string to a fixed constant value
* Random nits
2022-08-01 21:31:45 +02:00
LibretroAdmin e4bff7c12c Move rjsonwriter helper inline functions over to separate file rjson_helpers.h 2022-08-01 17:41:34 +02:00
LibretroAdmin 5b56ff145f Refine documentation 2022-08-01 15:46:08 +02:00
LibretroAdmin f79875536a (libretro-common) Move file_crc32 out of encoding_crc32.c - we don't want file I/O
code in encodings/encoding_crc32.c
2022-08-01 14:04:01 +02:00
LibretroAdmin ec6f4c1f55 (libretro-common) refinements to documentation 2022-08-01 13:06:35 +02:00
LibretroAdmin 107c69ab9e (libretro-common) More documentation refinement 2022-08-01 11:03:58 +02:00
LibretroAdmin c7a1d83675 (libretro-common) Start documenting leaf functon calls in function documentation
(libretro-common) docs - document when string has to be non-NULL or else UB (undefined behavior)
(libretro-common) stdstring.c - string_hex_to_unsigned - make strlen call unneeded
2022-08-01 09:52:39 +02:00
Cthulhu-throwaway 20c4407928
Add HAVE_IFINFO macro (#14265) 2022-08-01 07:51:02 +02:00
LibretroAdmin f472e4d0de (gfx_widgets) Call fill_pathname_application_special outside of hot functions
(gfx widgets) Pre-assemble and store paths that are not subject to change
2022-08-01 02:07:36 +02:00
LibretroAdmin cd04f770b9 (MaterialUI) Don't keep assembling MaterialUI icons path - store it once
in materialui_init
2022-08-01 01:17:39 +02:00
LibretroAdmin e9a6252fc7 (Ozone) Some simplifications - less string concatenation 2022-08-01 01:06:38 +02:00
LibretroAdmin 83a2ec1da8 (Ozone/XMB) Move some fill_pathname_join operations out of the loops since
the output string is not subject to change during iterations
2022-08-01 00:49:33 +02:00
LibretroAdmin 4b8d3ab8a0 (glslang) Use string append 2022-07-31 22:48:30 +02:00
LibretroAdmin e602f8762b (glslang) Turn functions static 2022-07-31 19:52:41 +02:00
LibretroAdmin 2b84be1210 Get rid of HlslLegalization 2022-07-31 19:34:30 +02:00
LibretroAdmin 5cb8d34ac8 (glslang) Relaxed errors will never be enabled 2022-07-31 19:26:54 +02:00
LibretroAdmin 819d02ab24 (glslang) Remove more unused code -
* EShMsgKeepUncalled will never be used
* ShBinding never used
* TIOMapResolver never used
2022-07-31 19:02:36 +02:00
LibretroAdmin 0faee680c0 (glslang) remove more code we won't need - EShMsgAST, etc 2022-07-31 18:49:16 +02:00
LibretroAdmin 5a4e7cfbd1 (glslang) Remove no longer used RemoveTree.cpp/.h 2022-07-31 18:28:45 +02:00
LibretroAdmin 2ba46da700 (glslang) Simplifications - cuts down on binary size 2022-07-31 17:41:22 +02:00
LibretroAdmin a176a935da (glslang) Further simplifications of InfoSink - get rid of message() and prefix() -
we want simple string concatenation/addition instead of all these layers
2022-07-31 16:37:49 +02:00
LibretroAdmin a2e525a1b6 (glslang) Further simplification of InfoSink 2022-07-31 16:08:33 +02:00
LibretroAdmin 0db7062c87 (glslang) Slim down TInfoSinkBase 2022-07-31 15:24:32 +02:00