Skip to content

Instantly share code, notes, and snippets.

@nemurigi
nemurigi / UdonSharpProgramAssetAutoGenerator.cs
Last active April 8, 2026 01:30
UdonSharpBehaviourのインポート時、対応するUdonSharpProgramAssetが存在しない場合に自動生成するAssetPostprocessor
// MIT License
// Copyright (c) 2026 nemurigi
using System;
using System.IO;
using System.Reflection;
using UdonSharp;
using UdonSharp.Compiler;
using UdonSharpEditor;
using UnityEditor;
@nemurigi
nemurigi / shader_var_baker.py
Created September 1, 2024 07:45
VRC Houdini勉強会No.92
import hou
def get_declare(name, attrib):
data_type = attrib.dataType()
size = attrib.size()
attrib_name = attrib.name()
if not (data_type == hou.attribData.Float or data_type == hou.attribData.Int):
return ''
@nemurigi
nemurigi / MainMenuCommon.xml
Created September 1, 2024 07:41
VRC Houdini勉強会 No.92 資料
<?xml version="1.0" encoding="UTF-8"?>
<mainMenu>
<menu>
<addScriptItem id="set_unity_assets_alias">
<label>Set Unity Assets Alias</label>
<parent>preferences_submenu</parent>
<scriptCode><![CDATA[
import os
assets_path = hou.ui.selectFile(
//https://github.com/bdunderscore/modular-avatar/blob/main/Packages/nadena.dev.modular-avatar/Editor/HeuristicBoneMapper.cs
dict get_bone_mapper(){
dict bone_mapper;
bone_mapper["Hips"] = {"Hips", "Hip"};
bone_mapper["LeftUpperLeg"] = {
"LeftUpperLeg", "UpperLeg_Left", "UpperLeg_L", "Leg_Left", "Leg_L", "ULeg_L", "Left leg", "LeftUpLeg",
"UpLeg.L"
};
bone_mapper["RightUpperLeg"] = {