Skip to content

Commit

Permalink
Merge branch 'master' into ffmpeg7
Browse files Browse the repository at this point in the history
  • Loading branch information
Yahweasel committed Sep 26, 2024
2 parents 8507324 + 0d12712 commit d1667d0
Show file tree
Hide file tree
Showing 58 changed files with 1,003 additions and 37 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/build-and-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ jobs:

- uses: mymindstorm/setup-emsdk@v12
with:
version: 3.1.60
# Versions beyond 3.1.50 currently build bad libvpx
version: 3.1.50
actions-cache-folder: 'cache-emsdk'

- uses: actions/cache@v3
Expand Down
15 changes: 15 additions & 0 deletions LICENSE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
LGPL.

The license text for this code is in the source files.
[LICENSE files do more harm than good](https://yahweasel.github.io/license-files-considered-harmful/).

This file exists because some people expect it to be here.

libav.js builds include correct license headers. Do not remove them.

If you make modifications to this repository beyond configuration changes¹ and
distribute builds with those changes, you are *legally obligated* to share those
changes. If you do not, you are in violation of FFmpeg's license terms. I'm
looking at you, “my startup is too cool to read licenses” scumbags.

¹ i.e., changes that link to FFmpeg.
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ OPTFLAGS=-Oz
THRFLAGS=-pthread
ES6FLAGS=-sEXPORT_ES6=1 -sUSE_ES6_IMPORT_META=1
EFLAGS=\
`tools/memory-init-file-emcc.sh` \
--pre-js pre.js \
--post-js build/post.js --extern-post-js extern-post.js \
-s "EXPORT_NAME='LibAVFactory'" \
Expand Down Expand Up @@ -110,6 +111,7 @@ dist/libav-%.dbg.mjs: dist/libav-$(LIBAVJS_VERSION)-%.dbg.mjs


dist/libav.types.d.ts: build/libav.types.d.ts
mkdir -p dist
cp $< $@

# General build rule for any target
Expand Down
2 changes: 2 additions & 0 deletions Makefile.m4
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ OPTFLAGS=-Oz
THRFLAGS=-pthread
ES6FLAGS=-sEXPORT_ES6=1 -sUSE_ES6_IMPORT_META=1
EFLAGS=\
`tools/memory-init-file-emcc.sh` \
--pre-js pre.js \
--post-js build/post.js --extern-post-js extern-post.js \
-s "EXPORT_NAME='LibAVFactory'" \
Expand Down Expand Up @@ -83,6 +84,7 @@ febuildrule(.dbg, js, cat)
febuildrule(.dbg, mjs, cat)

dist/libav.types.d.ts: build/libav.types.d.ts
mkdir -p dist
cp $< $@

# General build rule for any target
Expand Down
1 change: 1 addition & 0 deletions configs/fragments/decoder-ilbc/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-decoder=ilbc
35 changes: 35 additions & 0 deletions configs/fragments/decoder-ilbc/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
*
* ---
*
* ilbcdec.c:
*
* Copyright (c) 2013, The WebRTC project authors. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* * Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in
* the documentation and/or other materials provided with the
* distribution.
*
* * Neither the name of Google nor the names of its contributors may
* be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
1 change: 1 addition & 0 deletions configs/fragments/decoder-interplay_acm/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-decoder=interplay_acm
23 changes: 23 additions & 0 deletions configs/fragments/decoder-interplay_acm/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
*
* ---
*
* interplayacm.c:
*
* Interplay ACM decoder
*
* Copyright (c) 2004-2008 Marko Kreen
* Copyright (c) 2008 Adam Gashlin
* Copyright (c) 2015 Paul B Mahol
*
* Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
1 change: 1 addition & 0 deletions configs/fragments/decoder-mjpeg/FIXME-jrevdct
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
jrevdct is used by various decoders, but mjpeg and prores seem like the only ones anyone is likely to use nowadays, which is why the license text for it lives here.
1 change: 1 addition & 0 deletions configs/fragments/decoder-mjpeg/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-decoder=mjpeg
38 changes: 38 additions & 0 deletions configs/fragments/decoder-mjpeg/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
*
* ---
*
* jrevdct.c:
*
* This file is part of the Independent JPEG Group's software.
*
* The authors make NO WARRANTY or representation, either express or implied,
* with respect to this software, its quality, accuracy, merchantability, or
* fitness for a particular purpose. This software is provided "AS IS", and
* you, its user, assume the entire risk as to its quality and accuracy.
*
* This software is copyright (C) 1991, 1992, Thomas G. Lane.
* All Rights Reserved except as specified below.
*
* Permission is hereby granted to use, copy, modify, and distribute this
* software (or portions thereof) for any purpose, without fee, subject to
* these conditions:
* (1) If any part of the source code for this software is distributed, then
* this README file must be included, with this copyright and no-warranty
* notice unaltered; and any additions, deletions, or changes to the original
* files must be clearly indicated in accompanying documentation.
* (2) If only executable code is distributed, then the accompanying
* documentation must state that "this software is based in part on the work
* of the Independent JPEG Group".
* (3) Permission for use of this software is granted only if the user accepts
* full responsibility for any undesirable consequences; the authors accept
* NO LIABILITY for damages of any kind.
*
* These conditions apply to any software derived from or based on the IJG
* code, not just to the unmodified library. If you use our work, you ought
* to acknowledge us.
*
* Permission is NOT granted for the use of any IJG author's name or company
* name in advertising or publicity relating to this software or products
* derived from it. This software may be referred to only as "the Independent
* JPEG Group's software".
*
1 change: 1 addition & 0 deletions configs/fragments/decoder-nellymoser/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-decoder=nellymoser
28 changes: 28 additions & 0 deletions configs/fragments/decoder-nellymoser/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
* ---
*
* nellymoser:
*
* Copyright (c) 2007 a840bda5870ba11f19698ff6eb9581dfb0f95fa5,
* 539459aeb7d425140b62a3ec7dbf6dc8e408a306, and
* 520e17cd55896441042b14df2566a6eb610ed444
* Copyright (c) 2007 Loic Minier <lool at dooz.org>
* Benjamin Larsson
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*
1 change: 1 addition & 0 deletions configs/fragments/decoder-prores/FIXME-jrevdct
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
jrevdct is used by various decoders, but mjpeg and prores seem like the only ones anyone is likely to use nowadays, which is why the license text for it lives here.
38 changes: 38 additions & 0 deletions configs/fragments/decoder-prores/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
*
* ---
*
* jrevdct.c:
*
* This file is part of the Independent JPEG Group's software.
*
* The authors make NO WARRANTY or representation, either express or implied,
* with respect to this software, its quality, accuracy, merchantability, or
* fitness for a particular purpose. This software is provided "AS IS", and
* you, its user, assume the entire risk as to its quality and accuracy.
*
* This software is copyright (C) 1991, 1992, Thomas G. Lane.
* All Rights Reserved except as specified below.
*
* Permission is hereby granted to use, copy, modify, and distribute this
* software (or portions thereof) for any purpose, without fee, subject to
* these conditions:
* (1) If any part of the source code for this software is distributed, then
* this README file must be included, with this copyright and no-warranty
* notice unaltered; and any additions, deletions, or changes to the original
* files must be clearly indicated in accompanying documentation.
* (2) If only executable code is distributed, then the accompanying
* documentation must state that "this software is based in part on the work
* of the Independent JPEG Group".
* (3) Permission for use of this software is granted only if the user accepts
* full responsibility for any undesirable consequences; the authors accept
* NO LIABILITY for damages of any kind.
*
* These conditions apply to any software derived from or based on the IJG
* code, not just to the unmodified library. If you use our work, you ought
* to acknowledge us.
*
* Permission is NOT granted for the use of any IJG author's name or company
* name in advertising or publicity relating to this software or products
* derived from it. This software may be referred to only as "the Independent
* JPEG Group's software".
*
1 change: 1 addition & 0 deletions configs/fragments/decoder-texturedsp/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-decoder=texturedsp
26 changes: 26 additions & 0 deletions configs/fragments/decoder-texturedsp/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
*
* ---
*
* texturedsp.c:
*
* Copyright (C) 2009 Benjamin Dobell, Glass Echidna
* Copyright (C) 2012 Matthäus G. "Anteru" Chajdas (http://anteru.net)
* Copyright (C) 2015 Vittorio Giovara <vittorio.giovara@gmail.com>
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*
1 change: 1 addition & 0 deletions configs/fragments/decoder-zerocodec/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-decoder=zerocodec
19 changes: 19 additions & 0 deletions configs/fragments/decoder-zerocodec/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
*
* ---
*
* zerocodec.c:
*
* Copyright (c) 2012, Derek Buitenhuis
*
* Permission to use, copy, modify, and/or distribute this software for any
* purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*
1 change: 1 addition & 0 deletions configs/fragments/encoder-cinepak/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-encoder=cinepak
29 changes: 29 additions & 0 deletions configs/fragments/encoder-cinepak/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
*
* ---
*
* cinepakenc.c:
*
* Cinepak encoder (c) 2011 Tomas Härdin
* http://titan.codemill.se/~tomhar/cinepakenc.patch
*
* Fixes and improvements, vintage decoders compatibility
* (c) 2013, 2014 Rl, Aetey Global Technologies AB
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR
* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
* OTHER DEALINGS IN THE SOFTWARE.
*
1 change: 1 addition & 0 deletions configs/fragments/encoder-prores/FIXME-jfdctfst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
jfdctfst is used by various encoders, but prores seems like the only one anyone is likely to use nowadays, which is why the license text for it lives here.
1 change: 1 addition & 0 deletions configs/fragments/encoder-prores/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-encoder=prores
38 changes: 38 additions & 0 deletions configs/fragments/encoder-prores/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
*
* ---
*
* jfdctfst.c:
*
* This file is part of the Independent JPEG Group's software.
*
* The authors make NO WARRANTY or representation, either express or implied,
* with respect to this software, its quality, accuracy, merchantability, or
* fitness for a particular purpose. This software is provided "AS IS", and
* you, its user, assume the entire risk as to its quality and accuracy.
*
* This software is copyright (C) 1994-1996, Thomas G. Lane.
* All Rights Reserved except as specified below.
*
* Permission is hereby granted to use, copy, modify, and distribute this
* software (or portions thereof) for any purpose, without fee, subject to
* these conditions:
* (1) If any part of the source code for this software is distributed, then
* this README file must be included, with this copyright and no-warranty
* notice unaltered; and any additions, deletions, or changes to the original
* files must be clearly indicated in accompanying documentation.
* (2) If only executable code is distributed, then the accompanying
* documentation must state that "this software is based in part on the work
* of the Independent JPEG Group".
* (3) Permission for use of this software is granted only if the user accepts
* full responsibility for any undesirable consequences; the authors accept
* NO LIABILITY for damages of any kind.
*
* These conditions apply to any software derived from or based on the IJG
* code, not just to the unmodified library. If you use our work, you ought
* to acknowledge us.
*
* Permission is NOT granted for the use of any IJG author's name or company
* name in advertising or publicity relating to this software or products
* derived from it. This software may be referred to only as "the Independent
* JPEG Group's software".
*
1 change: 1 addition & 0 deletions configs/fragments/encoder-texturedsp/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-encoder=texturedsp
27 changes: 27 additions & 0 deletions configs/fragments/encoder-texturedsp/license.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
*
* ---
*
* texturedspenc.c:
*
* Copyright (C) 2015 Vittorio Giovara <vittorio.giovara@gmail.com>
* Based on public domain code by Fabian Giesen, Sean Barrett and Yann Collet.
*
* This file is part of FFmpeg
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*
1 change: 0 additions & 1 deletion configs/fragments/ennuicastr/ffmpeg-config.txt

This file was deleted.

1 change: 1 addition & 0 deletions configs/fragments/filter-arnndn/ffmpeg-config.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
--enable-filter=arnndn
Loading

0 comments on commit d1667d0

Please sign in to comment.