Skip to content

Instantly share code, notes, and snippets.

onionmk2

Block or report user

Report or block onionmk2

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@onionmk2
onionmk2 / UsingJsonDotNetInUnity.cs
Last active Oct 29, 2019
Json.Net ( Newtonsoft.Json ) in Unity
View UsingJsonDotNetInUnity.cs
using System;
using System.Collections.Generic;
using System.IO;
using Newtonsoft.Json;
using UnityEngine;
public class UsingJsonDotNetInUnity : MonoBehaviour
{
private void Awake()
{
@onionmk2
onionmk2 / save youtube cap.js
Last active Mar 1, 2019
save youtube caption.js
View save youtube cap.js
const divs = document.querySelectorAll(".cue.style-scope.ytd-transcript-body-renderer");
const array = Array.from(divs);
const texts = array.map(t => t.textContent.trim()+"\n");
const fileName = document.title;
const file = new File(texts, fileName, {
type: "text/plain",
});
View move cursor right by alt 2.ahk
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
; ! is Alt. Alt +2 が押されるまで待機ということ。
!2::
SysGet, monitor1, Monitor, 1
SysGet, monitor2, Monitor, 2
View move cursor left by alt 1.ahk
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
; ! is Alt. Alt +1 が押されるまで待機ということ。
!1::
SysGet, monitor1, Monitor, 1
SysGet, monitor2, Monitor, 2
View edge.py
# VEXで下記のコードが事前に必要です。
# i[]@neighbours = neighbours(0, @ptnum);
# i@point_number = @ptnum;
# [ [0, 1], [0, 3] ...] というように、edgeとなるpointの組を返します。
# get_point_pair_for_edge("point_number", "neighbours")
def get_point_pair_for_edge(ptnum_attr_name, neighbours_attr_name):
# type: (str, str) -> List[List[int]]
import hou
from itertools import chain
@onionmk2
onionmk2 / shelf_script.py
Created Dec 26, 2018
Houdini, create 2 network box and note
View shelf_script.py
# region for autocomplete
import hou
from hou import SopNode, Node
hou.attribType.Point = 1
hou.attribType.Prim = 2
hou.attribType.Vertex = 3
hou.attribType.Global = 4
from typing import List, Type, Any, Union, Callable, Tuple
View vex symbols
W
PY
intrinsic:pointcount
intrinsic:bounds
intrinsic:measuredarea
intrinsic:memoryusage
@elemnum
@ptnum
@primnum
View a.js
// paste this into web console
codes = $("code");
contents = Array.from(codes).map(i => i.textContent); //.filter(i => i.includes("@"));
uniqs = contents.filter((v, i, a) => a.indexOf(v) === i);
copy(uniqs.join('\n')); // save array to clipboard
@onionmk2
onionmk2 / pixologic.css
Created Jul 31, 2018
stylus for pixologic
View pixologic.css
.entry-content > ul > li {
margin: 0 0 0 36px;
}
.entry-content > ul {
list-style-type: circle;
}
.entry-content > ol {
list-style-type: decimal;
}
h2 {
@onionmk2
onionmk2 / VR MAGICの動画メモ.md
Last active Jul 11, 2018
【Unite 2017 Tokyo】VR MAGIC! ~キャラクターに命を吹き込んだこの4年間の記録~ https://www.youtube.com/watch?v=nWR816af2dU の動画でさらに理解がすすんだところ
View VR MAGICの動画メモ.md

イキイキしたキャラクター表現

プレゼンス

ハイライト

  • PS2くらいまではリソース不足のため、テクスチャにハイライトを書き込んでいた
    • ライトの色を変えたら、目のハイライトまでそのまま変わってしまい、イキイキ感が減る
You can’t perform that action at this time.