vim cheat sheet
useful .vimrc set tabstop=2 set shiftwidth=2 set expandtab inoremap <S-Tab> <C-V><Tab> syntax on set t_Co=256 set colorcolumn=80 “crazy vim, do not allow copy/paste set mouse=v setlocal spell spelllang=en_us “for vert…
useful .vimrc set tabstop=2 set shiftwidth=2 set expandtab inoremap <S-Tab> <C-V><Tab> syntax on set t_Co=256 set colorcolumn=80 “crazy vim, do not allow copy/paste set mouse=v setlocal spell spelllang=en_us “for vert…
Compiled lang: src — compiler –> directly to machine code Interpreter( python/js) : src-> bytecode, run on VM ( a VM load bytecode, and do some switch for each type…
Direct compile webrtc on arm64 will fail: webrtc seems does not support direct support on arm, we will get errors: … Running hooks: 18% ( 4/22) sysroot_arm64 ________ running ‘vpython…
nlohmann::json is a popluar json lib. code at: https://github.com/nlohmann/json document at: https://nlohmann.github.io/json/doxygen/index.html sample code: #include <iostream> 2 #include <nlohmann/json.hpp> 3 4 using json = nlohmann::json; 5 6 int main() 7 { 8 //…
Some notes: web assembly: a cool technology allows you to compile c/c++/rust and other languages into wasm, expose API to javascript world. Web audio worklet/worker: allows developer to intercept audio…
It is well known that if mutex protected codes could potentially be replaced by atomic compare exchange, thus we cab achieve lock-less programming. In practice, it may need several techniques…
Repo: https://github.com/meetecho/janus-gateway code: video sfu code at: plugins/janus_videoroom.c How sub/pub works: in its plugin implementation: plugins/janus_videoroom.c , there is: struct janus_videoroom_publisher { GSList subscribers; / Subscriptions to this publisher (who’s watching…
I recently submitted a patch to webrtc native. https://webrtc-review.googlesource.com/c/src/+/143841 https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!topic/discuss-webrtc/zn4kmjflvt4 The process is not that difficult, but there could be some caveats depending on your os version etc. Here is my…
vim has a grammar check plugin https://github.com/rhysd/vim-grammarous How to install vim-grammarous? it uses new vim 8+ plugin mechanism, so we can easily install it by: mkdir -p ~/.vim/pack/bundle/start cd ~/.vim/pack/bundle/start…
H.264 profile-level-id in sdp: profile-level-id = 428014 ( remember SDP use hex, wiki/h264 they use decimal ) profile_idc 0x42 == 66 so it is Baseline profile profile-iop 0x80 mean constraint_set0_flag=1 (so…