[email protected] nobolu-ootsuka-unrealengine
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
# -*- coding: utf-8 -*- | |
import os | |
from functools import partial | |
import time | |
import imp | |
import random | |
""" | |
PySide2モジュールを探し、ある場合はそちらをインポートします。 |
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
""" | |
This is what you need to do in order to get a qt window to dock next to maya channel box, | |
In all maya versions, including 2017 with PySide2 | |
""" | |
__author__ = "[email protected]" | |
import sys | |
import os | |
import logging | |
import xml.etree.ElementTree as xml |
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
# -*- coding: utf-8 -*- | |
#=========================================== | |
# カメラから直線方向にある選択メッシュに対してRayを飛ばす | |
# (視野角は考慮してないんでカメラは方向だけです。) | |
#=========================================== | |
import maya.api.OpenMaya as om | |
# vector用カメラの諸々を取得 | |
camera_selList = om.MGlobal.getSelectionListByName("camera1") |
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
from maya import cmds ,OpenMaya | |
# ジョイントのローカルXの差が出したいから | |
start = cmds.xform("joint1" , q=1 , ws = 0 , translation =1) | |
end = cmds.xform("joint2" , q=1 , ws = 0 , translation =1) | |
print("start[0]="+str(start[0])) | |
print("end[0]="+str(end[0])) | |
long=end[0]-start[0] | |
long=abs(long) | |
long=long*1 |
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
import maya.cmds as cmds | |
# ジョイントに回転をマッチさせたいから ジョイントにカーブを拘束と書く | |
node=cmds.orientConstraint( 'joint1', 'Cube' ,maintainOffset=False) | |
# ジョイントに回転をマッチさせたら消す。 | |
cmds.delete(node) | |
# リグとしてはカーブで動かしたいから カーブにジョイントを拘束と書く |
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
import unreal | |
# FBXインポート時の設定 | |
mesh_data = unreal.EditorAssetLibrary.find_asset_data(task.destination_path + task.destination_name) | |
mesh = mesh_data.get_asset() | |
mesh.skeleton | |
op = unreal.FbxImportUI() | |
op.import_materials = True # マテリアルもインポート |
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
#pragma once | |
#include "UnrealEd.h" | |
#include "SlateStyle.h" | |
#define IMAGE_BRUSH( RelativePath, ... ) FSlateImageBrush(RootToContentDir(RelativePath, TEXT(".png")), __VA_ARGS__) | |
class FMyPluginStyle : public FSlateStyleSet | |
{ | |
public: | |
FMyPluginStyle() | |
: FSlateStyleSet("MyPluginStyle") | |
{ |
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
#include "CoreMinimal.h" | |
#include "Modules/ModuleManager.h" | |
#include "../Public/MyPlugin.h" | |
#include "MyPluginStyle.h" | |
#include "LevelEditor.h" | |
#include "MultiBox/MultiBoxBuilder.h" | |
#include "Textures/SlateIcon.h" | |
#include "Editor/MainFrame/Public/Interfaces/IMainFrameModule.h" | |
#include "SWindow.h" | |
#include "SlateApplication.h" |
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
// Copyright 1998-2018 Epic Games, Inc. All Rights Reserved. | |
namespace UnrealBuildTool.Rules | |
{ | |
public class MyPlugin : ModuleRules | |
{ | |
public MyPlugin(ReadOnlyTargetRules Target) : base(Target) | |
{ | |
PublicIncludePaths.AddRange( | |
new string[] { |
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 "Custom/fragmentWithSurface" { | |
Properties { | |
_Color ("Color", Color) = (1,1,1,1) | |
_MainTex ("Albedo (RGB)", 2D) = "white" {} | |
_Glossiness ("Smoothness", Range(0,1)) = 0.5 | |
_Metallic ("Metallic", Range(0,1)) = 0.0 | |
} | |
SubShader { | |
Tags { "RenderType"="Opaque" } |
NewerOlder