A list of useful commands for the FFmpeg command line tool.
Download FFmpeg: https://www.ffmpeg.org/download.html
Full documentation: https://www.ffmpeg.org/ffmpeg.html
A list of useful commands for the FFmpeg command line tool.
Download FFmpeg: https://www.ffmpeg.org/download.html
Full documentation: https://www.ffmpeg.org/ffmpeg.html
| { | |
| ".123" : "application/vnd.lotus-1-2-3", | |
| ".3dml" : "text/vnd.in3d.3dml", | |
| ".3g2" : "video/3gpp2", | |
| ".3gp" : "video/3gpp", | |
| ".a" : "application/octet-stream", | |
| ".aab" : "application/x-authorware-bin", | |
| ".aac" : "audio/x-aac", | |
| ".aam" : "application/x-authorware-map", | |
| ".aas" : "application/x-authorware-seg", |
A non-exhaustive list of WebGL and WebGPU frameworks and libraries. It is mostly for learning purposes as some of the libraries listed are wip/outdated/not maintained anymore.
| Name | Stars | Last Commit | Description |
|---|---|---|---|
| three.js | ![GitHub Rep |
| // @return Promise<boolean> | |
| async function askWritePermission() { | |
| try { | |
| // The clipboard-write permission is granted automatically to pages | |
| // when they are the active tab. So it's not required, but it's more safe. | |
| const { state } = await navigator.permissions.query({ name: 'clipboard-write' }) | |
| return state === 'granted' | |
| } catch (error) { | |
| // Browser compatibility / Security error (ONLY HTTPS) ... | |
| return false |
| # The command finds the most recent tag that is reachable from a commit. | |
| # If the tag points to the commit, then only the tag is shown. | |
| # Otherwise, it suffixes the tag name with the number of additional commits on top of the tagged object | |
| # and the abbreviated object name of the most recent commit. | |
| git describe | |
| # With --abbrev set to 0, the command can be used to find the closest tagname without any suffix: | |
| git describe --abbrev=0 | |
| # other examples |
| <!DOCTYPE HTML> | |
| <html lang="en"><head> | |
| <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
| <title>Zooming via HTML5 Canvas Context</title> | |
| <style type="text/css" media="screen"> | |
| body { background:#eee; margin:1em; text-align:center; } | |
| canvas { display:block; margin:1em auto; background:#fff; border:1px solid #ccc } | |
| </style> | |
| </head><body> |
| // ⚠ IMPORTANT: this is old and doesn't work for many different edge cases but I'll keep it as-is for any of you want it | |
| // ⚠ IMPORTANT: you can find more robust versions in the comments or use a library implementation such as lodash's `merge` | |
| // Merge a `source` object to a `target` recursively | |
| const merge = (target, source) => { | |
| // Iterate through `source` properties and if an `Object` set property to merge of `target` and `source` properties | |
| for (const key of Object.keys(source)) { | |
| if (source[key] instanceof Object) Object.assign(source[key], merge(target[key], source[key])) | |
| } |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <title>My Iframe</title> | |
| </head> | |
| <body> | |
| <button>Botão</button> | |
| <script type="text/javascript"> |
| user www-data; | |
| http { | |
| ## | |
| # Basic Settings | |
| ## | |
| sendfile on; | |
| tcp_nopush on; |
| // By @coderitual | |
| // https://twitter.com/coderitual/status/1112297299307384833 | |
| // Remove any duplicates from an array of primitives. | |
| const unique = [...new Set(arr)] | |
| // Sleep in async functions. Use: await sleep(2000). | |
| const sleep = (ms) => (new Promise(resolve => setTimeout(resolve, ms))); | |
| // Type this in your code to break chrome debugger in that line. |