matroska | A Rust library for reading Matroska files

 by   tuffy Rust Version: v0.20.1 License: Apache-2.0

kandi X-RAY | matroska Summary

kandi X-RAY | matroska Summary

matroska is a Rust library typically used in Utilities applications. matroska has no bugs, it has no vulnerabilities, it has a Permissive License and it has low support. You can download it from GitHub.

A Rust library for reading metadata from Matroska files (.mkv, .webm, etc.). This library supports much of the same metadata reported by mkvinfo such as the file’s title, duration, track information, attachments, and so on.
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              matroska has a low active ecosystem.
              It has 20 star(s) with 4 fork(s). There are 2 watchers for this library.
              OutlinedDot
              It had no major release in the last 6 months.
              There are 1 open issues and 2 have been closed. On average issues are closed in 56 days. There are no pull requests.
              It has a neutral sentiment in the developer community.
              The latest version of matroska is v0.20.1

            kandi-Quality Quality

              matroska has no bugs reported.

            kandi-Security Security

              matroska has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.

            kandi-License License

              matroska is licensed under the Apache-2.0 License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              matroska releases are not available. You will need to build from source code and install.
              Installation instructions are not available. Examples and code snippets are available.

            Top functions reviewed by kandi - BETA

            kandi's functional review helps you automatically verify the functionalities of the libraries and avoid rework.
            Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of matroska
            Get all kandi verified functions for this library.

            matroska Key Features

            No Key Features are available at this moment for matroska.

            matroska Examples and Code Snippets

            No Code Snippets are available at this moment for matroska.

            Community Discussions

            QUESTION

            Can't write packet with unknown timestamp av_interleaved_write_frame(): Invalid argument
            Asked 2021-May-26 at 18:42

            I'm trying to convert a .ts file with this output to mkv:

            ...

            ANSWER

            Answered 2021-May-02 at 08:14

            Try to run with the -ss flag.

            Source https://stackoverflow.com/questions/66013483

            QUESTION

            webm live input to HLS live output
            Asked 2021-Apr-15 at 21:56

            I have ben struggling with this for quite some time; Essentially what I'm trying to do is broadcast my webcam from within the Browser to Ffmpeg on the server to convert into a .m3u8 HLS live stream. But I am having a few problems with video playback I initially thought it was CORS and cross origin headers however now I am thinking its to do with the way I'm trying to encode the media.

            I did a ffprobe on the input this was the response;

            ...

            ANSWER

            Answered 2021-Apr-15 at 21:56

            FFmpeg 2.8.17 is from 2015 and is way too old. Don't waste your time with this.

            Download or compile a modern version and it will work.

            Source https://stackoverflow.com/questions/67109529

            QUESTION

            Generating timestamps in webm transport stream with ffmpeg
            Asked 2021-Mar-25 at 19:11

            I am recording screen capture of my Electron app to a file, as suggested here: Save captured video to file in Electron

            It works great, but the file is a “transport stream”. I can play it in Chrome browser, but can’t adjust the time slider.

            The suggestion was to use ffmpeg to post-process the file. The simplest, straight-forward command I found is:

            ...

            ANSWER

            Answered 2021-Mar-25 at 19:11

            I am fairly sure your FFmpeg processing isn't exactly what you think it is -- with your command line, particularly with absence of certain explicit switches, FFmpeg will transcode your video and audio at its own discretion, which is why your output file is much smaller -- the data have been re-compressed, with potentially loss of quality.

            If you just want to generate the index necessary for the kind of seeking most players do, and avoid the undesired transcoding, the following command line will suffice:

            Source https://stackoverflow.com/questions/66378240

            QUESTION

            ffmpeg - 'hevc' codec changed to 'rawvideo' after copying video codec
            Asked 2021-Mar-11 at 14:36

            I am trying to convert some mkv videos with hevc codec to avi format. For this I run the following command:

            ...

            ANSWER

            Answered 2021-Mar-11 at 14:36
            Don't use AVI

            AVI is not meant to be used with HEVC.
            Use a modern output container format such as MP4, MOV, or MKV.

            If you require AVI

            A workaround is to add the -vtag hvc1 output option.

            Source https://stackoverflow.com/questions/66563579

            QUESTION

            Discord music bot's audio crashes
            Asked 2021-Mar-08 at 22:06

            I'm trying to make a discord music bot, but for some reason, the audio just crashes.

            Here's the code:

            ...

            ANSWER

            Answered 2021-Feb-25 at 02:32

            QUESTION

            FFmpeg: Concatenate .webm files some are video only some audio only some with both
            Asked 2021-Feb-26 at 02:00

            In my case I have 3 .webm files the first one is audio only, the second one is video only, the third one is audio and video.

            I want to concatenate them into a single file which shows black screen for audio only parts, video for video only parts, and plays both for the parts that have audio and video.

            The video codec is VP8, the audio codec is Opus.

            concat.txt contains the entries for the three files

            I am using the following command to concatenate them.

            ...

            ANSWER

            Answered 2021-Feb-26 at 02:00

            All files to be concatenated must have the same attributes and stream order.

            1. Add black video to audio only file:

            Source https://stackoverflow.com/questions/66375132

            QUESTION

            Trying to scale a webm video to 50% of its resolution using FFMPEG but keep getting an error (video has transparency btw)
            Asked 2021-Feb-06 at 18:37

            I'm trying to scale down a webm video with transparency using this line of commands (based off of an answer in this stackoverflow question @ How to keep transparency when scale webm file with ffmpeg):

            ffmpeg -c:v libvpx -i in.webm -c:v libvpx -vf scale=400:416 -auto-alt-ref 0 out.webm

            but I keep getting errors (for example):

            ...

            ANSWER

            Answered 2021-Feb-06 at 18:37

            QUESTION

            What the Hex is Going on with Milliseconds?
            Asked 2021-Jan-24 at 06:19

            I have the values 88 40 B0 00. They are is hex. I don't understand how, but they represent a number of nanoseconds. I need help with understand this document which outlines Matroska and WebM metadata encoding. I am relatively new to this, but I am using JavaScript to alter a file duration. What I am currently using works, but the goal is to know how to set a custom duration of the WebM video file. The document shows the following for the duration parameters:

            • Element Name
              • Duration
            • The level within an EBML tree
              • 2
            • Element ID displayed as octets
              • 0x4489
            • Mandatory
              • False
            • May occur multiple times
              • False
            • Contained in
              • 1
              • 2
              • 3
              • 4
            • Available to use in WebM
              • True
            • Description
              • Duration of the Segment in nanoseconds based on TimestampScale

            I am using the default time stamp scale (1000000). My question is how to I get those hex values, and turn them into hours:minutes:seconds:milliseconds. I simply am stumped :( 0x8840B000 doesn't help me.

            ...

            ANSWER

            Answered 2021-Jan-24 at 06:19

            Refer to the Stack Overflow question about a TimestampScale Element.

            In this question, you are asking about a Duration Element.

            The Duration Element you mentioned is made of

            • Element ID 44 89
            • Element Data Size 88 (a 1-byte Variable-Size Integer indicating 8 bytes of Element Data follow)
            • Element Data 40 B0 00 00 00 00 00 00 (a big-endian 64-bit float representation of decimal 4096)

            In JavaScript, you can convert those 8 bytes to the corresponding float value they represent using code like the following (adapted from an answer to question Convert uint8array to double in javascript)

            Source https://stackoverflow.com/questions/65833935

            QUESTION

            Explanation on Integer to Array
            Asked 2021-Jan-24 at 04:10
            Please Help

            I know that you are reading this, and I would appreciate a comment if do not have an answer because I feel that I am alone in trying to figure this out.

            How Does this Work?

            I have thoroughly read this document. It mentions an element called TimestampScale. I have downloaded probably thirty WebM example files and seen that the values following the HEX { 0x2AD7B1 or 2A D7 B1 or ['2A','D7','B1'] } or NON-HEX integers { 42 215 177 or [42, 215, 177] } are always the same: HEX { 0x830F4240 or 83 0F 42 40 or ['83', '0F', '42', '40'] } or NON-HEX integers { 131 15 66 64 or [131,15,66,64] }. The values all SHOULD be the default of 1000000 as stated in the Matroska Element Specification. So the question is... How does 0x830F4240 end up as 1000000?

            Incase Above Was Too Sloppy For You or You Want More Explanation:

            ...

            ANSWER

            Answered 2021-Jan-24 at 04:10

            The WebM container format is a subset of the Matroska container format.

            Matroska is based on EBML (Extensible Binary Meta Language).

            An EBML Document is made of Elements.

            An Element is made of an Element ID, an Element Data Size, and Element Data.

            An Element Data Size is a Variable-Size Integer. (An Element ID is also a Variable-Size Integer.)

            A Variable-Size Integer uses the kind of bit patterns shown below, where the leading bits indicate how many bytes are used and the x bits store the actual value.

            • 1-byte: 1xxxxxxx
            • 2-byte: 01xxxxxx xxxxxxxx
            • 3-byte: 001xxxxx xxxxxxxx xxxxxxxx
            • 4-byte: 0001xxxx xxxxxxxx xxxxxxxx xxxxxxxx

            and so on

            The TimestampScale Element you mentioned is made of

            • Element ID 2A D7 B1
            • Element Data Size 83 (a 1-byte Variable-Size Integer indicating 3 bytes of Element Data follow)
            • Element Data 0F 42 40 (a big endian encoding of decimal 1000000)

            Source https://stackoverflow.com/questions/65853363

            QUESTION

            How do you properly free a BitStreamFilter (bsf) without getting a double free error?
            Asked 2021-Jan-19 at 17:53

            I'm trying to write a C++ class handling MP4 movies via ffmpeg.

            First I created a couple of functions to use with std::unique<>() so that way things get released even on exceptions.

            However, I get a double free when I try to free the BitStreamFilter object, yet the documentation clearly says that each av_bsf_alloc() must be paired with an av_bsf_free() call.

            @param ctx a pointer into which the pointer to the newly-allocated context will be written. It must be freed with av_bsf_free() after the filtering is done.

            Note: emphasis mine.

            However, at the time I call the avformat_close_input() I get a double free error, even if I haven't used the two contexts for anything!? I'm thinking that there may be a packet that both allocate and both try to free. But since these two contexts are not directly connected, I really don't understand how they end up freeing something twice.

            Below is code which reproduce the error (at least on an amd64 platform). Once compiled, you can just execute it. Make sure to specify a filename as in:

            ...

            ANSWER

            Answered 2021-Jan-19 at 17:53

            It's double-freeing the AVCodecParameters* which you set here:

            Source https://stackoverflow.com/questions/65782600

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install matroska

            You can download it from GitHub.
            Rust is installed and managed by the rustup tool. Rust has a 6-week rapid release process and supports a great number of platforms, so there are many builds of Rust available at any time. Please refer rust-lang.org for more information.

            Support

            For any new features, suggestions and bugs create an issue on GitHub. If you have any questions check and ask questions on community page Stack Overflow .
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/tuffy/matroska.git

          • CLI

            gh repo clone tuffy/matroska

          • sshUrl

            git@github.com:tuffy/matroska.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link

            Explore Related Topics

            Consider Popular Rust Libraries

            996.ICU

            by 996icu

            deno

            by denoland

            rust

            by rust-lang

            alacritty

            by alacritty

            tauri

            by tauri-apps

            Try Top Libraries by tuffy

            bitstream-io

            by tuffyRust

            libdvd-audio

            by tuffyC

            emuman

            by tuffyRust

            iter-group

            by tuffyRust