Functions for working with pixel formats. More...
Functions for working with pixel formats.
loss due to resolution change
Definition at line 4648 of file avcodec.h.
Referenced by avcodec_find_best_pix_fmt_of_2(), and avcodec_get_pix_fmt_loss().
loss due to color depth change
Definition at line 4649 of file avcodec.h.
Referenced by avcodec_find_best_pix_fmt_of_2(), and avcodec_get_pix_fmt_loss().
loss due to color space conversion
Definition at line 4650 of file avcodec.h.
Referenced by avcodec_find_best_pix_fmt_of_2(), and avcodec_get_pix_fmt_loss().
loss of alpha bits
Definition at line 4651 of file avcodec.h.
Referenced by avcodec_find_best_pix_fmt_of_2(), and avcodec_get_pix_fmt_loss().
loss due to color quantization
Definition at line 4652 of file avcodec.h.
Referenced by avcodec_find_best_pix_fmt_of_2(), and avcodec_get_pix_fmt_loss().
loss of chroma (e.g.
RGB to gray conversion)
Definition at line 4653 of file avcodec.h.
Referenced by avcodec_find_best_pix_fmt_of_2(), and avcodec_get_pix_fmt_loss().
Utility function to access log2_chroma_w log2_chroma_h from the pixel format AVPixFmtDescriptor.
This function asserts that pix_fmt is valid. See av_pix_fmt_get_chroma_sub_sample for one that returns a failure code and continues in case of invalid pix_fmts.
Definition at line 64 of file imgconvert.c.
Referenced by alloc_buffer(), dirac_decode_data_unit(), encode_frame(), encode_init(), ff_mjpeg_decode_frame(), ff_MPV_common_init(), ff_MPV_encode_init(), ff_print_debug_info(), j2kenc_init(), load_input_picture(), parse_source_parameters(), and vp3_decode_init().
Return a value representing the fourCC code associated to the pixel format pix_fmt, or 0 if no associated fourCC code can be found.
Definition at line 199 of file raw.c.
Referenced by avformat_find_stream_info(), raw_init_encoder(), and v4l2_read_header().
Compute what kind of losses will occur when converting from one specific pixel format to another.
When converting from one pixel format to another, information loss may occur. For example, when converting from RGB24 to GRAY, the color information will be lost. Similarly, other losses occur when converting from some formats to other formats. These losses can involve loss of chroma, but also loss of resolution, loss of color depth, loss due to the color space conversion, loss of the alpha bits or loss due to color quantization. avcodec_get_fix_fmt_loss() informs you about the various types of losses which will occur when converting from one pixel format to another.
Definition at line 106 of file imgconvert.c.
Referenced by avcodec_find_best_pix_fmt_of_2().
Find the best pixel format to convert to given a certain source pixel format.
When converting from one pixel format to another, information loss may occur. For example, when converting from RGB24 to GRAY, the color information will be lost. Similarly, other losses occur when converting from some formats to other formats. avcodec_find_best_pix_fmt_of_2() searches which of the given pixel formats should be used to suffer the least amount of loss. The pixel formats from which it chooses one, are determined by the pix_fmt_list parameter.
Definition at line 261 of file imgconvert.c.
Referenced by avcodec_find_best_pix_fmt_of_2().
Find the best pixel format to convert to given a certain source pixel format and a selection of two destination pixel formats.
When converting from one pixel format to another, information loss may occur. For example, when converting from RGB24 to GRAY, the color information will be lost. Similarly, other losses occur when converting from some formats to other formats. avcodec_find_best_pix_fmt_of_2() selects which of the given pixel formats should be used to suffer the least amount of loss.
If one of the destination formats is AV_PIX_FMT_NONE the other pixel format (if valid) will be returned.
Definition at line 199 of file imgconvert.c.
Referenced by avcodec_find_best_pix_fmt2(), avcodec_find_best_pix_fmt_of_list(), choose_pixel_fmt(), and pick_format().
Definition at line 254 of file imgconvert.c.
Referenced by avcodec_find_best_pix_fmt_of_2().
Definition at line 659 of file utils.c.
Referenced by avcodec_get_context_defaults3().