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
#! /usr/bin/env python | |
# coding: utf-8 | |
# 指定フォルダ内の全ファイルをリネーム | |
import os,re,sys | |
import tempfile | |
import shutil | |
in_dir = "org" |
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
#! /usr/bin/env python | |
# coding: utf-8 | |
# ファイル名にiPhoneの高解像度向け画像の | |
# ファイル名を表す @2x を付加した名前に変更し、既存の名前で半分の画像ファイルを作成するスクリプト | |
import os,re,sys | |
import tempfile | |
import shutil | |
from PIL import Image |
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
#! /usr/bin/env python | |
# coding: utf-8 | |
import os,re,sys | |
import tempfile | |
import shutil | |
from PIL import Image | |
in_dir = "org_imgs" | |
out_dir = "crop_imgs" |
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
#! /usr/bin/env python | |
# coding: utf-8 | |
# -webkit- とベンダープレフィックスが付いている場合 | |
# 次の行に -moz- に差し替えたものを追加するプロブラム | |
# ※ @-webkit-〜 { } など、複数行に渡る場合は正しい構文に | |
# ならない事に注意 | |
import re |
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
Shader "test" { | |
Properties { | |
_Color ("Color", Color) = (1, 0, 0) | |
} | |
SubShader { | |
Color [_Color] | |
Pass {} | |
} | |
} |
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
#! /usr/bin/env python | |
# coding: utf-8 | |
from PIL import Image | |
from PIL import ImageDraw | |
screenW = 640 | |
screenH = 960 | |
img = Image.new('RGBA', (screenW, screenH), (255,255,255,0)) |
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
PImage img; | |
void setup() { | |
size(300, 200); | |
img = createImage(width, height, ARGB); | |
for (int y=0; y<img.height; y++) { | |
for (int x=0; x<img.width; x++) { | |
println((float)x/width); | |
img.pixels[y*img.width+x] = color(0, 0, 255, (float)x/width*255); | |
} |
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
using System.IO; | |
using UnityEngine; | |
using System.Collections; | |
public class example : MonoBehaviour { | |
private string path; | |
private string counter; | |
void Start () | |
{ |
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
using UnityEngine; | |
using System.Collections; | |
public class example : MonoBehaviour { | |
public GameObject targetGameObject; | |
private Mesh mesh; | |
private Vector3[] vertices; | |
private int[] indices; |
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
using UnityEngine; | |
using System.Collections; | |
public class TestGUI : MonoBehaviour { | |
private string txt = "test"; | |
public GUIText guiText; | |
public GUIText guiTextInfo; | |
public GUITexture guiTextureBg; | |
OlderNewer