Questions tagged [codec]

Codec is an implementation of compression and decompression of digital data streams and signals in different scales. Digital data like audio, video and electronic documents are been compressed and decompressed using codecs.

A codec can consist of two components: an encoder and a decoder. The encoder performs the compression (encoding) function and the decoder performs the decompression (decoding) function. Some codecs include both of these components and some codecs only include one of them.

There is mainly two kind of data compression technique.

  1. Lossless
  2. Lossy

Lossless Data Compression
Lossless data compression allows the exact original data to be reconstructed from the compressed data.

Lossy Data Compression
Lossy compression is a data encoding method that compresses data by discarding (losing) some of it. The procedure aims to minimize the amount of data that need to be held, handled.

List of Different Codecs
Wikipedia Codec List According to Catagory

FAQs
FAQ about Codecs by Microsoft
Codec Guide FAQ

Other Useful Links
Microsoft codec programming guide
ffmpeg codec programming
Codecguide

1497 questions
126
votes
7 answers

Difference between open and codecs.open in Python

There are two ways to open a text file in Python: f = open(filename) And import codecs f = codecs.open(filename, encoding="utf-8") When is codecs.open preferable to open?
BlogueroConnor
  • 1,893
  • 4
  • 17
  • 18
83
votes
1 answer

What is video timescale, timebase, or timestamp in ffmpeg?

There does not seem to be any explanation online as to what these are. People talk about them a lot. I just want to know what they are and why they are significant. Using -video_track_timescale, how would I determine a number for it? Is it random?…
Please Help
  • 929
  • 1
  • 8
  • 11
52
votes
18 answers

Flutter images not loaded (EXCEPTION: resolving an image codec)

When I try to run images assets doesn't get properly loaded, I am getting an exception: The following assertion was thrown resolving an image codec: Unable to load asset: /images/p8.png` Some weeks ago it was working and now it stopped. I tried…
Andrea Zanini
  • 630
  • 1
  • 5
  • 8
49
votes
6 answers

ffmpeg convert mov file to mp4 for HTML5 video tag IE9

I looked everywhere here and on google - there is no valid command that works for IE9. some how IE9 is missing something. All that I tried worked everywhere else: chrome,safari,mobile device etc... I want one command that will convert it and I can…
Adidi
  • 5,097
  • 4
  • 23
  • 30
44
votes
4 answers

Turn image sequence into video with transparency

I've got what seems like it should be a really simple problem, but it's proving much harder than I expected. Here's the issue: I've got a fairly large image sequence consisting of numbered frames (output from Maya, for what its worth). The images…
Cody Hatch
  • 8,857
  • 6
  • 29
  • 36
41
votes
4 answers

Choosing a video codec for screen recording

I'm doing a series of tutorials by recording the screen and my voice. Just as PNG works best for screenshots, while JPEG is better suited for photographs (although lossy), which video encoding & container formats are better for screen…
Dheeraj Vepakomma
  • 26,870
  • 17
  • 81
  • 104
37
votes
4 answers

Convert videos from .264 to .265 (HEVC) with ffmpeg

I see that there are a few questions on this subject but I am still getting errors. All I want to do is convert videos in my library to HEVC so they take up less space. I've tried this: ffmpeg -i input.mp4 -c:v libx265 output.mp4 ffmpeg seems to…
John Terragnoli
  • 371
  • 1
  • 3
  • 4
37
votes
5 answers

what is the codec for mp4 videos in python OpenCV

fourcc = cv2.cv.CV_FOURCC(*'XVID') The above line is used for avi video. In the same fashion, which codec do we use for mp4 videos in Ubuntu?
Suhail Ahmed Khan
  • 665
  • 2
  • 8
  • 10
35
votes
2 answers

Enabling libfdk_aac in ffmpeg installed with Homebrew

On macOs I always used to install or update ffmpeg through Homebrew. I use the libfdk_aac audio codec a lot so I always did this: brew reinstall ffmpeg --with-fdk-aac For some reason, since one or two brew updates, ffmpeg can no longer be installed…
RocketNuts
  • 9,958
  • 11
  • 47
  • 88
32
votes
7 answers

How can I convert from mp4 to webm?

How can I convert a video from mp4 to webm using VLC, if possible? What codec should I choose? Do I need to recode the sound? I'm trying to put html5 video on a website with flash as fallback. As I understand it, it's the only format (webm) that…
OZZIE
  • 6,609
  • 7
  • 55
  • 59
32
votes
1 answer

Could not find tag for codec pcm_alaw in stream #1, codec not currently supported in container when concatenating 2 files using ffmpeg

I am trying to concatenate two files, the first of which has audio and video while the second is video only. I use the following ffmpeg command: ffmpeg_command = ["ffmpeg", "-f", "concat", "-safe", "0", "-i", "clips_to_join.txt", "-vcodec", "copy",…
A_Matar
  • 2,210
  • 3
  • 31
  • 53
24
votes
2 answers

ffmpeg convert from H.264 (High 4:4:4 Profile) to H.264 (Main Profile)

How can I convert a video from H.264 (High 4:4:4 Profile) to H.264 (Main Profile) using ffmpeg? I can't do that with this command: ffmpeg -i 1/25359.mp4 -profile:v main out.mp4. That'd return an error: ... That'd return an error: Input #0,…
Milad
  • 692
  • 2
  • 9
  • 27
24
votes
4 answers

Where to start learning about audio or video codecs?

I am very much confused to know what happens inside the codecs. I want to learn about the elements inside audio encoders and decoders. Would be very happy if you can provide me some links where i can find some good study material. Precisely I would…
Vamsi
  • 5,853
  • 6
  • 29
  • 36
23
votes
2 answers

Decoding Opus audio data

I am trying to decode an Opus file back to raw 48 kHz. However I am unable to find any sample code to do that. My current code is this: void COpusCodec::Decode(unsigned char* encoded, short* decoded, unsigned int len) { int…
tmighty
  • 10,734
  • 21
  • 104
  • 218
21
votes
1 answer

How to use Blob URL, MediaSource or other methods to play concatenated Blobs of media fragments?

Am attempting to implement, for lack of a different description, an offline media context. The concept is to create 1 second Blobs of recorded media, with the ability to Play the 1 second Blobs independently at an HTMLMediaElement Play the full…
guest271314
  • 1
  • 15
  • 104
  • 177
1
2 3
99 100