Skip to content

Instantly share code, notes, and snippets.

View TyounanMOTI's full-sized avatar

Hirotoshi Yoshitaka TyounanMOTI

View GitHub Profile
@TyounanMOTI
TyounanMOTI / NoteTrim.cs
Created February 13, 2019 17:14
1音階ずつ2秒ごとに録った音をUnity上で切り分けるやつと、WAVファイル出力用のやつ
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
public class NoteTrim : ScriptableWizard {
public AudioClip clip;
public float duration = 2.0f;
public string path = "Assets/MOTI/MusicForest/";
public string[] notes = {
@TyounanMOTI
TyounanMOTI / AudioBankSortByNote.cs
Created February 13, 2019 17:11
VRC_AudioBankに一気にD&Dしたノート別AudioClipを音階順に並び替えるスクリプト
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
public class AudioBankSortByNote {
readonly static string[] noteNames = {
"C1",
"C#1",
"D1",
using NUnit.Framework;
using System.Threading.Tasks;
public class AsyncTest {
async Task<string> Subject() {
await Task.Delay(1000);
return "test";
}
[Test]
public class AudioPlayer : MonoBehaviour {
[SerializedField]
private float initialVolume;
void Start() {
Debug.Log(volume);
}
}
public class AudioEventAsset : ScriptableObject {
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
[RequireComponent (typeof(MeshFilter)), ExecuteInEditMode]
public class ArcMesh : MonoBehaviour
{
[SerializeField]
float outerRadius = 1.0f;
@TyounanMOTI
TyounanMOTI / MixerParamAttenuation.cs
Created July 2, 2017 12:40
SFX ReverbのDry Levelを距離減衰・指向性音源による減衰でコントロールするためのコンポーネント
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.Audio;
[RequireComponent(typeof(AudioSource))]
public class MixerParamAttenuation : MonoBehaviour {
AudioSource source;
AudioMixerGroup mixer;
Transform mainCamera;
=== -std=C++98, -Os ======
6.393718s wall, 1.480000s user + 4.110000s system = 5.590000s CPU (87.4%)
6.441048s wall, 2.010000s user + 3.770000s system = 5.780000s CPU (89.7%)
24.594495s wall, 5.680000s user + 13.500000s system = 19.180000s CPU (78.0%)
23.071802s wall, 5.590000s user + 12.920000s system = 18.510000s CPU (80.2%)
=== -std=C++11, -Os ======
6.956083s wall, 1.510000s user + 4.330000s system = 5.840000s CPU (84.0%)
6.532527s wall, 2.030000s user + 3.820000s system = 5.850000s CPU (89.6%)
11.977692s wall, 4.160000s user + 5.210000s system = 9.370000s CPU (78.2%)
@TyounanMOTI
TyounanMOTI / mac_build.patch
Created July 6, 2012 17:45
warsow0.7 mac_build update SHA:1ff970fd2f7 in https://github.com/TyounanMOTI/warsow_mac
diff --git angelwrap/addon/addon_dictionary.h angelwrap/addon/addon_dictionary.h
index c5d0166..8873c63 100644
--- angelwrap/addon/addon_dictionary.h
+++ angelwrap/addon/addon_dictionary.h
@@ -5,7 +5,11 @@
// string type must be registered with the engine before registering the
// dictionary type
+#if defined ( __APPLE__ )
+#include <angelscript/angelscript.h>
diff --git angelwrap/addon/addon_dictionary.h angelwrap/addon/addon_dictionary.h
index c5d0166..8873c63 100644
--- angelwrap/addon/addon_dictionary.h
+++ angelwrap/addon/addon_dictionary.h
@@ -5,7 +5,11 @@
// string type must be registered with the engine before registering the
// dictionary type
+#if defined ( __APPLE__ )
+#include <angelscript/angelscript.h>
@TyounanMOTI
TyounanMOTI / mac_build.patch
Created July 3, 2012 09:32
git diff --no-prefix 359e8fabadf696120b12d4c9428b34dd3527f2af > mac_build.patch
This file has been truncated, but you can view the full file.
diff --git libsrcs/angelscript/angelSVN/sdk/angelscript/projects/xcode/angelscript.xcodeproj/project.pbxproj libsrcs/angelscript/angelSVN/sdk/angelscript/projects/xcode/angelscript.xcodeproj/project.pbxproj
index 42aed37..b9daa61 100644
--- libsrcs/angelscript/angelSVN/sdk/angelscript/projects/xcode/angelscript.xcodeproj/project.pbxproj
+++ libsrcs/angelscript/angelSVN/sdk/angelscript/projects/xcode/angelscript.xcodeproj/project.pbxproj
@@ -1,512 +1,827 @@
-// !$*UTF8*$!
-{
- archiveVersion = 1;
- classes = {
- };