MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / sign_extend

Function sign_extend

libavcodec/mathops.h:135–140  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

133
134#ifndef sign_extend
135static inline av_const int sign_extend(int val, unsigned bits)
136{
137 unsigned shift = 8 * sizeof(int) - bits;
138 union { unsigned u; int s; } v = { (unsigned) val << shift };
139 return v.s >> shift;
140}
141#endif
142
143#ifndef sign_extend64

Callers 15

ambisonics_configFunction · 0.85
mix_presentation_obuFunction · 0.85
ebml_read_sintFunction · 0.85
matroska_parse_blockFunction · 0.85
parameter_block_obuFunction · 0.85
xan_wc3_decode_frameFunction · 0.85
cinaudio_decode_frameFunction · 0.85
decode_planeFunction · 0.85
aptx_unpack_codewordFunction · 0.85
aptxhd_unpack_codewordFunction · 0.85
flic_decode_frame_1BPPFunction · 0.85

Calls

no outgoing calls

Tested by 1

test_decorrelate_sfFunction · 0.68