#include <inttypes.h>#include "config.h"#include <stdlib.h>#include <stdio.h>#include <string.h>#include <ctype.h>#include <limits.h>#include <errno.h>#include <math.h>#include "internal.h"#include "mem.h"#include "internal.h"Go to the source code of this file.
Defines | |
| #define | av_always_inline inline |
| #define | av_noinline |
| #define | attribute_deprecated |
| #define | av_unused |
| #define | RSHIFT(a, b) ((a) > 0 ? ((a) + ((1<<(b))>>1))>>(b) : ((a) + ((1<<(b))>>1)-1)>>(b)) |
| #define | ROUNDED_DIV(a, b) (((a)>0 ? (a) + ((b)>>1) : (a) - ((b)>>1))/(b)) |
| #define | FFABS(a) ((a) >= 0 ? (a) : (-(a))) |
| #define | FFSIGN(a) ((a) > 0 ? 1 : -1) |
| #define | FFMAX(a, b) ((a) > (b) ? (a) : (b)) |
| #define | FFMIN(a, b) ((a) > (b) ? (b) : (a)) |
| #define | FFSWAP(type, a, b) do{type SWAP_tmp= b; b= a; a= SWAP_tmp;}while(0) |
| #define | MKTAG(a, b, c, d) (a | (b << 8) | (c << 16) | (d << 24)) |
| #define | MKBETAG(a, b, c, d) (d | (c << 8) | (b << 16) | (a << 24)) |
| #define | GET_UTF8(val, GET_BYTE, ERROR) |
| #define | PUT_UTF8(val, tmp, PUT_BYTE) |
| #define | START_TIMER |
| #define | STOP_TIMER(id) {} |
Functions | |
| static int | av_log2 (unsigned int v) |
| static int | av_log2_16bit (unsigned int v) |
| static int | mid_pred (int a, int b, int c) |
| static int | av_clip (int a, int amin, int amax) |
| clip a signed integer value into the amin-amax range | |
| static uint8_t | av_clip_uint8 (int a) |
| clip a signed integer value into the 0-255 range | |
| static int16_t | av_clip_int16 (int a) |
| clip a signed integer value into the -32768,32767 range | |
| int64_t | ff_gcd (int64_t a, int64_t b) |
| static int | ff_get_fourcc (const char *s) |
| converts fourcc string to int | |
Variables | |
| const uint8_t | ff_log2_tab [256] |
| #define attribute_deprecated |
| #define av_unused |
Definition at line 76 of file common.h.
Referenced by asf_build_simple_index(), avfilter_get_video_buffer(), body(), decode_cabac_residual_internal(), decode_i_frame(), ff_dprintf_ref(), ff_faandct(), ff_h264_filter_mb(), get_cabac_inline(), get_rac(), p8idct(), pred4x4_down_left_svq3_c(), row_fdct(), sha256_transform(), and show_filters().
| #define FFABS | ( | a | ) | ((a) >= 0 ? (a) : (-(a))) |
Definition at line 86 of file common.h.
Referenced by add_8x8basis_TMPL(), av_encode(), av_reduce(), av_resample(), avi_read_header(), check_mv(), codebook_sanity_check_for_rate_quarter(), compute_pkt_fields(), dct_error(), dct_max8x8_c(), dct_quantize_refine(), dct_quantize_trellis_c(), dct_single_coeff_elimination(), decode_frame_header(), decode_q_branch(), dering_TMPL(), dnxhd_calc_ac_bits(), do_a_deblock_C(), do_apply_filter(), doHorizDefFilter_C(), doHorizLowPass_C(), doVertDefFilter_TMPL(), doVertLowPass_TMPL(), dpcm_predict(), draw_line(), dv_init_enc_block(), encode_block(), estimate_stereo_mode(), ff_h264_direct_ref_list_init(), ff_init_me(), ff_jpegls_update_state_regular(), ff_mpeg1_encode_init(), ff_msmpeg4_decode_block(), ff_nelly_get_sample_bits(), filter_mb_mbaff_edgecv(), filter_mb_mbaff_edgev(), find_frame_rate_index(), flashsv_encode_frame(), funny_diamond_search(), get_diff_limited_q(), get_needed_flags(), get_qminmax(), get_rrp(), get_sae(), get_sample_bits(), get_scale_factor(), guess_mv(), gxf_seek(), h263_encode_picture_header(), h263_h_loop_filter_c(), h263_v_loop_filter_c(), h264_loop_filter_chroma_c(), h264_loop_filter_chroma_intra_c(), h264_loop_filter_luma_c(), h264_loop_filter_luma_intra_c(), h_block_filter(), hadamard8_intra8x8_c(), headroom(), hev(), horizX1Filter(), implicit_weight_table(), init(), init_uni_ac_vlc(), initFilter(), ls_decode_line(), ls_encode_line(), ls_encode_regular(), ls_get_code_runterm(), mov_find_next_sample(), mpc8_decode_frame(), mpeg1_encode_sequence_header(), mpeg4_decode_block(), normal_limit(), nsse16_c(), nsse16_mmx(), nsse8_c(), nsse8_mmx(), packedCopyWrapper(), postProcess_TMPL(), pp_postprocess(), pred_spatial_direct_motion(), put_s(), put_symbol(), put_symbol_inline(), read_rle_sgi(), read_seek2(), render_line(), render_slice(), reverse_dc_prediction(), rv40_adaptive_loop_filter(), rv40_weak_loop_filter(), sab_diamond_search(), search_for_quantizers_faac(), seq_unpack_rle_block(), simple_limit(), skip_check(), start_frame(), sum_abs_dctelem_c(), sws_convVec(), sws_getShiftedVec(), transcode(), try_8x8basis_TMPL(), update_vlc_state(), v_block_filter(), var_diamond_search(), vc1_filter_line(), vc1_pred_b_mv(), vc1_pred_mv(), vertX1Filter_TMPL(), vorbis_floor1_decode(), vp6_filter(), vsad16_c(), w_c(), wmv2_pred_motion(), x8_loop_filter(), and yuv420_rgb16_TMPL().
| #define FFMAX | ( | a, | |||
| b | ) | ((a) > (b) ? (a) : (b)) |
Definition at line 89 of file common.h.
Referenced by ac3_eac3_probe(), ac3_parse_audio_block(), adaptive_quantization(), add_codec(), addTonalComponents(), adjust_frame_information(), adts_aac_probe(), allocate_buffers(), applehttp_read_header(), applehttp_read_packet(), apply_tns(), asf_write_packet(), av_d2q(), av_encode(), av_estimate_timings_from_pts(), av_fast_malloc(), av_fast_realloc(), av_image_copy(), av_resample(), av_resample_init(), av_seek_frame_binary(), avcodec_align_dimensions(), avcodec_default_get_buffer(), avi_read_header(), avi_read_packet(), avi_read_seek(), avi_write_counters(), bidir_refine(), bink_decode_plane(), bit_allocation(), build_feed_streams(), build_filter(), build_table(), calc_input_response(), calc_lowcomp(), calc_lowcomp1(), cavs_decode_frame(), cdg_scroll(), compute_pkt_fields2(), compute_target_time(), copy(), copy_backptr(), copy_chapters(), create_vorbis_context(), dct_error(), dct_max8x8_c(), decode(), decode_audio_block(), decode_chunks(), decode_frame(), decode_lspf(), decode_p_frame(), decode_scale_factors(), decode_var_block_data(), decodeChannelSoundUnit(), decorrelation(), direct_search(), dnxhd_encode_rdo(), dnxhd_find_qscale(), do_a_deblock_C(), do_audio_out(), doHorizDefFilter_C(), doVertDefFilter_TMPL(), encode_block(), encode_picture(), epzs_motion_search_internal(), execute_code(), ff_ac3_bit_alloc_calc_bap(), ff_ac3_bit_alloc_calc_mask(), ff_ac3_bit_alloc_calc_psd(), ff_ac3_parse_header(), ff_acelp_reorder_lsf(), ff_acelp_update_past_gain(), ff_emulated_edge_mc(), ff_gen_syncpoint_search(), ff_get_best_fcode(), ff_init_me(), ff_jpegls_init_state(), ff_jpegls_reset_coding_parameters(), ff_jpegls_update_state_regular(), ff_mjpeg_decode_dqt(), ff_nelly_get_sample_bits(), ff_pca(), ff_probe_input_buffer(), ff_rewind_with_probe_data(), ff_set_min_dist_lsf(), ff_timefilter_update(), ffm_seek1(), filter_level_for_mb(), find_max_val(), findCode(), flac_decode_frame(), flv_write_packet(), full_search(), get_exponent_dynamic(), get_floor_average(), get_limits(), get_new_centroids(), get_quant_quality(), get_quants(), get_sample_bits(), get_video_frame(), get_visual_weight(), guess_mv(), gxf_seek(), h_block_filter(), horizX1Filter(), http_start_receive_data(), init_dequantizer(), init_exp(), init_offset(), initFilter(), is_intra_more_likely(), kalman_smoothen(), lame_calc_attack_threshold(), libopenjpeg_decode_frame(), main(), match_format(), matroska_parse_block(), matroska_read_seek(), median4(), mkv_write_ass_blocks(), mkv_write_packet_internal(), modify_qscale(), mov_read_ctts(), mov_write_esds_tag(), MPV_encode_picture(), output_packet(), paint_mouse_pointer(), postProcess_TMPL(), pp_postprocess(), ps_tableinit(), psy_3gpp_analyze(), put_codebook_header(), quantize_lpc_coefs(), queue_picture(), read_gab2_sub(), read_header(), read_sbr_grid(), read_seek(), read_var_block_data(), render_charset(), residue_encode(), rv34_gen_vlc(), sbr_hf_calc_npatches(), sbr_make_f_derived(), sbr_x_gen(), search_for_ms(), search_for_quantizers_anmr(), search_for_quantizers_faac(), search_for_quantizers_twoloop(), select_input_picture(), shorten_decode_frame(), skip_check(), stabilize_lsps(), start_frame(), sws_diffVec(), sws_getContext(), sws_sumVec(), transcode(), try_decode_frame(), umh_search(), url_read_complete(), v_block_filter(), var_diamond_search(), vertX1Filter_TMPL(), video_refresh_timer(), wmv2_pred_motion(), write_header(), x8_ac_compensation(), x8_loop_filter(), x8_setup_spatial_compensation(), yop_read_seek(), and zmbv_me().
| #define FFMIN | ( | a, | |||
| b | ) | ((a) > (b) ? (b) : (a)) |
Definition at line 90 of file common.h.
Referenced by aac_encode_frame(), ac3_decode_frame(), add_metadata(), aiff_read_packet(), ape_decode_frame(), applehttp_read_header(), applehttp_read_packet(), apply_pitch_filters(), apply_tns(), array_min_int16(), asf_read_header(), asfrtp_parse_packet(), av_fifo_generic_read(), av_fifo_generic_write(), av_fifo_write(), av_reduce(), av_resample(), av_resample_init(), av_url_split(), avfilter_insert_pad(), avfilter_merge_formats(), avfilter_poll_frame(), avi_read_header(), aw_parse_coords(), bidir_refine(), build_filter(), build_table(), cdg_scroll(), chomp6(), chroma_4mv_motion_lowres(), chrRangeToJpeg_TMPL(), cin_decode_lzss(), cin_decode_rle(), cinaudio_decode_frame(), clean_index(), commit_bitstream_and_slice_buffer(), copy_bits(), copy_chapters(), count_pixels(), create_adapt_vect(), dct_quantize_trellis_c(), decode_block(), decode_block_refinement(), decode_byterun(), decode_frame(), decode_frame_ilbm(), decode_header(), decode_lspf(), decode_mb_i(), decode_prediction(), decode_rgb_frame(), decode_rle(), decode_slice_header(), decode_subframe(), decodeTonalComponents(), dering_TMPL(), direct_search(), dnxhd_encode_rdo(), dnxhd_find_qscale(), do_a_deblock_C(), do_rematrixing(), do_video_out(), doHorizDefFilter_C(), doVertDefFilter_TMPL(), dxa_read_packet(), encode_exp(), encode_ext_header(), encode_frame(), encode_init(), encode_scalar(), encode_superframe(), epzs_motion_search_internal(), execute_code(), ff_aac_ac3_parse(), ff_ac3_bit_alloc_calc_bap(), ff_ac3_bit_alloc_calc_mask(), ff_ac3_bit_alloc_calc_psd(), ff_acelp_reorder_lsf(), ff_amf_get_field_value(), ff_amf_tag_contents(), ff_cmap_read_palette(), ff_copy_and_dup(), ff_draw_horiz_band(), ff_eac3_apply_spectral_extension(), ff_emulated_edge_mc(), ff_estimate_p_frame_motion(), ff_find_start_code(), ff_get_best_fcode(), ff_init_long_region(), ff_init_me(), ff_interleave_new_audio_packet(), ff_ivi_init_tiles(), ff_jpegls_reset_coding_parameters(), ff_jpegls_update_state_regular(), ff_mms_read_data(), ff_mms_read_header(), ff_pca(), ff_probe_input_buffer(), ff_region_offset2size(), ff_rtmp_packet_read(), ff_rtmp_packet_write(), ff_rtp_send_aac(), ff_rtp_send_h263(), ff_rtp_send_vp8(), ff_sipr_decode_frame_16k(), ff_spatial_idwt_buffered_slice(), ff_spatial_idwt_slice(), ff_vorbis_floor1_render_list(), ffm_seek1(), fill_rectangle(), filter_common(), filter_level_for_mb(), find_optimal_param(), flac_decode_frame(), floor_encode(), full_search(), get_exponent_dynamic(), get_floor_average(), get_limits(), get_max_p_order(), get_new_centroids(), get_quants(), get_sockaddr(), get_str(), get_symbol(), get_symbol_inline(), get_visual_weight(), gif_image_write_image(), guess_mv(), hpel_motion_lowres(), hScale_altivec_real(), http_read(), http_receive_data(), huffman_decode(), init_poc(), initFilter(), interleave_buffer(), inverse_channel_transform(), iv_decode_frame(), kalman_smoothen(), lsf_decode_fp(), main(), matroska_ebmlnum_uint(), matroska_read_header(), median4(), mkv_write_ass_blocks(), mov2textsub(), mov_build_index(), mov_read_default(), mov_read_dref(), mov_write_chpl_tag(), mov_write_uuidprof_tag(), mp_decode_frame(), mp_read_changes_map(), mpc8_get_mask(), mpeg4_decode_sprite_trajectory(), mpeg4_encode_gop_header(), mpeg_decode_slice(), mpeg_motion_lowres(), mpegaudio_parse(), mszh_decomp(), ogg_buffer_data(), op(), paint_mouse_pointer(), pcm_decode_frame(), pitch_sharpening(), postProcess_TMPL(), pred_intra_mode(), predict_slice(), predict_slice_buffered(), psy_3gpp_analyze(), psy_3gpp_init(), put_bitstream_info(), put_buffer(), put_symbol(), put_symbol_inline(), pva_read_timestamp(), qcp_read_header(), qdm2_parse_subpacket(), qdm2_restore_block(), qtrle_encode_line(), quantize_bands(), read_access_unit(), read_dcs(), read_gab2_sub(), read_packet(), read_seek(), read_ttag(), read_var_block_data(), render_charset(), render_slice(), rm_assemble_video_frame(), rtp_check_and_send_back_rr(), rtp_send_samples(), rv30_decode_init(), rv34_gen_vlc(), save_bits(), sbr_gain_calc(), sbr_make_f_master(), search_for_ms(), search_for_quantizers_anmr(), search_for_quantizers_faac(), search_for_quantizers_fast(), search_for_quantizers_twoloop(), seq_unpack_rle_block(), shorten_decode_frame(), spatial_compensation_1(), spatial_compensation_9(), stabilize_lsps(), stream_component_open(), sub_left_prediction_bgr32(), subframe_count_exact(), svq3_decode_mb(), svq3_get_ue_golomb(), synth_frame(), synthesis(), to_meta_with_crop(), truespeech_decode_frame(), umh_search(), unpack(), unpack_coeffs(), url_alloc(), var_diamond_search(), vc1_filter_line(), video_audio_display(), voc_get_packet(), vorbis_decode_init(), vp5_parse_coeff(), vp6_parse_coeff_huffman(), vp8_init(), vqf_read_header(), wavpack_decode_frame(), wiener_denoise(), write_packet(), write_subframes(), x8_get_prediction(), x8_loop_filter(), x8_setup_spatial_compensation(), xan_wc3_output_pixel_run(), xsub_encode_rle(), yop_read_seek(), and zmbv_me().
| #define FFSIGN | ( | a | ) | ((a) > 0 ? 1 : -1) |
Definition at line 87 of file common.h.
Referenced by alac_linear_predictor(), do_a_deblock_C(), doHorizDefFilter_C(), doVertDefFilter_TMPL(), ff_ivi_decode_blocks(), horizX1Filter(), mulawinv(), sign_only(), and vertX1Filter_TMPL().
| #define FFSWAP | ( | type, | |||
| a, | |||||
| b | ) | do{type SWAP_tmp= b; b= a; a= SWAP_tmp;}while(0) |
Definition at line 92 of file common.h.
Referenced by adpcm_decode_frame(), at1_imdct(), at1_imdct_block(), av_aes_init(), av_rc4_crypt(), av_rc4_init(), avcodec_default_release_buffer(), cinvideo_decode_frame(), cmv_decode_frame(), compute_pkt_fields(), compute_pkt_fields2(), decode_band(), decode_bytes_and_gain(), decode_frame(), decodeFrame(), draw_char(), draw_line(), encode_frame(), ff_acelp_reorder_lsf(), ff_ccitt_unpack(), ff_celp_lp_synthesis_filterf(), ff_eval_coefs(), ff_eval_refl(), ff_fft_calc_3dn2(), ff_h264_fill_default_ref_list(), ff_huff_build_tree(), ff_rc4_enc(), ff_sort_nearly_sorted_floats(), ff_vp56_decode_frame(), fft(), find_near_mvs(), getChannelWeights(), IMLT(), mp3_header_compress(), mp3_header_decompress(), png_choose_filter(), png_handle_row(), postfilter(), ra144_decode_frame(), ra144_encode_frame(), raw_decode(), read_tree(), rm_ac3_swap_bytes(), roq_decode_frame(), roq_encode_video(), switch_buffers(), tgv_decode_frame(), twin_decode_frame(), vmdvideo_decode_frame(), vp8_decode_frame(), and xan_decode_frame().
| #define GET_UTF8 | ( | val, | |||
| GET_BYTE, | |||||
| ERROR | ) |
Value:
val= GET_BYTE;\
{\
int ones= 7 - av_log2(val ^ 255);\
if(ones==1)\
ERROR\
val&= 127>>ones;\
while(--ones > 0){\
int tmp= GET_BYTE - 128;\
if(tmp>>6)\
ERROR\
val= (val<<6) + tmp;\
}\
}
| val | is the output and should be of type uint32_t. It holds the converted UCS-4 character and should be a left value. | |
| GET_BYTE | gets UTF-8 encoded bytes from any proper source. It can be a function or a statement whose return value or evaluated value is of type uint8_t. It will be executed up to 4 times for values in the valid UTF-8 range, and up to 7 times in the general case. | |
| ERROR | action that should be taken when an invalid UTF-8 byte is returned from GET_BYTE. It should be a statement that jumps out of the macro, like exit(), goto, return, break, or continue. |
Definition at line 236 of file common.h.
Referenced by ascii_to_wc(), ff_put_str16_nolen(), get_utf8(), and utf8len().
| #define MKBETAG | ( | a, | |||
| b, | |||||
| c, | |||||
| d | ) | (d | (c << 8) | (b << 16) | (a << 24)) |
Definition at line 221 of file common.h.
Referenced by alac_encode_init(), ff_mpeg4audio_get_config(), flac_decode_frame(), mjpegb_decode_frame(), nsv_resync(), parse_config_ALS(), probe(), qdm2_decode_init(), read_desc_chunk(), read_header(), read_specific_config(), swf_read_header(), and sync().
| #define MKTAG | ( | a, | |||
| b, | |||||
| c, | |||||
| d | ) | (a | (b << 8) | (c << 16) | (d << 24)) |
Definition at line 220 of file common.h.
Referenced by aiff_read_header(), aiff_write_header(), amr_read_header(), ape_read_header(), asf_read_header(), au_read_header(), avi_load_index(), avi_read_header(), bfi_probe(), bfi_read_packet(), daud_header(), decode_frame(), decode_frame_byterun1(), decode_frame_ilbm(), decode_init(), decode_wave_header(), dirac_probe(), dxa_read_header(), dxa_read_packet(), encode_frame(), ff_flac_is_extradata_valid(), ff_mjpeg_decode_init(), ff_mjpeg_decode_sos(), ff_mov_init_hinting(), ff_rm_read_mdpr_codecdata(), ffm_read_header(), ffm_write_header(), flac_decode_frame(), flac_read_header(), get_codec_data(), ingenient_read_packet(), ipod_get_codec_tag(), mmf_read_header(), mov_create_chapter_track(), mov_get_codec_tag(), mov_get_dv_codec_tag(), mov_probe(), mov_read_cmov(), mov_read_default(), mov_read_dref(), mov_read_hdlr(), mov_read_meta(), mov_read_stco(), mov_read_stsd(), mov_read_stsz(), mov_read_udta_string(), mov_read_wide(), mov_write_audio_tag(), mov_write_hdlr_tag(), mov_write_header(), mov_write_minf_tag(), mov_write_moov_tag(), mov_write_stbl_tag(), mov_write_stsd_tag(), mov_write_trailer(), mov_write_trak_tag(), mov_write_video_tag(), mp4_get_codec_tag(), mpc_read_header(), msnwc_tcp_probe(), msnwc_tcp_read_header(), nsv_parse_NSVf_header(), nsv_read_chunk(), parse_ffconfig(), png_write_row(), probe(), qcp_read_packet(), r3d_probe(), r3d_read_header(), r3d_read_packet(), raw_decode(), raw_init_decoder(), rdt_load_mdpr(), rm_read_header(), rm_read_index(), siff_parse_vbv1(), siff_read_header(), smacker_read_header(), sol_read_header(), start_command_packet(), thp_probe(), vfw_codecid(), vfw_pixfmt(), vfw_read_header(), vid_probe(), vp3_decode_init(), vqf_probe(), vqf_read_header(), wv_read_block_header(), and xsub_encoder_init().
| #define PUT_UTF8 | ( | val, | |||
| tmp, | |||||
| PUT_BYTE | ) |
Value:
{\
int bytes, shift;\
uint32_t in = val;\
if (in < 0x80) {\
tmp = in;\
PUT_BYTE\
} else {\
bytes = (av_log2(in) + 4) / 5;\
shift = (bytes - 1) * 6;\
tmp = (256 - (256 >> bytes)) | (in >> shift);\
PUT_BYTE\
while (shift >= 6) {\
shift -= 6;\
tmp = 0x80 | ((in >> shift) & 0x3f);\
PUT_BYTE\
}\
}\
}
| val | is an input only argument and should be of type uint32_t. It holds a ucs4 encoded unicode character that is to be converted to UTF-8. If val is given as a function it's executed only once. | |
| tmp | is a temporary variable and should be of type uint8_t. It represents an intermediate value during conversion that is to be outputted by PUT_BYTE. | |
| PUT_BYTE | writes the converted UTF-8 bytes to any proper destination. It could be a function or a statement, and uses tmp as the input byte. For example, PUT_BYTE could be "*output++ = tmp;" PUT_BYTE will be executed up to 4 times for values in the valid UTF-8 range and up to 7 times in the general case, depending on the length of the converted unicode character. |
Definition at line 267 of file common.h.
Referenced by count_frame_header(), get_str16_nolen(), mov_read_chapters(), mov_read_mac_string(), read_gab2_sub(), read_ttag(), and write_utf8().
| #define ROUNDED_DIV | ( | a, | |||
| b | ) | (((a)>0 ? (a) + ((b)>>1) : (a) - ((b)>>1))/(b)) |
Definition at line 85 of file common.h.
Referenced by add_peak(), decide_ac_pred(), decode_ppc(), decode_vop_header(), draw_arrow(), ff_convert_matrix(), initFilter(), mpeg4_decode_sprite_trajectory(), mpeg4_pred_ac(), and vect_division().
| #define RSHIFT | ( | a, | |||
| b | ) | ((a) > 0 ? ((a) + ((1<<(b))>>1))>>(b) : ((a) + ((1<<(b))>>1)-1)>>(b)) |
Definition at line 83 of file common.h.
Referenced by get_amv(), unpack_vectors(), and vp56_decode_4mv().
| #define START_TIMER |
Definition at line 365 of file common.h.
Referenced by av_adler32_update(), dct_quantize_refine(), and main().
| #define STOP_TIMER | ( | id | ) | {} |
Definition at line 366 of file common.h.
Referenced by av_adler32_update(), dct_quantize_refine(), and main().
| static int av_clip | ( | int | a, | |
| int | amin, | |||
| int | amax | |||
| ) | [inline, static] |
clip a signed integer value into the amin-amax range
| a | value to clip | |
| amin | minimum value of the clip range | |
| amax | maximum value of the clip range |
Definition at line 177 of file common.h.
Referenced by AC3_encode_init(), adpcm_ct_expand_nibble(), adpcm_decode_frame(), adpcm_sbpro_expand_nibble(), adpcm_yamaha_expand_nibble(), alac_encode_init(), av_log_default_callback(), bgmc_lut_getp(), blend_subrect(), build_filter(), build_qp_table(), calc_input_response(), categorize(), choose_vlc_set(), chroma_4mv_motion(), clamp_mv(), dec_delay3_2nd(), decode(), decode_exponents(), decode_frame(), decode_gain_and_index(), decode_init(), decode_pitch_lag_1_6(), decode_subband_slice_buffered(), dequantize_slice_buffered(), direct_search(), do_adaptive_prediction(), do_audio_out(), draw_arrow(), draw_line(), encode_block(), encode_frame(), encode_init(), encode_mb_internal(), eval_expr(), execute_code(), ff_ac3_bit_alloc_calc_bap(), ff_decode_pitch_lag(), ff_er_add_slice(), ff_gmc_c(), ff_init_qscale_tab(), ff_ivi_decode_blocks(), ff_mspel_motion(), ff_nelly_get_sample_bits(), ff_vbv_update(), filter_level_for_mb(), filter_mb_mbaff_edgecv(), filter_mb_mbaff_edgev(), g722_decode_frame(), g726_decode(), get_qminmax(), get_quants(), get_sample_bits(), get_scale_factor(), gmc1_motion(), gmc_c(), gsm_decode_block(), h263_encode_picture_header(), h263_h_loop_filter_c(), h263_v_loop_filter_c(), h264_loop_filter_chroma_c(), h264_loop_filter_luma_c(), hpel_motion(), hScale_altivec_real(), hScale_TMPL(), implicit_weight_table(), init_dequantizer(), init_pass2(), loop_filter_c1(), loop_filter_l1(), ls_decode_line(), ls_encode_line(), MPV_motion_internal(), png_enc_init(), quantize_and_encode_band_cost_template(), quantize_lpc_coefs(), read_channel_data(), read_var_block_data(), round_sample(), rv30_weak_loop_filter(), rv40_adaptive_loop_filter(), search_for_quantizers_anmr(), search_for_quantizers_faac(), search_for_quantizers_fast(), search_for_quantizers_twoloop(), sum_bits(), svq3_mc_dir(), svq3_mc_dir_part(), synth_block_fcb_acb(), synth_frame(), truespeech_synth(), update_high_predictor(), update_low_predictor(), update_qscale(), value_string(), vc1_interp_mc(), vc1_mc_1mv(), vc1_mc_4mv_chroma(), vc1_mc_4mv_luma(), vc1_pred_b_mv(), vp5_parse_coeff_models(), and vp6_parse_coeff_models().
| static int16_t av_clip_int16 | ( | int | a | ) | [inline, static] |
clip a signed integer value into the -32768,32767 range
| a | value to clip |
Definition at line 200 of file common.h.
Referenced by adpcm_ct_expand_nibble(), adpcm_decode_frame(), adpcm_ima_expand_nibble(), adpcm_ms_expand_nibble(), adpcm_yamaha_expand_nibble(), adx_decode(), atrac3_decode_frame(), av_audio_convert(), av_resample(), cinaudio_decode_frame(), do_adaptive_prediction(), do_apply_filter(), dpcm_decode_frame(), ff_acelp_high_pass_filter(), ff_acelp_interpolate(), ff_acelp_weighted_vector_sum(), ff_iir_filter(), ff_mpa_synth_filter(), g722_decode_frame(), postprocess(), ra144_decode_frame(), saturate_output_float(), vmdaudio_decode_audio(), wma_decode_frame(), and xa_decode().
| static uint8_t av_clip_uint8 | ( | int | a | ) | [inline, static] |
clip a signed integer value into the 0-255 range
| a | value to clip |
Definition at line 189 of file common.h.
Referenced by av_audio_convert(), coef2maxsf(), coef2minsf(), comp(), encode_picture(), ff_ivi_output_plane(), ff_ivi_recompose53(), ff_vp3_h_loop_filter_c(), ff_vp3_v_loop_filter_c(), ff_vp6_filter_diag4_c(), ff_yuv2rgb_c_init_tables(), filter_mb_mbaff_edgecv(), filter_mb_mbaff_edgev(), h264_loop_filter_chroma_c(), h264_loop_filter_luma_c(), ir2_decode_plane(), ir2_decode_plane_inter(), loop_filter_c1(), loop_filter_l1(), p8idct(), rv34_add_4x4_block(), search_for_quantizers_anmr(), search_for_quantizers_faac(), sws_scale(), tgq_dconly(), tm2_apply_deltas(), tm2_decode_blocks(), unsharpen(), vc1_h_overlap_c(), vc1_parse_frame_header(), vc1_parse_frame_header_adv(), vc1_v_overlap_c(), vp6_filter_hv4(), x8_decode_intra_mb(), yuv2nv12XinC(), and yuv2yuvXinC().
| static int av_log2 | ( | unsigned int | v | ) | [inline, static] |
Definition at line 97 of file common.h.
Referenced by AC3_encode_frame(), alac_entropy_coder(), av_ceil_log2_c(), av_mod_i(), av_normalize_sf(), av_read_packet(), bastardized_rice_decompress(), compute_scale_factors(), decode_block(), decode_frame(), decode_init(), decode_q_branch(), decode_spectrum_and_dequant(), decode_subframe(), decode_vol_header(), ebml_id_size(), encode_block(), escape124_decode_frame(), ff_eac3_parse_header(), ff_log2(), ff_mpeg1_encode_init(), ff_mpeg4_encode_video_packet_header(), ff_wma_init(), find_optimal_param(), fps_umf2avr(), get_level_prefix(), get_max_p_order(), get_rac_count(), get_se_golomb(), get_tail(), get_ue_golomb(), get_ur_golomb(), get_ur_golomb_jpegls(), headroom(), imdct_and_window(), init_cavlc_level_tab(), init_cook_mlt(), init_lengths(), init_mdct_win(), init_mv_penalty_and_fcode(), klv_ber_length(), klv_encode_ber_length(), log2_tab(), mp_decode_init(), mpeg4_decode_video_packet_header(), MPV_encode_init(), parse_source_parameters(), put_symbol(), put_symbol_inline(), qdm2_decode_init(), quantize_and_encode_band_cost_template(), rv20_decode_picture_header(), set_ue_golomb(), shorten_decode_frame(), svq3_decode_slice_header(), unpack_coeffs(), very_broken_op(), vmdaudio_decode_frame(), wma_decode_block(), wmapro_window(), wp_log2(), and wv_get_value_float().
| static int av_log2_16bit | ( | unsigned int | v | ) | [inline, static] |
Definition at line 115 of file common.h.
Referenced by av_log2_i(), aw_pulse_set2(), dnxhd_calc_bits_thread(), dnxhd_encode_dc(), encode_dc(), ff_mjpeg_encode_dc(), ff_sqrt(), i2f(), and quant().
| int64_t ff_gcd | ( | int64_t | a, | |
| int64_t | b | |||
| ) |
Definition at line 51 of file mathematics.c.
Referenced by av_reduce(), ff_gcd(), and xvid_correct_framerate().
| static int ff_get_fourcc | ( | const char * | s | ) | [inline, static] |
converts fourcc string to int
Definition at line 212 of file common.h.
Referenced by ff_xvid_encode_init().
| static int mid_pred | ( | int | a, | |
| int | b, | |||
| int | c | |||
| ) | [inline, static] |
| const uint8_t ff_log2_tab[256] |
Definition at line 40 of file mathematics.c.
Referenced by av_log2(), av_log2_16bit(), av_log2_16bit_c(), av_log2_c(), ebml_read_num(), put_xsub_rle(), and seq_decode_op1().
1.5.6