|
Libav
0.7.1
|
Go to the source code of this file.
Enumerations | |
| enum | AVRounding { AV_ROUND_ZERO = 0, AV_ROUND_INF = 1, AV_ROUND_DOWN = 2, AV_ROUND_UP = 3, AV_ROUND_NEAR_INF = 5 } |
Functions | |
| int64_t av_const | av_gcd (int64_t a, int64_t b) |
| Return the greatest common divisor of a and b. | |
| int64_t | av_rescale (int64_t a, int64_t b, int64_t c) av_const |
| Rescale a 64-bit integer with rounding to nearest. | |
| int64_t | av_rescale_rnd (int64_t a, int64_t b, int64_t c, enum AVRounding) av_const |
| Rescale a 64-bit integer with specified rounding. | |
| int64_t | av_rescale_q (int64_t a, AVRational bq, AVRational cq) av_const |
| Rescale a 64-bit integer by 2 rational numbers. | |
| int | av_compare_ts (int64_t ts_a, AVRational tb_a, int64_t ts_b, AVRational tb_b) |
| Compare 2 timestamps each in its own timebases. | |
| int64_t | av_compare_mod (uint64_t a, uint64_t b, uint64_t mod) |
| Compare 2 integers modulo mod. | |
| enum AVRounding |
Definition at line 60 of file mathematics.h.
| int64_t av_compare_mod | ( | uint64_t | a, |
| uint64_t | b, | ||
| uint64_t | mod | ||
| ) |
Compare 2 integers modulo mod.
That is we compare integers a and b for which only the least significant log2(mod) bits are known.
| mod | must be a power of 2 |
Definition at line 147 of file mathematics.c.
Referenced by av_read_frame().
| int av_compare_ts | ( | int64_t | ts_a, |
| AVRational | tb_a, | ||
| int64_t | ts_b, | ||
| AVRational | tb_b | ||
| ) |
Compare 2 timestamps each in its own timebases.
The result of the function is undefined if one of the timestamps is outside the int64_t range when represented in the others timebase.
Definition at line 139 of file mathematics.c.
Referenced by ff_gen_syncpoint_search(), ff_interleave_compare_dts(), search_hi_lo_keyframes(), and transcode().
| int64_t av_const av_gcd | ( | int64_t | a, |
| int64_t | b | ||
| ) |
Return the greatest common divisor of a and b.
If both a and b are 0 or either or both are <0 then behavior is undefined.
Definition at line 72 of file mathematics.c.
Referenced by av_gcd(), av_reduce(), avcodec_string(), avformat_find_stream_info(), config_output(), decode_main_header(), dump_stream_format(), ff_parse_specific_params(), h263_decode_picture_header(), init(), and MPV_encode_init().
| int64_t av_rescale | ( | int64_t | a, |
| int64_t | b, | ||
| int64_t | c | ||
| ) | const |
Rescale a 64-bit integer with rounding to nearest.
A simple a*b/c isn't possible as it can overflow.
Definition at line 129 of file mathematics.c.
Referenced by asf_build_simple_index(), av_dump_format(), av_estimate_timings_from_bit_rate(), av_gen_search(), av_seek_frame(), av_update_cur_dts(), avi_read_header(), compute_pkt_fields(), compute_pkt_fields2(), config_props(), dc1394_read_common(), finalize_packet(), get_pcr(), mov_build_index(), mov_find_next_sample(), mov_read_trak(), mov_write_tapt_tag(), mp3_parse_vbr_tags(), mpeg_mux_write_packet(), mpegts_write_header(), mpegts_write_packet(), mpegts_write_pes(), mxf_read_seek(), nsv_parse_NSVs_header(), output_packet(), pcm_read_seek(), r3d_read_reda(), and vqf_read_seek().
| int64_t av_rescale_q | ( | int64_t | a, |
| AVRational | bq, | ||
| AVRational | cq | ||
| ) | const |
Rescale a 64-bit integer by 2 rational numbers.
Definition at line 133 of file mathematics.c.
Referenced by av_update_stream_timings(), avformat_find_stream_info(), avi_read_packet(), avi_read_seek(), color_request_frame(), compute_chapters_end(), copy_chapters(), decode_frame(), do_audio_out(), do_subtitle_out(), do_video_out(), dv_extract_video_info(), dv_offset_reset(), dv_read_header(), ff_interleave_new_audio_packet(), ff_write_chained(), fill_all_stream_timings(), get_subtitle_pkt(), http_prepare_data(), main(), mkv_write_chapters(), mov_create_chapter_track(), mov_read_seek(), mov_write_chpl_tag(), mp3_parse_vbr_tags(), ogg_compare_granule(), oggvorbis_encode_frame(), output_packet(), parse_forced_key_frames(), read_header(), read_seek2(), rl2_read_seek(), rtcp_send_sr(), rtp_write_header(), rtsp_read_play(), rtsp_read_seek(), seek_subtitle(), source_request_frame(), start_frame(), start_frame_overlay(), transcode(), video_thread(), write_audio_frame(), and write_video_frame().
| int64_t av_rescale_rnd | ( | int64_t | a, |
| int64_t | b, | ||
| int64_t | c, | ||
| enum | AVRounding | ||
| ) | const |
Rescale a 64-bit integer with specified rounding.
A simple a*b/c isn't possible as it can overflow.
Definition at line 77 of file mathematics.c.
Referenced by applehttp_read_seek(), av_compare_ts(), av_nearer_q(), av_rescale(), av_rescale_q(), av_rescale_rnd(), compute_pkt_fields(), dv_write_pack(), ff_nut_reset_ts(), gxf_compare_field_nb(), gxf_write_media_preamble(), mov_write_edts_tag(), mov_write_mvhd_tag(), mov_write_tkhd_tag(), pcm_read_seek(), read_seek2(), rtmp_read_seek(), rtp_write_header(), vp8_init(), vqf_read_seek(), and write_packet().
1.7.6.1