summaryrefslogtreecommitdiff
path: root/src/video_core/command_classes
diff options
context:
space:
mode:
authorGravatar Lioncash2021-01-15 02:02:57 -0500
committerGravatar Lioncash2021-01-15 02:15:32 -0500
commit8620de6b2030bef35360d029354f672cde8978f1 (patch)
treeed1f105b1fef3fc9a5209c5106accaaee283ebf2 /src/video_core/command_classes
parentMerge pull request #5354 from ReinUsesLisp/remove-common-color (diff)
downloadyuzu-8620de6b2030bef35360d029354f672cde8978f1.tar.gz
yuzu-8620de6b2030bef35360d029354f672cde8978f1.tar.xz
yuzu-8620de6b2030bef35360d029354f672cde8978f1.zip
common/bit_util: Replace CLZ/CTZ operations with standardized ones
Makes for less code that we need to maintain.
Diffstat (limited to 'src/video_core/command_classes')
-rw-r--r--src/video_core/command_classes/codecs/h264.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/video_core/command_classes/codecs/h264.cpp b/src/video_core/command_classes/codecs/h264.cpp
index 65bbeac78..fea6aed98 100644
--- a/src/video_core/command_classes/codecs/h264.cpp
+++ b/src/video_core/command_classes/codecs/h264.cpp
@@ -19,7 +19,7 @@
19// 19//
20 20
21#include <array> 21#include <array>
22#include "common/bit_util.h" 22#include <bit>
23#include "video_core/command_classes/codecs/h264.h" 23#include "video_core/command_classes/codecs/h264.h"
24#include "video_core/gpu.h" 24#include "video_core/gpu.h"
25#include "video_core/memory_manager.h" 25#include "video_core/memory_manager.h"
@@ -266,7 +266,7 @@ void H264BitWriter::WriteExpGolombCodedInt(s32 value) {
266} 266}
267 267
268void H264BitWriter::WriteExpGolombCodedUInt(u32 value) { 268void H264BitWriter::WriteExpGolombCodedUInt(u32 value) {
269 const s32 size = 32 - Common::CountLeadingZeroes32(static_cast<s32>(value + 1)); 269 const s32 size = 32 - std::countl_zero(value + 1);
270 WriteBits(1, size); 270 WriteBits(1, size);
271 271
272 value -= (1U << (size - 1)) - 1; 272 value -= (1U << (size - 1)) - 1;