Skip to content

Instantly share code, notes, and snippets.

View aggresss's full-sized avatar
♾️
kata

Jagger Yu aggresss

♾️
kata
View GitHub Profile

.

  • ├── avio-list-dir
  • ├── avio-reading
  • ├── decode-audio
  • ├── decode-video
  • ├── demuxing-decoding
  • ├── encode-audio
  • ├── encode-video
  • ├── extract-mvs
  • ├── filter-audio

ffmpeg 4.4.4

  • 36 ./libavcodec/ac3_parser.h
  • 37 ./libavcodec/adts_parser.h
  • 4184 ./libavcodec/avcodec.h
  • 88 ./libavcodec/avdct.h
  • 118 ./libavcodec/avfft.h
  • 325 ./libavcodec/bsf.h
  • 480 ./libavcodec/codec.h
  • 128 ./libavcodec/codec_desc.h
@aggresss
aggresss / README.md
Last active February 24, 2022 04:44

A tinker and plumber

aggresss's GitHub stats

# SSH Agent Functions
# Mark Embling (http://www.markembling.info/)
#
# How to use:
# - Place this file into %USERPROFILE%\Documents\WindowsPowershell (or location of choice)
# - Import into your profile.ps1:
# e.g. ". (Resolve-Path ~/Documents/WindowsPowershell/ssh-agent-utils.ps1)" [without quotes]
# - Enjoy
#
# Note: ensure you have ssh and ssh-agent available on your path, from Git's Unix tools or Cygwin.
@aggresss
aggresss / lazy_load_posh-git.ps1
Created January 3, 2021 01:09
Lazy load posh-git
function git_prompt {
if (-not $(Get-InstalledModule -Name "posh-git")) {
Install-Module posh-git -Scope CurrentUser -Force
}
if (-not (Get-Module -Name "posh-git")) {
Import-Module -Name posh-git -Scope Global
}
else {
$GitPromptSettings.EnablePromptStatus = -not $GitPromptSettings.EnablePromptStatus
}
@aggresss
aggresss / handling_multiple_github_accounts.md
Created December 14, 2020 11:41 — forked from Jonalogy/handling_multiple_github_accounts.md
Handling Multiple Github Accounts on MacOS

Handling Multiple Github Accounts on MacOS

The only way I've succeeded so far is to employ SSH.

Assuming you are new to this like me, first I'd like to share with you that your Mac has a SSH config file in a .ssh directory. The config file is where you draw relations of your SSH keys to each GitHub (or Bitbucket) account, and all your SSH keys generated are saved into .ssh directory by default. You can navigate to it by running cd ~/.ssh within your terminal, open the config file with any editor, and it should look something like this:

Host *
 AddKeysToAgent yes

> UseKeyChain yes

@aggresss
aggresss / webrtc.js
Created July 9, 2020 14:52 — forked from daurnimator/webrtc.js
Playing with WebAudio and WebRTC
// Browser compat
window.AudioContext = window.AudioContext || window.webkitAudioContext;
window.RTCPeerConnection = window.RTCPeerConnection || window.webkitRTCPeerConnection || window.mozRTCPeerConnection;
navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia;
var key = window.location.hash.substring(1);
var audio_context = new AudioContext();
var local_output = audio_context.createMediaStreamDestination();
@aggresss
aggresss / webrtc.js
Created July 9, 2020 14:52 — forked from daurnimator/webrtc.js
Playing with WebAudio and WebRTC
// Browser compat
window.AudioContext = window.AudioContext || window.webkitAudioContext;
window.RTCPeerConnection = window.RTCPeerConnection || window.webkitRTCPeerConnection || window.mozRTCPeerConnection;
navigator.getUserMedia = navigator.getUserMedia || navigator.webkitGetUserMedia;
var key = window.location.hash.substring(1);
var audio_context = new AudioContext();
var local_output = audio_context.createMediaStreamDestination();

Accessible color palette

A set of colors that is unambiguous both to colorblinds and non-colorblinds.

Color name R G B
Black 0 0 0
Orange 230 159 0
Sky Blue 86 180 233
Bluish Green 0 158 115
@aggresss
aggresss / ajax-success.js
Last active November 8, 2018 10:10
ajax-success
$.ajax({
type: "POST",
url: url,
contentType: "application/json; charset=utf-8",
data: JSON.stringify(data),
dataType: "json",
statusCode: {
200: function() {alert("成功")}
},
error: function(xhr, status, error) {