QuickTime Player とかで画面キャプチャしたあとに gif にしたい場合
ffmpeg -i input.mov -an -r 15 -pix_fmt rgb24 -f gif -vf scale=640:-1 out.gif
これでいい感じの gif になる
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>mokuji</title> | |
<link rel="stylesheet" href="styles.css"> | |
</head> | |
<body onload="createMokuji(2,4)"> |
QuickTime Player とかで画面キャプチャしたあとに gif にしたい場合
ffmpeg -i input.mov -an -r 15 -pix_fmt rgb24 -f gif -vf scale=640:-1 out.gif
これでいい感じの gif になる
ベースはここ
趣味の領域だが、subscribe
に以下の処理を入れたり、 filter
に o -> o instanceof SomeEvent
や map
に o -> (SomeEvent) o)
を記載するとダサいのでスマートに書く
package in.tanjo.retrofit.api; | |
import retrofit2.Retrofit; | |
class BaseApi<T> { | |
T service; | |
public BaseApi(Class<T> tClass) { | |
this.service = RetrofitUtil.getInstance().create(tClass); |
// | |
// Jsonable.swift | |
// | |
// MIT License | |
// | |
// Copyright (c) 2018 tanjo | |
// | |
// Permission is hereby granted, free of charge, to any person obtaining a copy | |
// of this software and associated documentation files (the "Software"), to deal | |
// in the Software without restriction, including without limitation the rights |
document.onkeydown = function(e) { | |
if((e.ctrlKey && !e.metaKey) || (!e.ctrlKey && e.metaKey)) { | |
if (e.keyCode === 40) { | |
window.scrollTo(0,document.body.scrollHeight); | |
} | |
} | |
console.log(JSON.stringify(e.keyCode)); | |
} |
module.exports = function(controller) { | |
controller.hears(['茶', 'tea', 'おちゃ', 'りょくちゃ', '🍵', '旦', 'Tea'], ['ambient'], function(bot, message) { | |
bot.api.reactions.add({ | |
timestamp: message.ts, | |
channel: message.channel, | |
name: 'tea' | |
}); | |
}); | |
}; |
var div = document.createElement('div'); | |
div.id = "tj-pos-view"; | |
div.style.cssText = "position: fixed; right: 0; top: 0; background: black; color: white;" | |
document.body.appendChild(div); | |
document.body.addEventListener("mousemove", (e) => document.getElementById("tj-pos-view").innerText = "x: " + e.pageX + " y: " + e.pageY); |
const fs = require('fs').promises; | |
const puppeteer = require('puppeteer'); | |
const headleass = true; | |
(async () => { | |
var browser = await puppeteer.launch({ headless: headleass, args: ['--lang=ja,en-US,en'] }); | |
var page = await browser.newPage(); | |
page.setViewport({ width: 1920, height: 1080 }); | |
// 自分のツイッターのアイコン | |
var source = await page.goto('https://pbs.twimg.com/profile_images/450452672638763008/2wm_mrCJ.jpeg'); |