Steven Borkman
4 年前
当前提交
52b02f18
共有 12 个文件被更改,包括 152 次插入 和 150 次删除
-
51com.unity.perception/Runtime/GroundTruth/Labelers/KeyPointLabeler.cs
-
3com.unity.perception/Runtime/Randomization/Parameters/ParameterTypes/CategorialParameters/AnimationClipParameter.cs
-
80com.unity.perception/Runtime/Randomization/Randomizers/RandomizerExamples/Randomizers/AnimationRandomizer.cs
-
21com.unity.perception/Runtime/Randomization/Randomizers/RandomizerExamples/Tags/AnimationRandomizerTag.cs
-
72com.unity.perception/Runtime/GroundTruth/Resources/AnimationRandomizerController.controller
-
8com.unity.perception/Runtime/GroundTruth/Resources/AnimationRandomizerController.controller.meta
-
16com.unity.perception/Runtime/GroundTruth/Labelers/PoseStateGroundTruthInfo.cs
-
3com.unity.perception/Runtime/GroundTruth/Labelers/PoseStateGroundTruthInfo.cs.meta
-
28com.unity.perception/Runtime/Randomization/Randomizers/RandomizerExamples/Randomizers/ConstantTransformRandomizer.cs
-
3com.unity.perception/Runtime/Randomization/Randomizers/RandomizerExamples/Randomizers/ConstantTransformRandomizer.cs.meta
-
14com.unity.perception/Runtime/Randomization/Randomizers/RandomizerExamples/Tags/ConstantTransformRandomizerTag.cs
-
3com.unity.perception/Runtime/Randomization/Randomizers/RandomizerExamples/Tags/ConstantTransformRandomizerTag.cs.meta
|
|||
%YAML 1.1 |
|||
%TAG !u! tag:unity3d.com,2011: |
|||
--- !u!91 &9100000 |
|||
AnimatorController: |
|||
m_ObjectHideFlags: 0 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_Name: AnimationRandomizerController |
|||
serializedVersion: 5 |
|||
m_AnimatorParameters: [] |
|||
m_AnimatorLayers: |
|||
- serializedVersion: 5 |
|||
m_Name: Base Layer |
|||
m_StateMachine: {fileID: 1300458365308884037} |
|||
m_Mask: {fileID: 0} |
|||
m_Motions: [] |
|||
m_Behaviours: [] |
|||
m_BlendingMode: 0 |
|||
m_SyncedLayerIndex: -1 |
|||
m_DefaultWeight: 0 |
|||
m_IKPass: 0 |
|||
m_SyncedLayerAffectsTiming: 0 |
|||
m_Controller: {fileID: 9100000} |
|||
--- !u!1107 &1300458365308884037 |
|||
AnimatorStateMachine: |
|||
serializedVersion: 6 |
|||
m_ObjectHideFlags: 1 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_Name: Base Layer |
|||
m_ChildStates: |
|||
- serializedVersion: 1 |
|||
m_State: {fileID: 3212544235944076811} |
|||
m_Position: {x: 390, y: 320, z: 0} |
|||
m_ChildStateMachines: [] |
|||
m_AnyStateTransitions: [] |
|||
m_EntryTransitions: [] |
|||
m_StateMachineTransitions: {} |
|||
m_StateMachineBehaviours: [] |
|||
m_AnyStatePosition: {x: 50, y: 20, z: 0} |
|||
m_EntryPosition: {x: 50, y: 120, z: 0} |
|||
m_ExitPosition: {x: 800, y: 120, z: 0} |
|||
m_ParentStateMachinePosition: {x: 800, y: 20, z: 0} |
|||
m_DefaultState: {fileID: 3212544235944076811} |
|||
--- !u!1102 &3212544235944076811 |
|||
AnimatorState: |
|||
serializedVersion: 6 |
|||
m_ObjectHideFlags: 1 |
|||
m_CorrespondingSourceObject: {fileID: 0} |
|||
m_PrefabInstance: {fileID: 0} |
|||
m_PrefabAsset: {fileID: 0} |
|||
m_Name: RandomState |
|||
m_Speed: 1 |
|||
m_CycleOffset: 0 |
|||
m_Transitions: [] |
|||
m_StateMachineBehaviours: [] |
|||
m_Position: {x: 50, y: 50, z: 0} |
|||
m_IKOnFeet: 0 |
|||
m_WriteDefaultValues: 1 |
|||
m_Mirror: 0 |
|||
m_SpeedParameterActive: 0 |
|||
m_MirrorParameterActive: 0 |
|||
m_CycleOffsetParameterActive: 0 |
|||
m_TimeParameterActive: 0 |
|||
m_Motion: {fileID: 7400000, guid: 3f8d204fb62cf440aacbef0b85ff6858, type: 2} |
|||
m_Tag: |
|||
m_SpeedParameter: |
|||
m_MirrorParameter: |
|||
m_CycleOffsetParameter: |
|||
m_TimeParameter: |
|
|||
fileFormatVersion: 2 |
|||
guid: 492c555d00e884241a46c09b49877983 |
|||
NativeFormatImporter: |
|||
externalObjects: {} |
|||
mainObjectFileID: 9100000 |
|||
userData: |
|||
assetBundleName: |
|||
assetBundleVariant: |
|
|||
using UnityEngine; |
|||
|
|||
namespace UnityEngine.Perception.GroundTruth |
|||
{ |
|||
/// <summary>
|
|||
/// Pose state ground truth information that can be applied to a gameobject. The typical use case
|
|||
/// is that this will be added to a labeled gameobject by a randomizer.
|
|||
/// </summary>
|
|||
public class PoseStateGroundTruthInfo : MonoBehaviour |
|||
{ |
|||
/// <summary>
|
|||
/// The pose state
|
|||
/// </summary>
|
|||
public string poseState; |
|||
} |
|||
} |
|
|||
fileFormatVersion: 2 |
|||
guid: 509316760ae346d1b4cac25f103fa5a7 |
|||
timeCreated: 1611613163 |
|
|||
using System; |
|||
using UnityEngine.Experimental.Perception.Randomization.Randomizers.SampleRandomizers.Tags; |
|||
|
|||
namespace UnityEngine.Experimental.Perception.Randomization.Randomizers.SampleRandomizers |
|||
{ |
|||
/// <summary>
|
|||
/// Sets a gameobject tagged with <see cref="ConstantTransformRandomizerTag"/> to the same transform(location, rotation, scale)
|
|||
/// each frame. This randomizer is useful to reset a scene to a start state, especially when used in conjunction
|
|||
/// with other randomizers that may move a gameobject.
|
|||
/// </summary>
|
|||
[Serializable] |
|||
[AddRandomizerMenu("Perception/Constant Transform Randomizer")] |
|||
public class ConstantTransformRandomizer : Randomizer |
|||
{ |
|||
/// <inheritdoc/>
|
|||
protected override void OnIterationStart() |
|||
{ |
|||
var taggedObjects = tagManager.Query<ConstantTransformRandomizerTag>(); |
|||
foreach (var taggedObject in taggedObjects) |
|||
{ |
|||
var tag = taggedObject.GetComponent<ConstantTransformRandomizerTag>(); |
|||
taggedObject.transform.position = tag.position; |
|||
taggedObject.transform.rotation = tag.rotation; |
|||
taggedObject.transform.localScale = tag.scale; |
|||
} |
|||
} |
|||
} |
|||
} |
|
|||
fileFormatVersion: 2 |
|||
guid: 6a2bb7db515c4b8bb95327b2ef6f3759 |
|||
timeCreated: 1611261464 |
|
|||
namespace UnityEngine.Experimental.Perception.Randomization.Randomizers.SampleRandomizers.Tags |
|||
{ |
|||
/// <summary>
|
|||
/// Tag to indicate which gameobjects should have the effects of <see cref="ConstantTransformRandomizer"/> applied
|
|||
/// to them.
|
|||
/// </summary>
|
|||
[AddComponentMenu("Perception/RandomizerTags/Constant Transform Randomizer Tag")] |
|||
public class ConstantTransformRandomizerTag : RandomizerTag |
|||
{ |
|||
public Vector3 position = Vector3.zero; |
|||
public Quaternion rotation; |
|||
public Vector3 scale = Vector3.one; |
|||
} |
|||
} |
|
|||
fileFormatVersion: 2 |
|||
guid: 4577b7dd026b4d69b2077ac01df61342 |
|||
timeCreated: 1611261493 |
撰写
预览
正在加载...
取消
保存
Reference in new issue