Commit d25c033d authored by Rostislav Pehlivanov's avatar Rostislav Pehlivanov

aaccoder_twoloop.h: simplify and comment ff_pns_bits()

parent 5f760da6
......@@ -56,14 +56,10 @@
#define sclip(x) av_clip(x,60,218)
static av_always_inline int ff_pns_bits(const SingleChannelElement *sce, int w, int g)
/* Reflects the cost to change codebooks */
static inline int ff_pns_bits(SingleChannelElement *sce, int w, int g)
{
if (!g || !sce->zeroes[w*16+g-1] || !sce->can_pns[w*16+g-1]) {
return 9;
} else {
return 5;
}
return (!g || !sce->zeroes[w*16+g-1] || !sce->can_pns[w*16+g-1]) ? 9 : 5;
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment