This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"percentDifference": null, | |
"quoteResponse": { | |
"contextSlot": 256843874, | |
"inAmount": "1000000000", | |
"inputMint": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v", | |
"otherAmountThreshold": "14254443187926", | |
"outAmount": "14268711899825", | |
"outputMint": "D8r8XTuCrUhLheWeGXSwC3G92RhASficV3YA7B2XWcLv", | |
"platformFee": null, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// first: `npm init -- yes && npm i chalk puppeteer-core` | |
// then: `node . --help` | |
const puppeteer = require('puppeteer-core'); | |
const chalk = require('chalk'); | |
// --- | |
const ifHasParam = (s = '') => process.argv.includes(s); | |
const paramValueOf = (s = '') => (process.argv.find(x => x.startsWith(`${s}=`)) || '').split('=')[1]; | |
const DEFAULT_VIDEO_ID = '5qap5aO4i9A'; // ChillCow; his other channel is "DWcJFNfaw9c" | |
const DEBUG = ifHasParam('--debug'); | |
const SHOW_HEAD = ifHasParam('--head'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Interpolate video frames for a higher frame rate | |
ffmpeg -i source.mp4 -filter:v minterpolate -r 25 result.mp4 | |
ffmpeg -i source.mp4 -vf minterpolate=50,tblend=all_mode=average,framestep=2 result.mp4 | |
# Crop a video to the bottom right quarter | |
ffmpeg -i in.mp4 -filter:v "crop=in_w/2:in_h/2:in_w/2:in_h/2" -c:a copy out.mp4 | |
# Resize a video to half size | |
ffmpeg -i input.mkv -filter_complex "scale=in_w/2:in_h/2" output.mkv |