From 74f45ed9c55aaecf6fd90a8076f486ad4302515d Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sun, 3 Oct 2021 12:06:06 +1100 Subject: Cleanup: spelling in comments --- intern/cycles/blender/blender_display_driver.cpp | 2 +- intern/cycles/device/hip/kernel.cpp | 2 +- intern/cycles/device/optix/device_impl.cpp | 2 +- intern/cycles/kernel/kernel_shader.h | 4 ++-- intern/ghost/intern/GHOST_DisplayManagerSDL.cpp | 3 +-- intern/ghost/intern/GHOST_SystemX11.cpp | 12 ++++++------ intern/ghost/intern/GHOST_WindowX11.cpp | 6 +++--- intern/guardedalloc/intern/mallocn_guarded_impl.c | 7 +++---- 8 files changed, 18 insertions(+), 20 deletions(-) (limited to 'intern') diff --git a/intern/cycles/blender/blender_display_driver.cpp b/intern/cycles/blender/blender_display_driver.cpp index 5267f41eef7..f55a8ce8c4e 100644 --- a/intern/cycles/blender/blender_display_driver.cpp +++ b/intern/cycles/blender/blender_display_driver.cpp @@ -460,7 +460,7 @@ void BlenderDisplayDriver::draw(const Params ¶ms) /* Texture is requested to be cleared and was not yet cleared. * * Do early return which should be equivalent of drawing all-zero texture. - * Watchout for the lock though so that the clear happening during update is properly + * Watch out for the lock though so that the clear happening during update is properly * synchronized here. */ gl_context_mutex_.unlock(); return; diff --git a/intern/cycles/device/hip/kernel.cpp b/intern/cycles/device/hip/kernel.cpp index e0acd6f17c6..9ede8507a0c 100644 --- a/intern/cycles/device/hip/kernel.cpp +++ b/intern/cycles/device/hip/kernel.cpp @@ -28,7 +28,7 @@ void HIPDeviceKernels::load(HIPDevice *device) for (int i = 0; i < (int)DEVICE_KERNEL_NUM; i++) { HIPDeviceKernel &kernel = kernels_[i]; - /* No megakernel used for GPU. */ + /* No mega-kernel used for GPU. */ if (i == DEVICE_KERNEL_INTEGRATOR_MEGAKERNEL) { continue; } diff --git a/intern/cycles/device/optix/device_impl.cpp b/intern/cycles/device/optix/device_impl.cpp index 5f5eff53063..49d4e22143f 100644 --- a/intern/cycles/device/optix/device_impl.cpp +++ b/intern/cycles/device/optix/device_impl.cpp @@ -1419,7 +1419,7 @@ void OptiXDevice::build_bvh(BVH *bvh, Progress &progress, bool refit) } else { /* Can disable __anyhit__kernel_optix_visibility_test by default (except for thick curves, - * since it needs to filter out endcaps there). + * since it needs to filter out end-caps there). * It is enabled where necessary (visibility mask exceeds 8 bits or the other any-hit * programs like __anyhit__kernel_optix_shadow_all_hit) via OPTIX_RAY_FLAG_ENFORCE_ANYHIT. */ diff --git a/intern/cycles/kernel/kernel_shader.h b/intern/cycles/kernel/kernel_shader.h index 8bad9c34d74..e7133724c85 100644 --- a/intern/cycles/kernel/kernel_shader.h +++ b/intern/cycles/kernel/kernel_shader.h @@ -186,8 +186,8 @@ ccl_device_inline float _shader_bsdf_multi_eval(const KernelGlobals *kg, float sum_sample_weight, const uint light_shader_flags) { - /* this is the veach one-sample model with balance heuristic, some pdf - * factors drop out when using balance heuristic weighting */ + /* This is the veach one-sample model with balance heuristic, + * some PDF factors drop out when using balance heuristic weighting. */ for (int i = 0; i < sd->num_closure; i++) { const ShaderClosure *sc = &sd->closure[i]; diff --git a/intern/ghost/intern/GHOST_DisplayManagerSDL.cpp b/intern/ghost/intern/GHOST_DisplayManagerSDL.cpp index 5b026eb1632..09b2e4dfe2b 100644 --- a/intern/ghost/intern/GHOST_DisplayManagerSDL.cpp +++ b/intern/ghost/intern/GHOST_DisplayManagerSDL.cpp @@ -101,8 +101,7 @@ GHOST_TSuccess GHOST_DisplayManagerSDL::setCurrentDisplaySetting( uint8_t display, const GHOST_DisplaySetting &setting) { /* - * Mode switching code ported from Quake 2 version 3.21 and bzflag version - * 2.4.0: + * Mode switching code ported from Quake 2 version 3.21 and BZFLAG version 2.4.0: * ftp://ftp.idsoftware.com/idstuff/source/q2source-3.21.zip * See linux/gl_glx.c:GLimp_SetMode * http://wiki.bzflag.org/BZFlag_Source diff --git a/intern/ghost/intern/GHOST_SystemX11.cpp b/intern/ghost/intern/GHOST_SystemX11.cpp index c87b745cf40..86b4245ca67 100644 --- a/intern/ghost/intern/GHOST_SystemX11.cpp +++ b/intern/ghost/intern/GHOST_SystemX11.cpp @@ -1528,13 +1528,13 @@ void GHOST_SystemX11::processEvent(XEvent *xe) window->GetTabletData().Pressure = axis_value / ((float)xtablet.PressureLevels); } - /* the (short) cast and the & 0xffff is bizarre and unexplained anywhere, - * but I got garbage data without it. Found it in the xidump.c source --matt + /* NOTE(@broken): the (short) cast and the & 0xffff is bizarre and unexplained anywhere, + * but I got garbage data without it. Found it in the `xidump.c` source. * - * The '& 0xffff' just truncates the value to its two lowest bytes, this probably means - * some drivers do not properly set the whole int value? Since we convert to float - * afterward, I don't think we need to cast to short here, but do not have a device to - * check this. --mont29 + * NOTE(@mont29): The '& 0xffff' just truncates the value to its two lowest bytes, + * this probably means some drivers do not properly set the whole int value? + * Since we convert to float afterward, + * I don't think we need to cast to short here, but do not have a device to check this. */ if (AXIS_VALUE_GET(3, axis_value)) { window->GetTabletData().Xtilt = (short)(axis_value & 0xffff) / diff --git a/intern/ghost/intern/GHOST_WindowX11.cpp b/intern/ghost/intern/GHOST_WindowX11.cpp index de389951613..8b44403c598 100644 --- a/intern/ghost/intern/GHOST_WindowX11.cpp +++ b/intern/ghost/intern/GHOST_WindowX11.cpp @@ -1092,9 +1092,9 @@ GHOST_TSuccess GHOST_WindowX11::setOrder(GHOST_TWindowOrder order) XWindowAttributes attr; Atom atom; - /* We use both XRaiseWindow and _NET_ACTIVE_WINDOW, since some - * window managers ignore the former (e.g. kwin from kde) and others - * don't implement the latter (e.g. fluxbox pre 0.9.9) */ + /* We use both #XRaiseWindow and #_NET_ACTIVE_WINDOW, since some + * window managers ignore the former (e.g. KWIN from KDE) and others + * don't implement the latter (e.g. FLUXBOX before 0.9.9). */ XRaiseWindow(m_display, m_window); diff --git a/intern/guardedalloc/intern/mallocn_guarded_impl.c b/intern/guardedalloc/intern/mallocn_guarded_impl.c index 98a8553a3eb..bba72c907eb 100644 --- a/intern/guardedalloc/intern/mallocn_guarded_impl.c +++ b/intern/guardedalloc/intern/mallocn_guarded_impl.c @@ -89,7 +89,7 @@ typedef struct localListBase { void *first, *last; } localListBase; -/* note: keep this struct aligned (e.g., irix/gcc) - Hos */ +/* NOTE(@hos): keep this struct aligned (e.g., IRIX/GCC). */ typedef struct MemHead { int tag1; size_t len; @@ -98,9 +98,8 @@ typedef struct MemHead { const char *nextname; int tag2; short pad1; - short alignment; /* if non-zero aligned alloc was used - * and alignment is stored here. - */ + /* if non-zero aligned allocation was used and alignment is stored here. */ + short alignment; #ifdef DEBUG_MEMCOUNTER int _count; #endif -- cgit v1.2.3