xref: /aosp_15_r20/external/libdav1d/CONTRIBUTING.md (revision c09093415860a1c2373dacd84c4fde00c507cdfd)
1*c0909341SAndroid Build Coastguard Worker# dav1d contribution guide
2*c0909341SAndroid Build Coastguard Worker
3*c0909341SAndroid Build Coastguard Worker## CoC
4*c0909341SAndroid Build Coastguard WorkerThe [VideoLAN Code of Conduct](https://wiki.videolan.org/CoC) applies fully to this project.
5*c0909341SAndroid Build Coastguard Worker
6*c0909341SAndroid Build Coastguard Worker## ToDo
7*c0909341SAndroid Build Coastguard Worker
8*c0909341SAndroid Build Coastguard WorkerThe todo list can be found [on the wiki](https://code.videolan.org/videolan/dav1d/wikis/task-list).
9*c0909341SAndroid Build Coastguard Worker
10*c0909341SAndroid Build Coastguard Worker## Codebase language
11*c0909341SAndroid Build Coastguard Worker
12*c0909341SAndroid Build Coastguard WorkerThe codebase is developed with the following assumptions:
13*c0909341SAndroid Build Coastguard Worker
14*c0909341SAndroid Build Coastguard WorkerFor the library:
15*c0909341SAndroid Build Coastguard Worker- C language with C99 version, without the VLA or the Complex (*\_\_STDC_NO_COMPLEX__*) features, and without compiler extensions. Anonymous structures and unions are the only allowed compiler extensions for internal code.
16*c0909341SAndroid Build Coastguard Worker- x86 asm in .asm files, using the NASM syntax,
17*c0909341SAndroid Build Coastguard Worker- arm/arm64 in .S files, using the GAS syntax limited to subset llvm 5.0's internal assembler supports,
18*c0909341SAndroid Build Coastguard Worker- no C++ is allowed, whatever the version.
19*c0909341SAndroid Build Coastguard Worker
20*c0909341SAndroid Build Coastguard WorkerFor the tools and utils:
21*c0909341SAndroid Build Coastguard Worker- C *(see above for restrictions)*
22*c0909341SAndroid Build Coastguard Worker- Rust
23*c0909341SAndroid Build Coastguard Worker- C++ is only allowed for the MFT.
24*c0909341SAndroid Build Coastguard Worker
25*c0909341SAndroid Build Coastguard WorkerIf you want to use *Threads* or *Atomic* features, please conform to the **C11**/**POSIX** semantic and use a wrapper for older compilers/platforms *(like done in VLC)*.
26*c0909341SAndroid Build Coastguard Worker
27*c0909341SAndroid Build Coastguard WorkerPlease use modern standard POSIX functions *(strscpy, asprintf, tdestroy)*, and provide a compatibility fallback *(like done in VLC)*.
28*c0909341SAndroid Build Coastguard Worker
29*c0909341SAndroid Build Coastguard WorkerWe will make reasonable efforts for compilers that are a bit older, but we won't support gcc 3 or MSVC 2012.
30*c0909341SAndroid Build Coastguard Worker
31*c0909341SAndroid Build Coastguard Worker## Authorship
32*c0909341SAndroid Build Coastguard Worker
33*c0909341SAndroid Build Coastguard WorkerPlease provide a correct authorship for your commit logs, with a name and a valid email.
34*c0909341SAndroid Build Coastguard Worker
35*c0909341SAndroid Build Coastguard WorkerWe will reject anonymous contributions for now. As an exception, known pseudonyms from the multimedia community are accepted.
36*c0909341SAndroid Build Coastguard Worker
37*c0909341SAndroid Build Coastguard WorkerThis project is respecting **Copyright** and **Droit d'auteur**. There is no copyright attribution or CLA.
38*c0909341SAndroid Build Coastguard Worker
39*c0909341SAndroid Build Coastguard Worker## Commit logs
40*c0909341SAndroid Build Coastguard Worker
41*c0909341SAndroid Build Coastguard WorkerPlease read [How to Write a Git Commit Message](https://chris.beams.io/posts/git-commit/).
42*c0909341SAndroid Build Coastguard Worker
43*c0909341SAndroid Build Coastguard Worker## Submit requests (WIP)
44*c0909341SAndroid Build Coastguard Worker
45*c0909341SAndroid Build Coastguard Worker- Code,
46*c0909341SAndroid Build Coastguard Worker- [Compile](https://xkcd.com/303/),
47*c0909341SAndroid Build Coastguard Worker- Check your [code style](https://code.videolan.org/videolan/dav1d/wikis/Coding-style),
48*c0909341SAndroid Build Coastguard Worker- Test,
49*c0909341SAndroid Build Coastguard Worker- Try,
50*c0909341SAndroid Build Coastguard Worker- Submit patches through merge requests,
51*c0909341SAndroid Build Coastguard Worker- Check that this passes the CI.
52*c0909341SAndroid Build Coastguard Worker
53*c0909341SAndroid Build Coastguard Worker## Patent license
54*c0909341SAndroid Build Coastguard Worker
55*c0909341SAndroid Build Coastguard WorkerYou need to read, understand, and agree to the [AV1 patents license](doc/PATENTS), before committing.
56*c0909341SAndroid Build Coastguard Worker
57