Skip to content

Instantly share code, notes, and snippets.

@cloudqq
cloudqq / metal_01_swiftui.swift
Created December 12, 2020 03:15 — forked from 0xLeif/metal_01_swiftui.swift
Metal + SwiftUI
//
// ContentView.swift
// MetalSwiftUI
//
// Created by Zach Eriksen on 9/8/20.
// Copyright © 2020 oneleif. All rights reserved.
//
// Inspired [MetalUI](https://github.com/0xLeif/MetalUI)
import SwiftUI
@cloudqq
cloudqq / YUV Sample files.txt
Created August 8, 2020 04:09 — forked from commshare/YUV Sample files.txt
YUV Sample files
http://www.sunrayimage.com/examples.html
http://trace.eas.asu.edu/yuv/ 都是yuv420p的
Example Images Download:
You can download the example images of all the suppoted formats in version 2.
@cloudqq
cloudqq / encoding-video.md
Created June 17, 2020 03:01 — forked from glen-cheney/encoding-video.md
Encoding video for the web

Encoding Video

Installing

Install FFmpeg with homebrew. You'll need to install it with a couple flags for webm and the AAC audio codec.

brew install ffmpeg --with-libvpx --with-libvorbis --with-fdk-aac --with-opus
image: vauxoo/odoo-80-image-shippable-auto
stages:
- test
- test_build
- build
- upload_image
variables:
PSQL_VERSION: "9.5"
VERSION: "saas-15"
@cloudqq
cloudqq / gist:5132edd3fb307fdf55c2f87235c55386
Created June 1, 2018 07:30 — forked from marcora/gist:cb37b2432c072e8e9d77
Install Adobe Source Code Pro font on Linux
#!/bin/sh
echo "installing fonts at $PWD to ~/.fonts/"
mkdir -p ~/.fonts/adobe-fonts/source-code-pro
git clone https://github.com/adobe-fonts/source-code-pro.git ~/.fonts/adobe-fonts/source-code-pro
# find ~/.fonts/ -iname '*.ttf' -exec echo \{\} \;
fc-cache -f -v ~/.fonts/adobe-fonts/source-code-pro
echo "finished installing"

sudo vim /etc/default/keyboard

And edit XKBOPTIONS="ctrl:nocaps"

Then, reconfigure:

sudo dpkg-reconfigure keyboard-configuration

@cloudqq
cloudqq / setup.sh
Created March 15, 2017 13:00 — forked from jmtatsch/setup.sh
Install ROS Jade on OS X El Capitan
# NOTE: These instructions do not represent a robust, self-troubleshooting install; they
# are definitely not suitable for dumping to a giant script and running as one. If you
# use them, they should be run one at a time, with an eye out for errors or problems
# along the way.
#
# The #1 issue you are likely to encounter is with Homebrew or Python packages whose
# binary components link against system Python. This will result in runtime segfaults,
# especially in rviz. If you suspect this is occurring, you can attempt to remove and
# reinstall the offending packages, or go for the nuclear option--- empty your Cellar
# and site-packages folders and start over with brewed python from the beginning.
@cloudqq
cloudqq / .profile
Created June 10, 2016 12:33
.profile for msys2
alias ls="ls --color"
alias ll="ls -l"
alias la="ls -la"
alias nano="nano -I -T 4 -$ -i -N -A"
# Win32 msys fix
alias irb="irb --noreadline"
# For msys2, add the following line to /etc/fstab and relogin
@cloudqq
cloudqq / ssh-multi.sh
Created June 6, 2016 02:58 — forked from dmytro/ssh-multi.sh
Start multiple synchronized SSH connections with Tmux
#!/bin/bash
# ssh-multi
# D.Kovalov
# Based on http://linuxpixies.blogspot.jp/2011/06/tmux-copy-mode-and-how-to-control.html
# a script to ssh multiple servers over multiple tmux panes
starttmux() {
if [ -z "$HOSTS" ]; then
@cloudqq
cloudqq / osx_automount_nfs.md
Created February 26, 2016 05:51 — forked from L422Y/osx_automount_nfs.md
Automounting NFS share in OS X into /Volumes

I have spent quite a bit of time figuring out automounts of NFS shares in OS X...

Somewhere along the line, Apple decided allowing mounts directly into /Volumes should not be possible:

/etc/auto_master (see last line):

#
# Automounter master map
#

+auto_master # Use directory service