Revision 90bc36b0 libavutil/common.h

View differences:

libavutil/common.h
119 119
static inline av_const uint8_t av_clip_uint8(int a)
120 120
{
121 121
    if (a&(~0xFF)) return (-a)>>31;
122
    else          return a;
122
    else           return a;
123 123
}
124 124

  
125 125
/**
......
130 130
static inline av_const uint16_t av_clip_uint16(int a)
131 131
{
132 132
    if (a&(~0xFFFF)) return (-a)>>31;
133
    else            return a;
133
    else             return a;
134 134
}
135 135

  
136 136
/**
......
141 141
static inline av_const int16_t av_clip_int16(int a)
142 142
{
143 143
    if ((a+0x8000) & ~0xFFFF) return (a>>31) ^ 0x7FFF;
144
    else                    return a;
144
    else                      return a;
145 145
}
146 146

  
147 147
/**
......
152 152
static inline av_const int32_t av_clipl_int32(int64_t a)
153 153
{
154 154
    if ((a+0x80000000u) & ~UINT64_C(0xFFFFFFFF)) return (a>>63) ^ 0x7FFFFFFF;
155
    else                              return a;
155
    else                                         return a;
156 156
}
157 157

  
158 158
/**

Also available in: Unified diff