diff --git a/Assets/OpenCVForUnity/Examples/MainModules/dnn/FacialExpressionRecognitionExample/FacialExpressionRecognitionExample.unity b/Assets/OpenCVForUnity/Examples/MainModules/dnn/FacialExpressionRecognitionExample/FacialExpressionRecognitionExample.unity index fb6b1b6..4c08462 100644 --- a/Assets/OpenCVForUnity/Examples/MainModules/dnn/FacialExpressionRecognitionExample/FacialExpressionRecognitionExample.unity +++ b/Assets/OpenCVForUnity/Examples/MainModules/dnn/FacialExpressionRecognitionExample/FacialExpressionRecognitionExample.unity @@ -43,7 +43,7 @@ RenderSettings: --- !u!157 &4 LightmapSettings: m_ObjectHideFlags: 0 - serializedVersion: 11 + serializedVersion: 12 m_GIWorkflowMode: 1 m_GISettings: serializedVersion: 2 @@ -67,9 +67,6 @@ LightmapSettings: m_LightmapParameters: {fileID: 0} m_LightmapsBakeMode: 1 m_TextureCompression: 0 - m_FinalGather: 0 - m_FinalGatherFiltering: 1 - m_FinalGatherRayCount: 1024 m_ReflectionCompression: 2 m_MixedBakeMode: 1 m_BakeBackend: 0 @@ -98,13 +95,13 @@ LightmapSettings: m_TrainingDataDestination: TrainingData m_LightProbeSampleCountMultiplier: 4 m_LightingDataAsset: {fileID: 0} - m_UseShadowmask: 0 + m_LightingSettings: {fileID: 1969507427} --- !u!196 &5 NavMeshSettings: serializedVersion: 2 m_ObjectHideFlags: 0 m_BuildSettings: - serializedVersion: 2 + serializedVersion: 3 agentTypeID: 0 agentRadius: 0.5 agentHeight: 2 @@ -117,15 +114,16 @@ NavMeshSettings: cellSize: 0.16666666 manualTileSize: 0 tileSize: 256 - accuratePlacement: 0 + buildHeightMesh: 0 + maxJobWorkers: 0 + preserveTilesOutsideBounds: 0 debug: m_Flags: 0 m_NavMeshData: {fileID: 0} --- !u!1 &266668974 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -145,18 +143,17 @@ GameObject: --- !u!224 &266668975 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 266668974} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 696772637} m_Father: {fileID: 1419009409} - m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} @@ -166,8 +163,7 @@ RectTransform: --- !u!114 &266668976 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400016, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 266668974} @@ -187,8 +183,7 @@ MonoBehaviour: --- !u!114 &266668977 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400018, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 266668974} @@ -199,6 +194,7 @@ MonoBehaviour: m_EditorClassIdentifier: m_Navigation: m_Mode: 3 + m_WrapAround: 0 m_SelectOnUp: {fileID: 0} m_SelectOnDown: {fileID: 0} m_SelectOnLeft: {fileID: 0} @@ -229,6 +225,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnPauseButtonClick m_Mode: 1 m_Arguments: @@ -242,8 +239,7 @@ MonoBehaviour: --- !u!114 &266668978 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400020, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 266668974} @@ -255,6 +251,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -272,8 +269,7 @@ MonoBehaviour: --- !u!222 &266668979 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 266668974} @@ -290,6 +286,7 @@ GameObject: - component: {fileID: 395431854} - component: {fileID: 395431852} - component: {fileID: 395431851} + - component: {fileID: 395431856} m_Layer: 0 m_Name: Main Camera m_TagString: MainCamera @@ -327,9 +324,17 @@ Camera: m_projectionMatrixMode: 1 m_GateFitMode: 2 m_FOVAxisMode: 0 + m_Iso: 200 + m_ShutterSpeed: 0.005 + m_Aperture: 16 + m_FocusDistance: 10 + m_FocalLength: 50 + m_BladeCount: 5 + m_Curvature: {x: 2, y: 11} + m_BarrelClipping: 0.25 + m_Anamorphism: 0 m_SensorSize: {x: 36, y: 24} m_LensShift: {x: 0, y: 0} - m_FocalLength: 50 m_NormalizedViewPortRect: serializedVersion: 2 x: 0 @@ -363,18 +368,62 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 395431850} + serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 1, z: -10} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &395431856 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 395431850} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: a79441f348de89743a2939f4d699eac1, type: 3} + m_Name: + m_EditorClassIdentifier: + m_RenderShadows: 1 + m_RequiresDepthTextureOption: 2 + m_RequiresOpaqueTextureOption: 2 + m_CameraType: 0 + m_Cameras: [] + m_RendererIndex: -1 + m_VolumeLayerMask: + serializedVersion: 2 + m_Bits: 1 + m_VolumeTrigger: {fileID: 0} + m_VolumeFrameworkUpdateModeOption: 2 + m_RenderPostProcessing: 0 + m_Antialiasing: 0 + m_AntialiasingQuality: 2 + m_StopNaN: 0 + m_Dithering: 0 + m_ClearDepth: 1 + m_AllowXRRendering: 1 + m_AllowHDROutput: 1 + m_UseScreenCoordOverride: 0 + m_ScreenSizeOverride: {x: 0, y: 0, z: 0, w: 0} + m_ScreenCoordScaleBias: {x: 0, y: 0, z: 0, w: 0} + m_RequiresDepthTexture: 0 + m_RequiresColorTexture: 0 + m_Version: 2 + m_TaaSettings: + quality: 3 + frameInfluence: 0.1 + jitterScale: 1 + mipBias: 0 + varianceClampScale: 0.9 + contrastAdaptiveSharpening: 0 --- !u!1 &686826706 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -392,17 +441,16 @@ GameObject: --- !u!224 &686826707 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 686826706} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1699795913} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -412,8 +460,7 @@ RectTransform: --- !u!114 &686826708 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 686826706} @@ -425,6 +472,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -446,8 +494,7 @@ MonoBehaviour: --- !u!222 &686826709 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 686826706} @@ -455,8 +502,7 @@ CanvasRenderer: --- !u!1 &696772636 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -474,17 +520,16 @@ GameObject: --- !u!224 &696772637 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 696772636} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 266668975} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -494,8 +539,7 @@ RectTransform: --- !u!114 &696772638 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 696772636} @@ -507,6 +551,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -528,8 +573,7 @@ MonoBehaviour: --- !u!222 &696772639 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 696772636} @@ -537,8 +581,7 @@ CanvasRenderer: --- !u!1 &1037250637 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100002, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -557,18 +600,17 @@ GameObject: --- !u!224 &1037250638 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400002, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1037250637} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 0, y: 0, z: 0} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 1419009409} m_Father: {fileID: 0} - m_RootOrder: 2 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} @@ -578,8 +620,7 @@ RectTransform: --- !u!114 &1037250639 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400002, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1037250637} @@ -596,8 +637,7 @@ MonoBehaviour: --- !u!114 &1037250640 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400004, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1037250637} @@ -616,11 +656,11 @@ MonoBehaviour: m_FallbackScreenDPI: 96 m_DefaultSpriteDPI: 96 m_DynamicPixelsPerUnit: 1 + m_PresetInfoIsWorld: 0 --- !u!223 &1037250641 Canvas: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22300000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1037250637} @@ -634,15 +674,16 @@ Canvas: m_OverrideSorting: 0 m_OverridePixelPerfect: 0 m_SortingBucketNormalizedSize: 0 + m_VertexColorAlwaysGammaSpace: 0 m_AdditionalShaderChannelsFlag: 25 + m_UpdateRectTransformForStandalone: 0 m_SortingLayerID: 0 m_SortingOrder: 0 m_TargetDisplay: 0 --- !u!1 &1045041045 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100000, guid: 516b0ed7bbe49b54eb11d0acece129f1, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -660,8 +701,7 @@ GameObject: --- !u!114 &1045041047 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400002, guid: 516b0ed7bbe49b54eb11d0acece129f1, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1045041045} @@ -670,6 +710,7 @@ MonoBehaviour: m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, type: 3} m_Name: m_EditorClassIdentifier: + m_SendPointerHoverToParent: 1 m_HorizontalAxis: Horizontal m_VerticalAxis: Vertical m_SubmitButton: Submit @@ -680,8 +721,7 @@ MonoBehaviour: --- !u!114 &1045041048 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400004, guid: 516b0ed7bbe49b54eb11d0acece129f1, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1045041045} @@ -696,23 +736,22 @@ MonoBehaviour: --- !u!4 &1045041049 Transform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 400000, guid: 516b0ed7bbe49b54eb11d0acece129f1, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1045041045} + serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1144110445 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -730,8 +769,7 @@ GameObject: --- !u!114 &1144110446 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1144110445} @@ -743,6 +781,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -764,8 +803,7 @@ MonoBehaviour: --- !u!222 &1144110447 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1144110445} @@ -773,17 +811,16 @@ CanvasRenderer: --- !u!224 &1144110448 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1144110445} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1200307540} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -793,8 +830,7 @@ RectTransform: --- !u!1 &1177067774 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100004, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -814,18 +850,17 @@ GameObject: --- !u!224 &1177067775 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400004, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1177067774} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 1585318593} m_Father: {fileID: 1419009409} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} @@ -835,8 +870,7 @@ RectTransform: --- !u!114 &1177067776 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1177067774} @@ -856,8 +890,7 @@ MonoBehaviour: --- !u!114 &1177067777 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400008, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1177067774} @@ -868,6 +901,7 @@ MonoBehaviour: m_EditorClassIdentifier: m_Navigation: m_Mode: 3 + m_WrapAround: 0 m_SelectOnUp: {fileID: 0} m_SelectOnDown: {fileID: 0} m_SelectOnLeft: {fileID: 0} @@ -898,6 +932,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnBackButtonClick m_Mode: 1 m_Arguments: @@ -911,8 +946,7 @@ MonoBehaviour: --- !u!114 &1177067778 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1177067774} @@ -924,6 +958,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -941,8 +976,7 @@ MonoBehaviour: --- !u!222 &1177067779 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200002, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1177067774} @@ -950,8 +984,7 @@ CanvasRenderer: --- !u!1 &1200307539 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -971,18 +1004,17 @@ GameObject: --- !u!224 &1200307540 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1200307539} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 1144110448} m_Father: {fileID: 1419009409} - m_RootOrder: 3 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} @@ -992,8 +1024,7 @@ RectTransform: --- !u!114 &1200307541 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400016, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1200307539} @@ -1013,8 +1044,7 @@ MonoBehaviour: --- !u!114 &1200307542 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400018, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1200307539} @@ -1025,6 +1055,7 @@ MonoBehaviour: m_EditorClassIdentifier: m_Navigation: m_Mode: 3 + m_WrapAround: 0 m_SelectOnUp: {fileID: 0} m_SelectOnDown: {fileID: 0} m_SelectOnLeft: {fileID: 0} @@ -1055,6 +1086,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnStopButtonClick m_Mode: 1 m_Arguments: @@ -1068,8 +1100,7 @@ MonoBehaviour: --- !u!114 &1200307543 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400020, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1200307539} @@ -1081,6 +1112,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -1098,8 +1130,7 @@ MonoBehaviour: --- !u!222 &1200307544 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1200307539} @@ -1107,8 +1138,7 @@ CanvasRenderer: --- !u!1 &1419009408 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -1125,14 +1155,14 @@ GameObject: --- !u!224 &1419009409 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1419009408} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 1177067775} - {fileID: 1699795913} @@ -1140,7 +1170,6 @@ RectTransform: - {fileID: 1200307540} - {fileID: 1499899214} m_Father: {fileID: 1037250638} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -1150,8 +1179,7 @@ RectTransform: --- !u!114 &1419009410 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400012, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1419009408} @@ -1173,11 +1201,11 @@ MonoBehaviour: m_ChildControlHeight: 1 m_ChildScaleWidth: 0 m_ChildScaleHeight: 0 + m_ReverseArrangement: 0 --- !u!1 &1499899213 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -1197,18 +1225,17 @@ GameObject: --- !u!224 &1499899214 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1499899213} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 1620370069} m_Father: {fileID: 1419009409} - m_RootOrder: 4 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} @@ -1218,8 +1245,7 @@ RectTransform: --- !u!114 &1499899215 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400016, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1499899213} @@ -1239,8 +1265,7 @@ MonoBehaviour: --- !u!114 &1499899216 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400018, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1499899213} @@ -1251,6 +1276,7 @@ MonoBehaviour: m_EditorClassIdentifier: m_Navigation: m_Mode: 3 + m_WrapAround: 0 m_SelectOnUp: {fileID: 0} m_SelectOnDown: {fileID: 0} m_SelectOnLeft: {fileID: 0} @@ -1281,6 +1307,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnChangeCameraButtonClick m_Mode: 1 m_Arguments: @@ -1294,8 +1321,7 @@ MonoBehaviour: --- !u!114 &1499899217 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400020, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1499899213} @@ -1307,6 +1333,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -1324,8 +1351,7 @@ MonoBehaviour: --- !u!222 &1499899218 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1499899213} @@ -1333,8 +1359,7 @@ CanvasRenderer: --- !u!1 &1585318592 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100008, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -1352,17 +1377,16 @@ GameObject: --- !u!224 &1585318593 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400008, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1585318592} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1177067775} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -1372,8 +1396,7 @@ RectTransform: --- !u!114 &1585318594 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400014, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1585318592} @@ -1385,6 +1408,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -1406,8 +1430,7 @@ MonoBehaviour: --- !u!222 &1585318595 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200004, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1585318592} @@ -1415,8 +1438,7 @@ CanvasRenderer: --- !u!1 &1620370068 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -1434,17 +1456,16 @@ GameObject: --- !u!224 &1620370069 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1620370068} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 1499899214} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 1, y: 1} @@ -1454,8 +1475,7 @@ RectTransform: --- !u!114 &1620370070 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1620370068} @@ -1467,6 +1487,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 0.196, g: 0.196, b: 0.196, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -1488,8 +1509,7 @@ MonoBehaviour: --- !u!222 &1620370071 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200000, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1620370068} @@ -1497,8 +1517,7 @@ CanvasRenderer: --- !u!1 &1699795908 GameObject: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 100010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} serializedVersion: 6 @@ -1518,8 +1537,7 @@ GameObject: --- !u!114 &1699795909 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400016, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1699795908} @@ -1539,8 +1557,7 @@ MonoBehaviour: --- !u!114 &1699795910 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400018, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1699795908} @@ -1551,6 +1568,7 @@ MonoBehaviour: m_EditorClassIdentifier: m_Navigation: m_Mode: 3 + m_WrapAround: 0 m_SelectOnUp: {fileID: 0} m_SelectOnDown: {fileID: 0} m_SelectOnLeft: {fileID: 0} @@ -1581,6 +1599,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnPlayButtonClick m_Mode: 1 m_Arguments: @@ -1594,8 +1613,7 @@ MonoBehaviour: --- !u!114 &1699795911 MonoBehaviour: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 11400020, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1699795908} @@ -1607,6 +1625,7 @@ MonoBehaviour: m_Material: {fileID: 0} m_Color: {r: 1, g: 1, b: 1, a: 1} m_RaycastTarget: 1 + m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} m_Maskable: 1 m_OnCullStateChanged: m_PersistentCalls: @@ -1624,8 +1643,7 @@ MonoBehaviour: --- !u!222 &1699795912 CanvasRenderer: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22200006, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1699795908} @@ -1633,18 +1651,17 @@ CanvasRenderer: --- !u!224 &1699795913 RectTransform: m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 22400010, guid: 4859e20a6237a7041959573320b6a033, - type: 2} + m_CorrespondingSourceObject: {fileID: 0} m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1699795908} m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 686826707} m_Father: {fileID: 1419009409} - m_RootOrder: 1 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} m_AnchorMin: {x: 0, y: 0} m_AnchorMax: {x: 0, y: 0} @@ -1684,10 +1701,12 @@ MeshRenderer: m_CastShadows: 1 m_ReceiveShadows: 1 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 0 m_ReflectionProbeUsage: 1 m_RayTracingMode: 2 + m_RayTraceProcedural: 0 m_RenderingLayerMask: 1 m_RendererPriority: 0 m_Materials: @@ -1712,6 +1731,7 @@ MeshRenderer: m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} --- !u!64 &1709852083 MeshCollider: m_ObjectHideFlags: 0 @@ -1720,9 +1740,17 @@ MeshCollider: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1709852081} m_Material: {fileID: 0} + m_IncludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_ExcludeLayers: + serializedVersion: 2 + m_Bits: 0 + m_LayerOverridePriority: 0 m_IsTrigger: 0 + m_ProvidesContacts: 0 m_Enabled: 1 - serializedVersion: 4 + serializedVersion: 5 m_Convex: 0 m_CookingOptions: 30 m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} @@ -1741,12 +1769,13 @@ Transform: m_PrefabInstance: {fileID: 0} m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1709852081} + serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 640, y: 480, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 0} - m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!114 &1709852086 MonoBehaviour: @@ -1774,6 +1803,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnWebCamTextureToMatHelperInitialized m_Mode: 1 m_Arguments: @@ -1788,6 +1818,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnWebCamTextureToMatHelperDisposed m_Mode: 1 m_Arguments: @@ -1802,6 +1833,7 @@ MonoBehaviour: m_PersistentCalls: m_Calls: - m_Target: {fileID: 1709852087} + m_TargetAssemblyTypeName: m_MethodName: OnWebCamTextureToMatHelperErrorOccurred m_Mode: 0 m_Arguments: @@ -1845,3 +1877,72 @@ MonoBehaviour: boxHeight: 110 padding: {x: 8, y: 5} consoleHeight: 50 +--- !u!850595691 &1969507427 +LightingSettings: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Settings.lighting + serializedVersion: 7 + m_GIWorkflowMode: 1 + m_EnableBakedLightmaps: 1 + m_EnableRealtimeLightmaps: 0 + m_RealtimeEnvironmentLighting: 1 + m_BounceScale: 1 + m_AlbedoBoost: 1 + m_IndirectOutputScale: 1 + m_UsingShadowmask: 0 + m_BakeBackend: 1 + m_LightmapMaxSize: 1024 + m_LightmapSizeFixed: 0 + m_BakeResolution: 50 + m_Padding: 2 + m_LightmapCompression: 0 + m_AO: 0 + m_AOMaxDistance: 1 + m_CompAOExponent: 0 + m_CompAOExponentDirect: 0 + m_ExtractAO: 0 + m_MixedBakeMode: 1 + m_LightmapsBakeMode: 1 + m_FilterMode: 1 + m_LightmapParameters: {fileID: 15204, guid: 0000000000000000f000000000000000, type: 0} + m_ExportTrainingData: 0 + m_TrainingDataDestination: TrainingData + m_RealtimeResolution: 1 + m_ForceWhiteAlbedo: 0 + m_ForceUpdates: 0 + m_PVRCulling: 1 + m_PVRSampling: 1 + m_PVRDirectSampleCount: 32 + m_PVRSampleCount: 512 + m_PVREnvironmentSampleCount: 512 + m_PVREnvironmentReferencePointCount: 2048 + m_LightProbeSampleCountMultiplier: 4 + m_PVRBounces: 2 + m_PVRMinBounces: 2 + m_PVREnvironmentImportanceSampling: 0 + m_PVRFilteringMode: 0 + m_PVRDenoiserTypeDirect: 0 + m_PVRDenoiserTypeIndirect: 0 + m_PVRDenoiserTypeAO: 0 + m_PVRFilterTypeDirect: 0 + m_PVRFilterTypeIndirect: 0 + m_PVRFilterTypeAO: 0 + m_PVRFilteringGaussRadiusDirect: 1 + m_PVRFilteringGaussRadiusIndirect: 5 + m_PVRFilteringGaussRadiusAO: 2 + m_PVRFilteringAtrousPositionSigmaDirect: 0.5 + m_PVRFilteringAtrousPositionSigmaIndirect: 2 + m_PVRFilteringAtrousPositionSigmaAO: 1 + m_PVRTiledBaking: 0 + m_RespectSceneVisibilityWhenBakingGI: 0 +--- !u!1660057539 &9223372036854775807 +SceneRoots: + m_ObjectHideFlags: 0 + m_Roots: + - {fileID: 1709852085} + - {fileID: 395431855} + - {fileID: 1037250638} + - {fileID: 1045041049} diff --git a/Assets/_VoiceAssistant/AIChatTookit/Scripts/LLM/LLM.cs b/Assets/_VoiceAssistant/AIChatTookit/Scripts/LLM/LLM.cs index 096db13..461cb7b 100644 --- a/Assets/_VoiceAssistant/AIChatTookit/Scripts/LLM/LLM.cs +++ b/Assets/_VoiceAssistant/AIChatTookit/Scripts/LLM/LLM.cs @@ -43,8 +43,8 @@ public class LLM:MonoBehaviour //提示词处理 string message = m_Prompt + - " 回答的语言:" + lan + - " 接下来是我的提问:" + _msg; + " The language of reply is " + lan + + " here's my question:" + _msg; UnityEngine.Debug.Log("玩家post:" + message); //缓存发送的信息列表 diff --git a/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/Azure/AzureTextToSpeech.cs b/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/Azure/AzureTextToSpeech.cs index af93664..4b13d1f 100644 --- a/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/Azure/AzureTextToSpeech.cs +++ b/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/Azure/AzureTextToSpeech.cs @@ -7,7 +7,10 @@ using UnityEngine.Networking; public class AzureTextToSpeech : TTS { public AudioClip saySorry; + public AudioClip lookBad; public AudioClip[] sayHello; + public AudioClip lookHappy; + public AudioClip lookSurprise; #region 参数定义 /// /// Azure配置项 @@ -55,10 +58,22 @@ public class AzureTextToSpeech : TTS { callback(sayHello[UnityEngine.Random.Range(0, sayHello.Length)]); } - else + else if(presetAudio == PresetAudio.SorrySaid) { callback(saySorry); } + else if(presetAudio == PresetAudio.LookBad) + { + callback(lookBad); + } + else if (presetAudio == PresetAudio.LookHappy) + { + callback(lookHappy); + } + else if (presetAudio == PresetAudio.LookSurprised) + { + callback(lookSurprise); + } } diff --git a/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/TTS.cs b/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/TTS.cs index 40b74cb..d33150c 100644 --- a/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/TTS.cs +++ b/Assets/_VoiceAssistant/AIChatTookit/Scripts/TTS&&STT/TTS.cs @@ -9,7 +9,10 @@ public class TTS : MonoBehaviour public enum PresetAudio { SayHi, - SorrySaid + SorrySaid, + LookBad, + LookSurprised, + LookHappy } /// /// 语音合成的api地址 diff --git a/Assets/_VoiceAssistant/com.richframe.frame.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ActionQueue.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ActionQueue.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ActionQueue.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ActionQueue.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ActionQueue/ActionQueue.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressControl.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Controller/ProgressController/ProgressManager.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/EventSystem.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/EventSystem.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/EventSystem.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/EventSystem.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/EventSystem/EventManager.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/EventSystem/EventManager.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/EventSystem/EventManager.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/EventSystem/EventManager.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/EventSystem/EventManager.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/EventSystem/EventManager.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/EventSystem/EventManager.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/EventSystem/EventManager.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/GetInput.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/GetInput.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/GetInput.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/GetInput.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/GetInput.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/GetInput.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/GetInput.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/GetInput.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/IInputListener.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/IInputListener.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/IInputListener.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/IInputListener.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/IInputListener.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/IInputListener.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Input/IInputListener.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Input/IInputListener.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/BaseState.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/BaseState.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/BaseState.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/BaseState.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/BaseState.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/BaseState.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/BaseState.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/BaseState.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/StateManager.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/StateManager.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/StateManager.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/StateManager.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/StateManager.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/StateManager.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/StateMachine/StateManager.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/StateMachine/StateManager.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIForm.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Base/UIManager.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/NormalUIForm.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Util.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Util.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Util.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Util.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/UIFrame/Util/UIMask.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/CustomAnimation.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/CustomAnimation.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/CustomAnimation.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/CustomAnimation.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/CustomAnimation/CustomAnimation.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/DontDestroyOnLoad.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/ObjectPool.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/ObjectPool.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/ObjectPool.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/ObjectPool.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/ObjectPool.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/ObjectPool.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/ObjectPool.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/ObjectPool.cs.meta diff --git a/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/Singleton.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/Singleton.cs new file mode 100644 index 0000000..218cb83 --- /dev/null +++ b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/Singleton.cs @@ -0,0 +1,26 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +namespace RichFrame +{ + /// + /// 单例 + /// + /// + public class Singleton : MonoBehaviour where T : MonoBehaviour + { + public static T Instance + { + get + { + if (_Instance == null) + { + _Instance = FindObjectOfType(); + } + return _Instance; + } + } + static T _Instance; + } +} diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/Singleton.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/Singleton.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/Singleton.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/Util/Singleton.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/com.richframe.frame.asmdef b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/com.richframe.frame.asmdef similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/com.richframe.frame.asmdef rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/com.richframe.frame.asmdef diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/com.richframe.frame.asmdef.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/com.richframe.frame.asmdef.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Runtime/com.richframe.frame.asmdef.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Runtime/com.richframe.frame.asmdef.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test/ActionQueueTest.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/ActionQueueTest.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test/ActionQueueTest.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/ActionQueueTest.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test/ActionQueueTest.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/ActionQueueTest.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test/ActionQueueTest.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/ActionQueueTest.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test/EventManagerTest.cs b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/EventManagerTest.cs similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test/EventManagerTest.cs rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/EventManagerTest.cs diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test/EventManagerTest.cs.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/EventManagerTest.cs.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test/EventManagerTest.cs.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/EventManagerTest.cs.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test/com.richframe.test.asmdef b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/com.richframe.test.asmdef similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test/com.richframe.test.asmdef rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/com.richframe.test.asmdef diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Test/com.richframe.test.asmdef.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/com.richframe.test.asmdef.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/Test/com.richframe.test.asmdef.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/Test/com.richframe.test.asmdef.meta diff --git a/Assets/_VoiceAssistant/com.richframe.frame/package.json b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/package.json similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/package.json rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/package.json diff --git a/Assets/_VoiceAssistant/com.richframe.frame/package.json.meta b/Assets/_VoiceAssistant/Plugins/com.richframe.frame/package.json.meta similarity index 100% rename from Assets/_VoiceAssistant/com.richframe.frame/package.json.meta rename to Assets/_VoiceAssistant/Plugins/com.richframe.frame/package.json.meta diff --git a/Assets/_VoiceAssistant/Scenes/ChatScene.unity b/Assets/_VoiceAssistant/Scenes/ChatScene.unity index 4553564..fc34f0a 100644 --- a/Assets/_VoiceAssistant/Scenes/ChatScene.unity +++ b/Assets/_VoiceAssistant/Scenes/ChatScene.unity @@ -120,6 +120,175 @@ NavMeshSettings: debug: m_Flags: 0 m_NavMeshData: {fileID: 0} +--- !u!1 &42567472 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 42567473} + - component: {fileID: 42567479} + - component: {fileID: 42567477} + - component: {fileID: 42567476} + - component: {fileID: 42567480} + m_Layer: 0 + m_Name: OpenCV + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &42567473 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 42567472} + serializedVersion: 2 + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0.1619103, y: 1.36112, z: 2.4244072} + m_LocalScale: {x: 640, y: 480, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 725449907} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &42567476 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 42567472} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: df35b0c19ca97734e87299a664cea35f, type: 3} + m_Name: + m_EditorClassIdentifier: + _requestedDeviceName: + _requestedWidth: 640 + _requestedHeight: 480 + _requestedIsFrontFacing: 0 + _requestedFPS: 30 + _rotate90Degree: 0 + _flipVertical: 0 + _flipHorizontal: 0 + _outputColorFormat: 3 + _timeoutFrameCount: 1500 + onInitialized: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 42567480} + m_TargetAssemblyTypeName: OpenCVForUnityExample.MFacialExpressionRecognition, + Assembly-CSharp + m_MethodName: OnWebCamTextureToMatHelperInitialized + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + onDisposed: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 42567480} + m_TargetAssemblyTypeName: OpenCVForUnityExample.MFacialExpressionRecognition, + Assembly-CSharp + m_MethodName: OnWebCamTextureToMatHelperDisposed + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + onErrorOccurred: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 42567480} + m_TargetAssemblyTypeName: OpenCVForUnityExample.MFacialExpressionRecognition, + Assembly-CSharp + m_MethodName: OnWebCamTextureToMatHelperErrorOccurred + m_Mode: 0 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + avoidAndroidFrontCameraLowLightIssue: 0 +--- !u!23 &42567477 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 42567472} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 0 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: d5c2a09c8f8d079458801d608271b579, type: 2} + m_StaticBatchInfo: + firstSubMesh: 0 + subMeshCount: 0 + m_StaticBatchRoot: {fileID: 0} + m_ProbeAnchor: {fileID: 0} + m_LightProbeVolumeOverride: {fileID: 0} + m_ScaleInLightmap: 1 + m_ReceiveGI: 1 + m_PreserveUVs: 0 + m_IgnoreNormalsForChartDetection: 0 + m_ImportantGI: 0 + m_StitchLightmapSeams: 0 + m_SelectedEditorRenderState: 3 + m_MinimumChartSize: 4 + m_AutoUVMaxDistance: 0.5 + m_AutoUVMaxAngle: 89 + m_LightmapParameters: {fileID: 0} + m_SortingLayerID: 0 + m_SortingLayer: 0 + m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} +--- !u!33 &42567479 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 42567472} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!114 &42567480 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 42567472} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 956d8fd069f661f4aa9eb1055d305572, type: 3} + m_Name: + m_EditorClassIdentifier: + testInputImage: --- !u!1 &69452801 GameObject: m_ObjectHideFlags: 0 @@ -430,7 +599,7 @@ Transform: m_Children: - {fileID: 1370441789} - {fileID: 1864357025} - m_Father: {fileID: 0} + m_Father: {fileID: 1867627730} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &178736804 GameObject: @@ -904,6 +1073,7 @@ GameObject: m_Component: - component: {fileID: 334146834} - component: {fileID: 334146835} + - component: {fileID: 334146836} m_Layer: 0 m_Name: ChatBox m_TagString: Untagged @@ -919,9 +1089,9 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 334146833} serializedVersion: 2 - m_LocalRotation: {x: -0, y: 0.20791169, z: -0, w: 0.9781476} - m_LocalPosition: {x: -1.2509742, y: 1.49, z: 0.16220574} - m_LocalScale: {x: 0.59341, y: 0.59341, z: 0.59341} + m_LocalRotation: {x: 7.912123e-10, y: 0.2079117, z: 0.0000000037223615, w: 0.9781476} + m_LocalPosition: {x: -1.2509742, y: 1.4899998, z: 0.16220571} + m_LocalScale: {x: 0.5934101, y: 0.59340996, z: 0.59340996} m_ConstrainProportionsScale: 0 m_Children: - {fileID: 1260374842} @@ -979,6 +1149,19 @@ SpriteRenderer: m_WasSpriteAssigned: 1 m_MaskInteraction: 0 m_SpriteSortPoint: 0 +--- !u!114 &334146836 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 334146833} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d7a321df2a6cc0143875c6264f77afea, type: 3} + m_Name: + m_EditorClassIdentifier: + textMeshPro: {fileID: 1260374843} --- !u!95 &343958444 stripped Animator: m_CorrespondingSourceObject: {fileID: 5866666021909216657, guid: 659354b3e275286478812f96994daf50, type: 3} @@ -1385,7 +1568,7 @@ AudioSource: Spatialize: 0 SpatializePostEffects: 0 Priority: 128 - DopplerLevel: 1 + DopplerLevel: 0 MinDistance: 1 MaxDistance: 500 Pan2D: 0 @@ -1437,7 +1620,7 @@ AudioSource: m_Curve: - serializedVersion: 3 time: 0 - value: 0 + value: 1 inSlope: 0 outSlope: 0 tangentMode: 0 @@ -1470,12 +1653,12 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 489438414} serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0, y: 0, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] - m_Father: {fileID: 0} + m_Father: {fileID: 994815019} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &520604338 GameObject: @@ -1659,7 +1842,7 @@ GameObject: - component: {fileID: 571998187} m_Layer: 0 m_Name: Camera - m_TagString: Untagged + m_TagString: MainCamera m_Icon: {fileID: 0} m_NavMeshLayer: 0 m_StaticEditorFlags: 0 @@ -1860,6 +2043,51 @@ CanvasRenderer: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 606057521} m_CullTransparentMesh: 1 +--- !u!1 &606618096 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 606618097} + - component: {fileID: 606618098} + m_Layer: 0 + m_Name: '[TakeCare]' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &606618097 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 606618096} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 1867627730} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &606618098 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 606618096} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: cc9a370b3125d7145a714b241092c418, type: 3} + m_Name: + m_EditorClassIdentifier: + expressionRecognition: {fileID: 725449908} --- !u!1001 &617804397 PrefabInstance: m_ObjectHideFlags: 0 @@ -2842,6 +3070,55 @@ PrefabInstance: m_AddedGameObjects: [] m_AddedComponents: [] m_SourcePrefab: {fileID: 100100000, guid: 80b2fb52097f8c2409921cb59ed6c40b, type: 3} +--- !u!1 &725449906 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 725449907} + - component: {fileID: 725449908} + m_Layer: 0 + m_Name: '[FaceExpression]' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &725449907 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 725449906} + serializedVersion: 2 + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 1020181388} + - {fileID: 42567473} + m_Father: {fileID: 1867627730} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &725449908 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 725449906} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 960242e255f62c34e943f3a352559541, type: 3} + m_Name: + m_EditorClassIdentifier: + triggerEventDuration: 2 + resetExpDurationInterval: 5 + triggerEventCD: 5 --- !u!1 &757868372 GameObject: m_ObjectHideFlags: 0 @@ -2866,14 +3143,14 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 757868372} serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: -0.6697998, y: 1.4160436, z: -0.05155917} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: - {fileID: 2023088797} - {fileID: 401420926} - m_Father: {fileID: 0} + m_Father: {fileID: 1867627730} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &761275341 GameObject: @@ -3350,12 +3627,12 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 830768046} serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 113.66112, y: 36.962967, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] - m_Father: {fileID: 0} + m_Father: {fileID: 1867627730} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &834105487 GameObject: @@ -4097,7 +4374,7 @@ MonoBehaviour: voiceInputs: {fileID: 830768047} voiceWakeUp: {fileID: 1674986169} chatHistory: [] - textMeshPro: {fileID: 1260374843} + chatBox: {fileID: 334146836} currentTalking: --- !u!4 &994815019 Transform: @@ -4112,10 +4389,169 @@ Transform: m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: + - {fileID: 489438416} - {fileID: 334146834} - {fileID: 343958445} m_Father: {fileID: 0} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &1020181387 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1020181388} + - component: {fileID: 1020181393} + - component: {fileID: 1020181392} + - component: {fileID: 1020181391} + - component: {fileID: 1020181390} + - component: {fileID: 1020181389} + m_Layer: 0 + m_Name: OpenCV-UVC + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &1020181388 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1020181387} + serializedVersion: 2 + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0.1619103, y: 1.36112, z: 2.4244072} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 725449907} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &1020181389 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1020181387} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: a07b9addfb2161e4b8fbdc35b3ed9531, type: 3} + m_Name: + m_EditorClassIdentifier: + testInputImage: +--- !u!114 &1020181390 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1020181387} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 84a7daacad6b09f48b400beb5b4ddb06, type: 3} + m_Name: + m_EditorClassIdentifier: + _requestedDeviceName: 1 + _requestedWidth: 640 + _requestedHeight: 480 + _requestedIsFrontFacing: 1 + _requestedFPS: 17 + _rotate90Degree: 0 + _flipVertical: 0 + _flipHorizontal: 0 + _outputColorFormat: 1 + _timeoutFrameCount: 300 + onInitialized: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1020181389} + m_TargetAssemblyTypeName: OpenCVForUnityExample.FacialExpressionRecognition_UVC, + Assembly-CSharp + m_MethodName: OnWebCamTextureToMatHelperInitialized + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + onDisposed: + m_PersistentCalls: + m_Calls: + - m_Target: {fileID: 1020181389} + m_TargetAssemblyTypeName: OpenCVForUnityExample.FacialExpressionRecognition_UVC, + Assembly-CSharp + m_MethodName: OnWebCamTextureToMatHelperDisposed + m_Mode: 1 + m_Arguments: + m_ObjectArgument: {fileID: 0} + m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine + m_IntArgument: 0 + m_FloatArgument: 0 + m_StringArgument: + m_BoolArgument: 0 + m_CallState: 2 + onErrorOccurred: + m_PersistentCalls: + m_Calls: [] + uvcTexture: {fileID: 0} + avoidAndroidFrontCameraLowLightIssue: 0 +--- !u!114 &1020181391 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1020181387} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: f7e3fa0f7bdc68444abad301469f7cf7, type: 3} + m_Name: + m_EditorClassIdentifier: + DefaultWidth: 1280 + DefaultHeight: 720 + PreferH264: 0 + RenderBeforeSceneRendering: 0 + UVCDrawers: + - {fileID: 1020181393} +--- !u!114 &1020181392 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1020181387} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 6eca0239a3e830b45b761684e2a8c8ca, type: 3} + m_Name: + m_EditorClassIdentifier: +--- !u!114 &1020181393 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1020181387} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: b48c16e283709764bb9d934a3f73886c, type: 3} + m_Name: + m_EditorClassIdentifier: + sizeScale: 0.5 + isFrontFacing: 0 + UVCFilters: + - Description: + Vid: 0 + Pid: 0 + DeviceName: /dev/bus/usb/002/008 + IsExclude: 0 --- !u!1 &1174160297 GameObject: m_ObjectHideFlags: 0 @@ -4327,7 +4763,7 @@ MonoBehaviour: m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_text: Thinking... + m_text: m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} m_sharedMaterial: {fileID: 2180264, guid: 8f586378b4e144a9851e7b34d9b748ee, type: 2} @@ -4354,8 +4790,8 @@ MonoBehaviour: m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_fontSize: 1.86 - m_fontSizeBase: 1.86 + m_fontSize: 1.4 + m_fontSizeBase: 1.4 m_fontWeight: 400 m_enableAutoSizing: 0 m_fontSizeMin: 18 @@ -4835,12 +5271,12 @@ Transform: m_PrefabAsset: {fileID: 0} m_GameObject: {fileID: 1674986168} serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} m_LocalPosition: {x: 0.89272064, y: 0.28622746, z: -1.1412808} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: [] - m_Father: {fileID: 0} + m_Father: {fileID: 1867627730} m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!4 &1693404508 stripped Transform: @@ -5560,7 +5996,8 @@ MonoBehaviour: m_Name: m_EditorClassIdentifier: url: https://aip.baidubce.com/rpc/2.0/ai_custom/v1/wenxinworkshop/chat/eb-instant - m_Prompt: "\u4F60\u626E\u6F14\u540D\u53EBcare bot\u7684\u5927\u4F17\u6C7D\u8F66\u673A\u5668\u4EBA\u52A9\u624B\u548C\u6211\u5BF9\u8BDD\uFF0C100\u5B57\u4EE5\u5185\uFF0C\u4E0D\u8981\u4F7F\u7528\u8868\u60C5" + m_Prompt: You play the role of a Volkswagen robot assistant named "care bot" and + talk to me in 50 words or less, keep it short and don't use emojis. lan: english m_HistoryKeepCount: 15 m_DataList: [] @@ -5583,6 +6020,43 @@ MonoBehaviour: m_GetTokenFromServer: 0 m_Token: 24.a5b8cc45726132275717268035aa4f9f.2592000.1701917245.282335-42480460 m_AuthorizeURL: https://aip.baidubce.com/oauth/2.0/token +--- !u!1 &1867627729 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1867627730} + m_Layer: 0 + m_Name: '[Scripts]' + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &1867627730 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 1867627729} + serializedVersion: 2 + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 830768048} + - {fileID: 1674986170} + - {fileID: 757868373} + - {fileID: 178558178} + - {fileID: 725449907} + - {fileID: 606618097} + m_Father: {fileID: 0} + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} --- !u!1 &1871013865 GameObject: m_ObjectHideFlags: 0 @@ -5842,9 +6316,12 @@ MonoBehaviour: m_EditorClassIdentifier: m_PostURL: saySorry: {fileID: 8300000, guid: c86b1d89cfa640f479dfb144ae41de2c, type: 3} + lookBad: {fileID: 8300000, guid: 1a832d6973b62754e8b3ed14465a278b, type: 3} sayHello: - {fileID: 8300000, guid: 1c56f34f88846f44fbcec4823676fdd4, type: 3} - {fileID: 8300000, guid: 38a3652b1638ddb47859c87bc97e0fc8, type: 3} + lookHappy: {fileID: 0} + lookSurprise: {fileID: 8300000, guid: 3c6e71f6457937b469d6f6fae991700c, type: 3} m_AzureSettings: {fileID: 2023088800} voiceName: en-US-GuyNeural style: chat @@ -6274,13 +6751,9 @@ SceneRoots: - {fileID: 571998185} - {fileID: 761275345} - {fileID: 549504102} - - {fileID: 178558178} - - {fileID: 757868373} - {fileID: 854293664} - {fileID: 144129215} - - {fileID: 489438416} - - {fileID: 1674986170} - - {fileID: 830768048} + - {fileID: 1181482635} - {fileID: 657372508} - {fileID: 994815019} - - {fileID: 1181482635} + - {fileID: 1867627730} diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/CarAssistant.cs b/Assets/_VoiceAssistant/Scripts/Assistant/CarAssistant.cs index 1bb04da..8f978a6 100644 --- a/Assets/_VoiceAssistant/Scripts/Assistant/CarAssistant.cs +++ b/Assets/_VoiceAssistant/Scripts/Assistant/CarAssistant.cs @@ -25,7 +25,7 @@ public class CarAssistant : MonoBehaviour public VoiceWakeUp voiceWakeUp; //保存聊天记录 public List chatHistory; - public TextMeshPro textMeshPro; + public ChatBox chatBox; public string currentTalking = ""; /// /// 启用语音唤醒 @@ -50,10 +50,13 @@ public class CarAssistant : MonoBehaviour } } bool _EnableVoiceWakeup = false; + [NonSerialized] + public Expression expression = Expression.Neutral; public event Action onReceiveText; private void Awake() { + audioSource.dopplerLevel = 0; statusManager = new StatusManager(this); } @@ -81,6 +84,7 @@ public class CarAssistant : MonoBehaviour { if (successed) { + PlayPresetAudioClip(TTS.PresetAudio.SayHi); statusManager.MakeTransition(statusManager.listening); } } @@ -108,8 +112,17 @@ public class CarAssistant : MonoBehaviour public void PlayAudioClip(AudioClip clip) { - audioSource.clip = clip; - audioSource.Play(); + audioSource.PlayOneShot(clip); + } + /// + /// 播放预设的音频 + /// + /// + public void PlayPresetAudioClip(TTS.PresetAudio presetAudio) + { + chatSettings.m_TextToSpeech.Speak(presetAudio, (clip) => { + audioSource.PlayOneShot(clip); + }); } /// @@ -177,4 +190,14 @@ public class CarAssistant : MonoBehaviour statusManager.MakeTransition(statusManager.talking); }); } + + public enum Expression + { + Neutral = 0, + Happy = 1, + Sad = 2, + Doubt = 3, + Suprised = 4, + Smile = 5 + } } diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/Status_Idle.cs b/Assets/_VoiceAssistant/Scripts/Assistant/Status_Idle.cs index 7b9dc67..dc626f5 100644 --- a/Assets/_VoiceAssistant/Scripts/Assistant/Status_Idle.cs +++ b/Assets/_VoiceAssistant/Scripts/Assistant/Status_Idle.cs @@ -9,7 +9,7 @@ public class Status_Idle : AssistantStatus base.EnterState(); assistant.animController.Idle(); assistant.EnableVoiceWakeup = true; - assistant.textMeshPro.text = "Idle..."; + assistant.chatBox.SetText("Idle...", assistant.expression); } public override void QuitState() { diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/Status_Listening.cs b/Assets/_VoiceAssistant/Scripts/Assistant/Status_Listening.cs index c73dc5d..5e4dd0e 100644 --- a/Assets/_VoiceAssistant/Scripts/Assistant/Status_Listening.cs +++ b/Assets/_VoiceAssistant/Scripts/Assistant/Status_Listening.cs @@ -11,12 +11,9 @@ public class Status_Listening : AssistantStatus { base.EnterState(); assistant.animController.SayHi(); - assistant.chatSettings.m_TextToSpeech.Speak(TTS.PresetAudio.SayHi,(clip)=> { - assistant.PlayAudioClip(clip); - }); assistant.voiceInputs.StartRecordAudio(); assistant.EnableVoiceWakeup = false; - assistant.textMeshPro.text = "Listening..."; + assistant.chatBox.SetText("Listening...", assistant.expression); } public override void Update() { diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/Status_Talking.cs b/Assets/_VoiceAssistant/Scripts/Assistant/Status_Talking.cs index ea178e6..ab38261 100644 --- a/Assets/_VoiceAssistant/Scripts/Assistant/Status_Talking.cs +++ b/Assets/_VoiceAssistant/Scripts/Assistant/Status_Talking.cs @@ -10,7 +10,7 @@ public class Status_Talking : AssistantStatus assistant.animController.StartSpeek(); PlayVoice(assistant.clip, assistant.currentTalking); assistant.EnableVoiceWakeup = true; - assistant.textMeshPro.text = "Talking..."; + assistant.chatBox.SetText("Talking...", assistant.expression); } public override void QuitState() diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/Staus_Thinking.cs b/Assets/_VoiceAssistant/Scripts/Assistant/Staus_Thinking.cs index 487d935..e0f6618 100644 --- a/Assets/_VoiceAssistant/Scripts/Assistant/Staus_Thinking.cs +++ b/Assets/_VoiceAssistant/Scripts/Assistant/Staus_Thinking.cs @@ -10,7 +10,7 @@ public class Status_Thinking : AssistantStatus base.EnterState(); assistant.animController.Thinking(); assistant.EnableVoiceWakeup = false; - assistant.textMeshPro.text = "Thinking..."; + assistant.chatBox.SetText("Thinking...",assistant.expression); } public override void Update() diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/TakeCare.cs b/Assets/_VoiceAssistant/Scripts/Assistant/TakeCare.cs new file mode 100644 index 0000000..7c9ca3b --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/Assistant/TakeCare.cs @@ -0,0 +1,54 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class TakeCare : MonoBehaviour +{ + public ExpressionRecognition expressionRecognition; + CarAssistant carAssistant; + private void Awake() + { + carAssistant = FindObjectOfType(); + expressionRecognition.onRecognizingExpression += ProcessExpression; + } + public void ProcessExpression(FaceInfo.Expression expression) + { + Debug.Log("处理表情:" + expression); + switch (expression) + { + case FaceInfo.Expression.Neutral: + break; + case FaceInfo.Expression.Happy://播放彩蛋 + carAssistant.animController.Dance(); + carAssistant.expression = CarAssistant.Expression.Happy; + carAssistant.chatBox.SetText("", CarAssistant.Expression.Happy); + break; + case FaceInfo.Expression.Sad: + case FaceInfo.Expression.Disgust: + case FaceInfo.Expression.Angry: + //问候 + StopAllCoroutines(); + carAssistant.PlayPresetAudioClip(TTS.PresetAudio.LookBad); + carAssistant.expression = CarAssistant.Expression.Smile; + StartCoroutine(TransitionToStatusDelay(carAssistant.statusManager.listening, 2f)); + break; + case FaceInfo.Expression.Suprised: + //问候 + StopAllCoroutines(); + carAssistant.PlayPresetAudioClip(TTS.PresetAudio.LookSurprised); + carAssistant.expression = CarAssistant.Expression.Doubt; + StartCoroutine(TransitionToStatusDelay(carAssistant.statusManager.listening, 2f)); + break; + case FaceInfo.Expression.Fearful: + break; + default: + break; + } + } + + IEnumerator TransitionToStatusDelay(AssistantStatus status,float delay) + { + yield return new WaitForSeconds(delay); + carAssistant.statusManager.MakeTransition(status); + } +} diff --git a/Assets/_VoiceAssistant/Scripts/Assistant/TakeCare.cs.meta b/Assets/_VoiceAssistant/Scripts/Assistant/TakeCare.cs.meta new file mode 100644 index 0000000..0879c1a --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/Assistant/TakeCare.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: cc9a370b3125d7145a714b241092c418 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/CharacterAnimControlBase.cs b/Assets/_VoiceAssistant/Scripts/CharacterAnimControlBase.cs index 666e152..f646ddd 100644 --- a/Assets/_VoiceAssistant/Scripts/CharacterAnimControlBase.cs +++ b/Assets/_VoiceAssistant/Scripts/CharacterAnimControlBase.cs @@ -11,5 +11,6 @@ public abstract class CharacterAnimControlBase : MonoBehaviour public abstract void Thinking(); public abstract void Idle(); + public abstract void Dance(); } diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression.meta new file mode 100644 index 0000000..a487c8c --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 093673d5dde9d24489180575c5618d29 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/ExpressionRecognition.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/ExpressionRecognition.cs new file mode 100644 index 0000000..ff1d685 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/ExpressionRecognition.cs @@ -0,0 +1,131 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.Events; + +public class ExpressionRecognition : MonoBehaviour +{ + public FaceInfo.Expression currentExpression + { + get + { + return _currentExpression; + } + private set + { + if(_currentExpression != value) + { + _currentExpression = value; + if(!expressionDuration.ContainsKey(value)) + { + expressionDuration.Add(value, new ExpressionDuration()); + } + } + } + } + FaceInfo.Expression _currentExpression; + Dictionary expressionDuration = new Dictionary(); + /// + /// 当检测到一个表情持续一定时间后,触发事件 + /// + public float triggerEventDuration = 2; + /// + /// 当一个表情长时间未检测到,就重置它的状态 + /// + public float resetExpDurationInterval = 5; + /// + /// 触发表情事件后的冷却时间 + /// + public float triggerEventCD = 20; + public event UnityAction onRecognizingExpression; + IFaceRecognizer recognizer; + float triggerCDTimer = 0; + class ExpressionDuration + { + /// + /// 检测到的时长 + /// + public float duration + { + get + { + return _duration; + } + set + { + _duration = value; + unrecognizedInterval = 0; + } + } + float _duration; + /// + /// 未检测到的时间间隔 + /// + public float unrecognizedInterval; + } + private void Awake() + { + recognizer = GetComponentInChildren(false); + recognizer.BindListener(OnRecognizedFaces); + triggerCDTimer = triggerEventCD; + } + + // Start is called before the first frame update + void Start() + { + + } + + // Update is called once per frame + void Update() + { + triggerCDTimer += Time.deltaTime; + foreach (var item in expressionDuration) + { + if(item.Key == currentExpression) + { + item.Value.duration += Time.deltaTime; + //当前表情持续时间大于一定值后,触发表情识别事件 + if (item.Key != FaceInfo.Expression.Neutral && item.Value.duration > triggerEventDuration && triggerCDTimer > triggerEventCD) + { + Debug.Log("触发表情:" + currentExpression); + triggerCDTimer = 0; + if (onRecognizingExpression != null) + onRecognizingExpression(item.Key); + } + } + else + { + item.Value.unrecognizedInterval += Time.deltaTime; + if (item.Value.unrecognizedInterval > resetExpDurationInterval) + { + item.Value.duration = 0; + } + } + } + } + + void OnRecognizedFaces(FaceInfo[] infos) + { + if(infos!= null && infos.Length > 0) + { + FaceInfo largestFace = infos[0]; + for (int i = 1; i < infos.Length; i++) + { + var info = infos[i]; + //取面积最大的一个 + if (info.box.height * info.box.width > largestFace.box.height * largestFace.box.width) + { + largestFace = info; + } + } + currentExpression = largestFace.expression; + return; + } + else + { + currentExpression = FaceInfo.Expression.Neutral; + return; + } + } +} diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/ExpressionRecognition.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/ExpressionRecognition.cs.meta new file mode 100644 index 0000000..33dfd86 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/ExpressionRecognition.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 960242e255f62c34e943f3a352559541 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/FaceInfo.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/FaceInfo.cs new file mode 100644 index 0000000..892839d --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/FaceInfo.cs @@ -0,0 +1,28 @@ +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public class FaceInfo +{ + public enum Expression + { + Neutral = 0, + Happy = 1, + Sad = 2, + Disgust = 3, + Suprised = 4, + Fearful = 5, + Angry + } + public enum Gender + { + N = 0, + Male, + Female + } + public Expression expression; + public Gender gender; + public int age; + public float confidence; + public Rect box; +} diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/FaceInfo.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/FaceInfo.cs.meta new file mode 100644 index 0000000..9d05a51 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/FaceInfo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: fbbadf751503a8b44b88b05bb5798624 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/FacialExpressionRecognition_UVC.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/FacialExpressionRecognition_UVC.cs new file mode 100644 index 0000000..8ad0bc8 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/FacialExpressionRecognition_UVC.cs @@ -0,0 +1,463 @@ +#if !UNITY_WSA_10_0 + +using OpenCVForUnity.CoreModule; +using OpenCVForUnity.ImgcodecsModule; +using OpenCVForUnity.ImgprocModule; +using OpenCVForUnity.UnityUtils; +using OpenCVForUnity.UnityUtils.Helper; +using OpenCVForUnityExample.DnnModel; +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.SceneManagement; + +namespace OpenCVForUnityExample +{ + /// + /// Facial Expression Recognition Example + /// An example of using OpenCV dnn module with Facial Expression Recognition. + /// Referring to https://github.com/opencv/opencv_zoo/tree/master/models/facial_expression_recognition + /// + [RequireComponent(typeof(UVCCameraToMatHelper))] + public class FacialExpressionRecognition_UVC : MonoBehaviour,IFaceRecognizer + { + [Header("TEST")] + + [TooltipAttribute("Path to test input image.")] + public string testInputImage; + + /// + /// The texture. + /// + Texture2D texture; + + /// + /// The webcam texture to mat helper. + /// + UVCCameraToMatHelper usbCamTextureToMatHelper; + + /// + /// The bgr mat. + /// + Mat bgrMat; + + /// + /// The facial expression recognizer. + /// + MFacialExpressionRecognizer facialExpressionRecognizer; + + /// + /// The FPS monitor. + /// + FpsMonitor fpsMonitor; + + /// + /// FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME + /// + protected static readonly string FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME = "OpenCVForUnity/dnn/facial_expression_recognition_mobilefacenet_2022july.onnx"; + + /// + /// The facial expression recognition model filepath. + /// + string facial_expression_recognition_model_filepath; + + /// + /// FACE_RECOGNITION_MODEL_FILENAME + /// + protected static readonly string FACE_RECOGNITION_MODEL_FILENAME = "OpenCVForUnity/dnn/face_recognition_sface_2021dec.onnx"; + + /// + /// The face recognition model filepath. + /// + string face_recognition_model_filepath; + + + /// + /// The YuNetV2FaceDetector. + /// + YuNetV2FaceDetector faceDetector; + + int inputSizeW = 320; + int inputSizeH = 320; + float scoreThreshold = 0.9f; + float nmsThreshold = 0.3f; + int topK = 5000; + + /// + /// FACE_DETECTION_MODEL_FILENAME + /// + protected static readonly string FACE_DETECTION_MODEL_FILENAME = "OpenCVForUnity/dnn/face_detection_yunet_2023mar.onnx"; + + /// + /// The face detection model filepath. + /// + string face_detection_model_filepath; + + event Action onReconizedFaces; + +#if UNITY_WEBGL + IEnumerator getFilePath_Coroutine; +#endif + + // Use this for initialization + void Start() + { + fpsMonitor = GetComponent(); + + usbCamTextureToMatHelper = gameObject.GetComponent(); + +#if UNITY_WEBGL + getFilePath_Coroutine = GetFilePath(); + StartCoroutine(getFilePath_Coroutine); +#else + face_detection_model_filepath = Utils.getFilePath(FACE_DETECTION_MODEL_FILENAME); + facial_expression_recognition_model_filepath = Utils.getFilePath(FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME); + face_recognition_model_filepath = Utils.getFilePath(FACE_RECOGNITION_MODEL_FILENAME); + Run(); +#endif + } + +#if UNITY_WEBGL + private IEnumerator GetFilePath() + { + var getFilePathAsync_0_Coroutine = Utils.getFilePathAsync(FACE_DETECTION_MODEL_FILENAME, (result) => + { + face_detection_model_filepath = result; + }); + yield return getFilePathAsync_0_Coroutine; + + var getFilePathAsync_1_Coroutine = Utils.getFilePathAsync(FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME, (result) => + { + facial_expression_recognition_model_filepath = result; + }); + yield return getFilePathAsync_1_Coroutine; + + var getFilePathAsync_2_Coroutine = Utils.getFilePathAsync(FACE_RECOGNITION_MODEL_FILENAME, (result) => + { + face_recognition_model_filepath = result; + }); + yield return getFilePathAsync_2_Coroutine; + + getFilePath_Coroutine = null; + + Run(); + } +#endif + + // Use this for initialization + void Run() + { + //if true, The error log of the Native side OpenCV will be displayed on the Unity Editor Console. + Utils.setDebugMode(true); + + + if (string.IsNullOrEmpty(face_detection_model_filepath)) + { + Debug.LogError(FACE_DETECTION_MODEL_FILENAME + " is not loaded. Please read “StreamingAssets/OpenCVForUnity/dnn/setup_dnn_module.pdf” to make the necessary setup."); + } + else + { + faceDetector = new YuNetV2FaceDetector(face_detection_model_filepath, "", new Size(inputSizeW, inputSizeH), scoreThreshold, nmsThreshold, topK); + } + + if (string.IsNullOrEmpty(facial_expression_recognition_model_filepath) || string.IsNullOrEmpty(face_recognition_model_filepath)) + { + Debug.LogError(FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME + " or " + FACE_RECOGNITION_MODEL_FILENAME + " is not loaded. Please read “StreamingAssets/OpenCVForUnity/dnn/setup_dnn_module.pdf” to make the necessary setup."); + } + else + { + facialExpressionRecognizer = new MFacialExpressionRecognizer(facial_expression_recognition_model_filepath, face_recognition_model_filepath, ""); + } + + + if (string.IsNullOrEmpty(testInputImage)) + { +#if UNITY_ANDROID && !UNITY_EDITOR + // Avoids the front camera low light issue that occurs in only some Android devices (e.g. Google Pixel, Pixel2). + usbCamTextureToMatHelper.avoidAndroidFrontCameraLowLightIssue = true; +#endif + usbCamTextureToMatHelper.Initialize(); + } + else + { + ///////////////////// + // TEST + + var getFilePathAsync_0_Coroutine = Utils.getFilePathAsync("OpenCVForUnity/dnn/" + testInputImage, (result) => + { + string test_input_image_filepath = result; + if (string.IsNullOrEmpty(test_input_image_filepath)) Debug.Log("The file:" + testInputImage + " did not exist in the folder “Assets/StreamingAssets/OpenCVForUnity/dnn”."); + + Mat img = Imgcodecs.imread(test_input_image_filepath); + if (img.empty()) + { + img = new Mat(424, 640, CvType.CV_8UC3, new Scalar(0, 0, 0)); + Imgproc.putText(img, testInputImage + " is not loaded.", new Point(5, img.rows() - 30), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + Imgproc.putText(img, "Please read console message.", new Point(5, img.rows() - 10), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + } + else + { + TickMeter tm = new TickMeter(); + tm.start(); + + Mat faces = faceDetector.infer(img); + + tm.stop(); + Debug.Log("YuNetFaceDetector Inference time, ms: " + tm.getTimeMilli()); + + List expressions = new List(); + + // Estimate the expression of each face + for (int i = 0; i < faces.rows(); ++i) + { + tm.reset(); + tm.start(); + + // Facial expression recognizer inference + Mat facialExpression = facialExpressionRecognizer.infer(img, faces.row(i)); + + tm.stop(); + Debug.Log("FacialExpressionRecognizer Inference time (preprocess + infer + postprocess), ms: " + tm.getTimeMilli()); + + if (!facialExpression.empty()) + expressions.Add(facialExpression); + } + faceDetector.visualize(img, faces, true, false); + facialExpressionRecognizer.visualize(img, expressions, faces, true, false); + } + + gameObject.transform.localScale = new Vector3(img.width(), img.height(), 1); + float imageWidth = img.width(); + float imageHeight = img.height(); + float widthScale = (float)Screen.width / imageWidth; + float heightScale = (float)Screen.height / imageHeight; + if (widthScale < heightScale) + { + Camera.main.orthographicSize = (imageWidth * (float)Screen.height / (float)Screen.width) / 2; + } + else + { + Camera.main.orthographicSize = imageHeight / 2; + } + + Imgproc.cvtColor(img, img, Imgproc.COLOR_BGR2RGB); + Texture2D texture = new Texture2D(img.cols(), img.rows(), TextureFormat.RGB24, false); + Utils.matToTexture2D(img, texture); + gameObject.GetComponent().material.mainTexture = texture; + + }); + StartCoroutine(getFilePathAsync_0_Coroutine); + + ///////////////////// + } + } + + /// + /// Raises the webcam texture to mat helper initialized event. + /// + public void OnWebCamTextureToMatHelperInitialized() + { + Debug.Log("OnWebCamTextureToMatHelperInitialized"); + + Mat webCamTextureMat = usbCamTextureToMatHelper.GetMat(); + + texture = new Texture2D(webCamTextureMat.cols(), webCamTextureMat.rows(), TextureFormat.RGBA32, false); + Utils.matToTexture2D(webCamTextureMat, texture); + + gameObject.GetComponent().material.mainTexture = texture; + + gameObject.transform.localScale = new Vector3(webCamTextureMat.cols(), webCamTextureMat.rows(), 1); + Debug.Log("Screen.width " + Screen.width + " Screen.height " + Screen.height + " Screen.orientation " + Screen.orientation); + + if (fpsMonitor != null) + { + fpsMonitor.Add("width", webCamTextureMat.width().ToString()); + fpsMonitor.Add("height", webCamTextureMat.height().ToString()); + fpsMonitor.Add("orientation", Screen.orientation.ToString()); + } + + + float width = webCamTextureMat.width(); + float height = webCamTextureMat.height(); + + float widthScale = (float)Screen.width / width; + float heightScale = (float)Screen.height / height; + if (widthScale < heightScale) + { + Camera.main.orthographicSize = (width * (float)Screen.height / (float)Screen.width) / 2; + } + else + { + Camera.main.orthographicSize = height / 2; + } + + bgrMat = new Mat(webCamTextureMat.rows(), webCamTextureMat.cols(), CvType.CV_8UC3); + } + + /// + /// Raises the webcam texture to mat helper disposed event. + /// + public void OnWebCamTextureToMatHelperDisposed() + { + Debug.Log("OnWebCamTextureToMatHelperDisposed"); + + if (bgrMat != null) + bgrMat.Dispose(); + + if (texture != null) + { + Texture2D.Destroy(texture); + texture = null; + } + } + + /// + /// Raises the webcam texture to mat helper error occurred event. + /// + /// Error code. + public void OnWebCamTextureToMatHelperErrorOccurred(WebCamTextureToMatHelper.ErrorCode errorCode) + { + Debug.Log("OnWebCamTextureToMatHelperErrorOccurred " + errorCode); + } + + // Update is called once per frame + void Update() + { + + if (usbCamTextureToMatHelper.IsPlaying() && usbCamTextureToMatHelper.DidUpdateThisFrame()) + { + + Mat rgbaMat = usbCamTextureToMatHelper.GetMat(); + + if (faceDetector == null || facialExpressionRecognizer == null) + { + Imgproc.putText(rgbaMat, "model file is not loaded.", new Point(5, rgbaMat.rows() - 30), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + Imgproc.putText(rgbaMat, "Please read console message.", new Point(5, rgbaMat.rows() - 10), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + } + else + { + Imgproc.cvtColor(rgbaMat, bgrMat, Imgproc.COLOR_RGBA2BGR); + + //TickMeter tm = new TickMeter(); + //tm.start(); + + Mat faces = faceDetector.infer(bgrMat); + + //tm.stop(); + //Debug.Log("YuNetFaceDetector Inference time, ms: " + tm.getTimeMilli()); + + List expressions = new List(); + + // Estimate the expression of each face + for (int i = 0; i < faces.rows(); ++i) + { + //tm.reset(); + //tm.start(); + + // Facial expression recognizer inference + Mat facialExpression = facialExpressionRecognizer.infer(bgrMat, faces.row(i)); + + //tm.stop(); + //Debug.Log("FacialExpressionRecognizer Inference time (preprocess + infer + postprocess), ms: " + tm.getTimeMilli()); + + if (!facialExpression.empty()) + expressions.Add(facialExpression); + } + + Imgproc.cvtColor(bgrMat, rgbaMat, Imgproc.COLOR_BGR2RGBA); + + //faceDetector.visualize(rgbaMat, faces, false, true); + FaceInfo[] infos = facialExpressionRecognizer.visualize(rgbaMat, expressions, faces, true); + if (onReconizedFaces != null) + onReconizedFaces(infos); + } + + Utils.matToTexture2D(rgbaMat, texture); + } + + } + + + /// + /// Raises the destroy event. + /// + void OnDestroy() + { + usbCamTextureToMatHelper.Dispose(); + + if (faceDetector != null) + faceDetector.dispose(); + + if (facialExpressionRecognizer != null) + facialExpressionRecognizer.dispose(); + + Utils.setDebugMode(false); + +#if UNITY_WEBGL + if (getFilePath_Coroutine != null) + { + StopCoroutine(getFilePath_Coroutine); + ((IDisposable)getFilePath_Coroutine).Dispose(); + } +#endif + } + + /// + /// Raises the back button click event. + /// + public void OnBackButtonClick() + { + SceneManager.LoadScene("OpenCVForUnityExample"); + } + + /// + /// Raises the play button click event. + /// + public void OnPlayButtonClick() + { + usbCamTextureToMatHelper.Play(); + } + + /// + /// Raises the pause button click event. + /// + public void OnPauseButtonClick() + { + usbCamTextureToMatHelper.Pause(); + } + + /// + /// Raises the stop button click event. + /// + public void OnStopButtonClick() + { + usbCamTextureToMatHelper.Stop(); + } + + /// + /// Raises the change camera button click event. + /// + public void OnChangeCameraButtonClick() + { + usbCamTextureToMatHelper.requestedIsFrontFacing = !usbCamTextureToMatHelper.requestedIsFrontFacing; + } + + public FaceInfo[] GetFaceInfos() + { + throw new NotImplementedException(); + } + + public void BindListener(Action onRecognizedHandler) + { + onReconizedFaces += onRecognizedHandler; + } + + public void RemoveListener(Action onRecognizedHandler) + { + onReconizedFaces -= onRecognizedHandler; + } + } +} + +#endif \ No newline at end of file diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/FacialExpressionRecognition_UVC.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/FacialExpressionRecognition_UVC.cs.meta new file mode 100644 index 0000000..a53e809 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/FacialExpressionRecognition_UVC.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a07b9addfb2161e4b8fbdc35b3ed9531 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/IFaceRecognizer.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/IFaceRecognizer.cs new file mode 100644 index 0000000..93bd21c --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/IFaceRecognizer.cs @@ -0,0 +1,10 @@ +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; + +public interface IFaceRecognizer +{ + void BindListener(Action onRecognizedHandler); + void RemoveListener(Action onRecognizedHandler); +} diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/IFaceRecognizer.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/IFaceRecognizer.cs.meta new file mode 100644 index 0000000..ca7f052 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/IFaceRecognizer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a7b970a0e0890864ebc966baf1686d13 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognition.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognition.cs new file mode 100644 index 0000000..b1f5456 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognition.cs @@ -0,0 +1,458 @@ +#if !UNITY_WSA_10_0 + +using OpenCVForUnity.CoreModule; +using OpenCVForUnity.ImgcodecsModule; +using OpenCVForUnity.ImgprocModule; +using OpenCVForUnity.UnityUtils; +using OpenCVForUnity.UnityUtils.Helper; +using OpenCVForUnityExample.DnnModel; +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.SceneManagement; + +namespace OpenCVForUnityExample +{ + /// + /// Facial Expression Recognition Example + /// An example of using OpenCV dnn module with Facial Expression Recognition. + /// Referring to https://github.com/opencv/opencv_zoo/tree/master/models/facial_expression_recognition + /// + [RequireComponent(typeof(WebCamTextureToMatHelper))] + public class MFacialExpressionRecognition : MonoBehaviour,IFaceRecognizer + { + [Header("TEST")] + + [TooltipAttribute("Path to test input image.")] + public string testInputImage; + + /// + /// The texture. + /// + Texture2D texture; + + /// + /// The webcam texture to mat helper. + /// + WebCamTextureToMatHelper webCamTextureToMatHelper; + + /// + /// The bgr mat. + /// + Mat bgrMat; + + /// + /// The facial expression recognizer. + /// + MFacialExpressionRecognizer facialExpressionRecognizer; + + /// + /// The FPS monitor. + /// + FpsMonitor fpsMonitor; + + /// + /// FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME + /// + protected static readonly string FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME = "OpenCVForUnity/dnn/facial_expression_recognition_mobilefacenet_2022july.onnx"; + + /// + /// The facial expression recognition model filepath. + /// + string facial_expression_recognition_model_filepath; + + /// + /// FACE_RECOGNITION_MODEL_FILENAME + /// + protected static readonly string FACE_RECOGNITION_MODEL_FILENAME = "OpenCVForUnity/dnn/face_recognition_sface_2021dec.onnx"; + + /// + /// The face recognition model filepath. + /// + string face_recognition_model_filepath; + + + /// + /// The YuNetV2FaceDetector. + /// + YuNetV2FaceDetector faceDetector; + + int inputSizeW = 320; + int inputSizeH = 320; + float scoreThreshold = 0.9f; + float nmsThreshold = 0.3f; + int topK = 5000; + + /// + /// FACE_DETECTION_MODEL_FILENAME + /// + protected static readonly string FACE_DETECTION_MODEL_FILENAME = "OpenCVForUnity/dnn/face_detection_yunet_2023mar.onnx"; + + /// + /// The face detection model filepath. + /// + string face_detection_model_filepath; + + event Action onReconizedFaces; + +#if UNITY_WEBGL + IEnumerator getFilePath_Coroutine; +#endif + + // Use this for initialization + void Start() + { + fpsMonitor = GetComponent(); + + webCamTextureToMatHelper = gameObject.GetComponent(); + +#if UNITY_WEBGL + getFilePath_Coroutine = GetFilePath(); + StartCoroutine(getFilePath_Coroutine); +#else + face_detection_model_filepath = Utils.getFilePath(FACE_DETECTION_MODEL_FILENAME); + facial_expression_recognition_model_filepath = Utils.getFilePath(FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME); + face_recognition_model_filepath = Utils.getFilePath(FACE_RECOGNITION_MODEL_FILENAME); + Run(); +#endif + } + +#if UNITY_WEBGL + private IEnumerator GetFilePath() + { + var getFilePathAsync_0_Coroutine = Utils.getFilePathAsync(FACE_DETECTION_MODEL_FILENAME, (result) => + { + face_detection_model_filepath = result; + }); + yield return getFilePathAsync_0_Coroutine; + + var getFilePathAsync_1_Coroutine = Utils.getFilePathAsync(FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME, (result) => + { + facial_expression_recognition_model_filepath = result; + }); + yield return getFilePathAsync_1_Coroutine; + + var getFilePathAsync_2_Coroutine = Utils.getFilePathAsync(FACE_RECOGNITION_MODEL_FILENAME, (result) => + { + face_recognition_model_filepath = result; + }); + yield return getFilePathAsync_2_Coroutine; + + getFilePath_Coroutine = null; + + Run(); + } +#endif + + // Use this for initialization + void Run() + { + //if true, The error log of the Native side OpenCV will be displayed on the Unity Editor Console. + Utils.setDebugMode(true); + + + if (string.IsNullOrEmpty(face_detection_model_filepath)) + { + Debug.LogError(FACE_DETECTION_MODEL_FILENAME + " is not loaded. Please read “StreamingAssets/OpenCVForUnity/dnn/setup_dnn_module.pdf” to make the necessary setup."); + } + else + { + faceDetector = new YuNetV2FaceDetector(face_detection_model_filepath, "", new Size(inputSizeW, inputSizeH), scoreThreshold, nmsThreshold, topK); + } + + if (string.IsNullOrEmpty(facial_expression_recognition_model_filepath) || string.IsNullOrEmpty(face_recognition_model_filepath)) + { + Debug.LogError(FACIAL_EXPRESSION_RECOGNITION_MODEL_FILENAME + " or " + FACE_RECOGNITION_MODEL_FILENAME + " is not loaded. Please read “StreamingAssets/OpenCVForUnity/dnn/setup_dnn_module.pdf” to make the necessary setup."); + } + else + { + facialExpressionRecognizer = new MFacialExpressionRecognizer(facial_expression_recognition_model_filepath, face_recognition_model_filepath, ""); + } + + + if (string.IsNullOrEmpty(testInputImage)) + { +#if UNITY_ANDROID && !UNITY_EDITOR + // Avoids the front camera low light issue that occurs in only some Android devices (e.g. Google Pixel, Pixel2). + webCamTextureToMatHelper.avoidAndroidFrontCameraLowLightIssue = true; +#endif + webCamTextureToMatHelper.Initialize(); + } + else + { + ///////////////////// + // TEST + + var getFilePathAsync_0_Coroutine = Utils.getFilePathAsync("OpenCVForUnity/dnn/" + testInputImage, (result) => + { + string test_input_image_filepath = result; + if (string.IsNullOrEmpty(test_input_image_filepath)) Debug.Log("The file:" + testInputImage + " did not exist in the folder “Assets/StreamingAssets/OpenCVForUnity/dnn”."); + + Mat img = Imgcodecs.imread(test_input_image_filepath); + if (img.empty()) + { + img = new Mat(424, 640, CvType.CV_8UC3, new Scalar(0, 0, 0)); + Imgproc.putText(img, testInputImage + " is not loaded.", new Point(5, img.rows() - 30), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + Imgproc.putText(img, "Please read console message.", new Point(5, img.rows() - 10), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + } + else + { + TickMeter tm = new TickMeter(); + tm.start(); + + Mat faces = faceDetector.infer(img); + + tm.stop(); + Debug.Log("YuNetFaceDetector Inference time, ms: " + tm.getTimeMilli()); + + List expressions = new List(); + + // Estimate the expression of each face + for (int i = 0; i < faces.rows(); ++i) + { + tm.reset(); + tm.start(); + + // Facial expression recognizer inference + Mat facialExpression = facialExpressionRecognizer.infer(img, faces.row(i)); + + tm.stop(); + Debug.Log("FacialExpressionRecognizer Inference time (preprocess + infer + postprocess), ms: " + tm.getTimeMilli()); + + if (!facialExpression.empty()) + expressions.Add(facialExpression); + } + faceDetector.visualize(img, faces, true, false); + facialExpressionRecognizer.visualize(img, expressions, faces, true, false); + } + + gameObject.transform.localScale = new Vector3(img.width(), img.height(), 1); + float imageWidth = img.width(); + float imageHeight = img.height(); + float widthScale = (float)Screen.width / imageWidth; + float heightScale = (float)Screen.height / imageHeight; + if (widthScale < heightScale) + { + Camera.main.orthographicSize = (imageWidth * (float)Screen.height / (float)Screen.width) / 2; + } + else + { + Camera.main.orthographicSize = imageHeight / 2; + } + + Imgproc.cvtColor(img, img, Imgproc.COLOR_BGR2RGB); + Texture2D texture = new Texture2D(img.cols(), img.rows(), TextureFormat.RGB24, false); + Utils.matToTexture2D(img, texture); + gameObject.GetComponent().material.mainTexture = texture; + + }); + StartCoroutine(getFilePathAsync_0_Coroutine); + + ///////////////////// + } + } + + /// + /// Raises the webcam texture to mat helper initialized event. + /// + public void OnWebCamTextureToMatHelperInitialized() + { + Debug.Log("OnWebCamTextureToMatHelperInitialized"); + + Mat webCamTextureMat = webCamTextureToMatHelper.GetMat(); + + texture = new Texture2D(webCamTextureMat.cols(), webCamTextureMat.rows(), TextureFormat.RGBA32, false); + Utils.matToTexture2D(webCamTextureMat, texture); + + gameObject.GetComponent().material.mainTexture = texture; + + gameObject.transform.localScale = new Vector3(webCamTextureMat.cols(), webCamTextureMat.rows(), 1); + Debug.Log("Screen.width " + Screen.width + " Screen.height " + Screen.height + " Screen.orientation " + Screen.orientation); + + if (fpsMonitor != null) + { + fpsMonitor.Add("width", webCamTextureMat.width().ToString()); + fpsMonitor.Add("height", webCamTextureMat.height().ToString()); + fpsMonitor.Add("orientation", Screen.orientation.ToString()); + } + + + float width = webCamTextureMat.width(); + float height = webCamTextureMat.height(); + + float widthScale = (float)Screen.width / width; + float heightScale = (float)Screen.height / height; + if (widthScale < heightScale) + { + Camera.main.orthographicSize = (width * (float)Screen.height / (float)Screen.width) / 2; + } + else + { + Camera.main.orthographicSize = height / 2; + } + + bgrMat = new Mat(webCamTextureMat.rows(), webCamTextureMat.cols(), CvType.CV_8UC3); + } + + /// + /// Raises the webcam texture to mat helper disposed event. + /// + public void OnWebCamTextureToMatHelperDisposed() + { + Debug.Log("OnWebCamTextureToMatHelperDisposed"); + + if (bgrMat != null) + bgrMat.Dispose(); + + if (texture != null) + { + Texture2D.Destroy(texture); + texture = null; + } + } + + /// + /// Raises the webcam texture to mat helper error occurred event. + /// + /// Error code. + public void OnWebCamTextureToMatHelperErrorOccurred(WebCamTextureToMatHelper.ErrorCode errorCode) + { + Debug.Log("OnWebCamTextureToMatHelperErrorOccurred " + errorCode); + } + + // Update is called once per frame + void Update() + { + + if (webCamTextureToMatHelper.IsPlaying() && webCamTextureToMatHelper.DidUpdateThisFrame()) + { + + Mat rgbaMat = webCamTextureToMatHelper.GetMat(); + + if (faceDetector == null || facialExpressionRecognizer == null) + { + Imgproc.putText(rgbaMat, "model file is not loaded.", new Point(5, rgbaMat.rows() - 30), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + Imgproc.putText(rgbaMat, "Please read console message.", new Point(5, rgbaMat.rows() - 10), Imgproc.FONT_HERSHEY_SIMPLEX, 0.7, new Scalar(255, 255, 255, 255), 2, Imgproc.LINE_AA, false); + } + else + { + Imgproc.cvtColor(rgbaMat, bgrMat, Imgproc.COLOR_RGBA2BGR); + + //TickMeter tm = new TickMeter(); + //tm.start(); + + Mat faces = faceDetector.infer(bgrMat); + + //tm.stop(); + //Debug.Log("YuNetFaceDetector Inference time, ms: " + tm.getTimeMilli()); + + List expressions = new List(); + + // Estimate the expression of each face + for (int i = 0; i < faces.rows(); ++i) + { + //tm.reset(); + //tm.start(); + + // Facial expression recognizer inference + Mat facialExpression = facialExpressionRecognizer.infer(bgrMat, faces.row(i)); + + //tm.stop(); + //Debug.Log("FacialExpressionRecognizer Inference time (preprocess + infer + postprocess), ms: " + tm.getTimeMilli()); + + if (!facialExpression.empty()) + expressions.Add(facialExpression); + } + + Imgproc.cvtColor(bgrMat, rgbaMat, Imgproc.COLOR_BGR2RGBA); + + //faceDetector.visualize(rgbaMat, faces, false, true); + FaceInfo[] infos = facialExpressionRecognizer.visualize(rgbaMat, expressions, faces, true); + if (onReconizedFaces != null) + onReconizedFaces(infos); + } + + Utils.matToTexture2D(rgbaMat, texture); + } + + } + + + /// + /// Raises the destroy event. + /// + void OnDestroy() + { + webCamTextureToMatHelper.Dispose(); + + if (faceDetector != null) + faceDetector.dispose(); + + if (facialExpressionRecognizer != null) + facialExpressionRecognizer.dispose(); + + Utils.setDebugMode(false); + +#if UNITY_WEBGL + if (getFilePath_Coroutine != null) + { + StopCoroutine(getFilePath_Coroutine); + ((IDisposable)getFilePath_Coroutine).Dispose(); + } +#endif + } + + /// + /// Raises the back button click event. + /// + public void OnBackButtonClick() + { + SceneManager.LoadScene("OpenCVForUnityExample"); + } + + /// + /// Raises the play button click event. + /// + public void OnPlayButtonClick() + { + webCamTextureToMatHelper.Play(); + } + + /// + /// Raises the pause button click event. + /// + public void OnPauseButtonClick() + { + webCamTextureToMatHelper.Pause(); + } + + /// + /// Raises the stop button click event. + /// + public void OnStopButtonClick() + { + webCamTextureToMatHelper.Stop(); + } + + /// + /// Raises the change camera button click event. + /// + public void OnChangeCameraButtonClick() + { + webCamTextureToMatHelper.requestedIsFrontFacing = !webCamTextureToMatHelper.requestedIsFrontFacing; + } + + public void BindListener(Action onRecognizedHandler) + { + onReconizedFaces += onRecognizedHandler; + } + + public void RemoveListener(Action onRecognizedHandler) + { + onReconizedFaces -= onRecognizedHandler; + } + } +} + +#endif \ No newline at end of file diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognition.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognition.cs.meta new file mode 100644 index 0000000..2856c04 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognition.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 956d8fd069f661f4aa9eb1055d305572 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognizer.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognizer.cs new file mode 100644 index 0000000..efb83f6 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognizer.cs @@ -0,0 +1,127 @@ + +using OpenCVForUnity.CoreModule; +using OpenCVForUnity.DnnModule; +using OpenCVForUnity.ImgprocModule; +using OpenCVForUnity.ObjdetectModule; +using OpenCVForUnityExample.DnnModel; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Runtime.InteropServices; +using System.Text; +using UnityEngine; + +public class MFacialExpressionRecognizer : FacialExpressionRecognizer +{ + + List mPalette = new List(); + public MFacialExpressionRecognizer(string modelFilepath, string SF_modelFilepath, string SF_configFilepath, int backend = Dnn.DNN_BACKEND_OPENCV, int target = Dnn.DNN_TARGET_CPU):base(modelFilepath,SF_modelFilepath,SF_configFilepath,backend,target) + { + mPalette = new List(); + mPalette.Add(new Scalar(255, 56, 56, 255)); + mPalette.Add(new Scalar(82, 0, 133, 255)); + mPalette.Add(new Scalar(52, 69, 147, 255)); + mPalette.Add(new Scalar(255, 178, 29, 255)); + mPalette.Add(new Scalar(55, 55, 55, 255)); + mPalette.Add(new Scalar(100, 115, 255, 255)); + mPalette.Add(new Scalar(255, 112, 31, 255)); + } + + public FaceInfo[] visualize(Mat image, List results, Mat faces, bool isRGB = false) + { + if (image.IsDisposed) + return new FaceInfo[0]; + + if (results.Count != faces.rows()) + return new FaceInfo[0]; + + StringBuilder sb = null; + + //if (print_results) + // sb = new StringBuilder(); + + FaceInfo[] faceInfos = new FaceInfo[results.Count]; + + for (int i = 0; i < results.Count; ++i) + { + float[] face_box = new float[4]; + faces.get(i, 0, face_box); + + float left = face_box[0] + 2; + float top = face_box[1] + 2; + float right = face_box[0] + face_box[2] - 2; + float bottom = face_box[1] + face_box[3] - 2; + + ClassificationData bmData = getBestMatchData(results[i]); + int classId = (int)bmData.cls; + string label = getClassLabel(bmData.cls) + ", " + String.Format("{0:0.0000}", bmData.conf); + + Scalar c = mPalette[classId % mPalette.Count]; + Scalar color = isRGB ? c : new Scalar(c.val[2], c.val[1], c.val[0], c.val[3]); + + // draw box + Imgproc.rectangle(image, new Point(left, top), new Point(right, bottom), color, 2); + + // draw label + int[] baseLine = new int[1]; + Size labelSize = Imgproc.getTextSize(label, Imgproc.FONT_HERSHEY_SIMPLEX, 0.5, 1, baseLine); + + top = Mathf.Max((float)top, (float)labelSize.height); + Imgproc.rectangle(image, new Point(left, top + 2), + new Point(left + labelSize.width, top + labelSize.height + baseLine[0] + 2), color, Core.FILLED); + Imgproc.putText(image, label, new Point(left, top + labelSize.height + 2), Imgproc.FONT_HERSHEY_SIMPLEX, 0.5, Scalar.all(255), 1, Imgproc.LINE_AA); + + FaceInfo info = new FaceInfo(); + info.expression = getClassExp(bmData.cls); + info.confidence = bmData.conf; + info.box = new UnityEngine.Rect(left, bottom, right - left, top - bottom); + faceInfos[i] = info; + // Print results + //if (print_results) + //{ + // sb.AppendLine(String.Format("-----------expression {0}-----------", i + 1)); + //sb.AppendLine(String.Format("Best match: " + getClassLabel(bmData.cls) + ", " + bmData)); + //} + } + //if (print_results) + // Debug.Log(sb); + + return faceInfos; + } + public FaceInfo.Expression getClassExp(float id) + { + /* + * ("angry"); + ("disgust"); + ("fearful"); + ("happy"); + ("neutral"); + ("sad"); + ("surprised"); + * */ + int index = (int)id; + if(index >= 0) + { + switch (index) + { + case 0: + return FaceInfo.Expression.Angry; + case 1: + return FaceInfo.Expression.Disgust; + case 2: + return FaceInfo.Expression.Fearful; + case 3: + return FaceInfo.Expression.Happy; + case 4: + return FaceInfo.Expression.Neutral; + case 5: + return FaceInfo.Expression.Sad; + case 6: + return FaceInfo.Expression.Suprised; + default: + return FaceInfo.Expression.Neutral; + } + } + return FaceInfo.Expression.Neutral; + } +} diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognizer.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognizer.cs.meta new file mode 100644 index 0000000..f8512e9 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/MFacialExpressionRecognizer.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 847d49fa864db24469ce713456829df2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCCameraToMatHelper.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCCameraToMatHelper.cs new file mode 100644 index 0000000..1016ea1 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCCameraToMatHelper.cs @@ -0,0 +1,1140 @@ +#if !OPENCV_DONT_USE_WEBCAMTEXTURE_API +#if !(PLATFORM_LUMIN && !UNITY_EDITOR) + +using OpenCVForUnity.CoreModule; +using OpenCVForUnity.ImgprocModule; +using OpenCVForUnity.UtilsModule; +using System; +using System.Collections; +using UnityEngine; +using UnityEngine.Events; +using UnityEngine.Serialization; +namespace OpenCVForUnity.UnityUtils.Helper +{ + public class UVCCameraToMatHelper : MonoBehaviour + {/// + /// Set the name of the camera device to use. (or device index number) + /// + [SerializeField, FormerlySerializedAs("requestedDeviceName"), TooltipAttribute("Set the name of the device to use. (or device index number)")] + protected string _requestedDeviceName = null; + public virtual string requestedDeviceName + { + get { return _requestedDeviceName; } + set + { + if (_requestedDeviceName != value) + { + _requestedDeviceName = value; + if (hasInitDone) + Initialize(); + } + } + } + + /// + /// Set the width of camera. + /// + [SerializeField, FormerlySerializedAs("requestedWidth"), TooltipAttribute("Set the width of camera.")] + protected int _requestedWidth = 640; + + public virtual int requestedWidth + { + get { return _requestedWidth; } + set + { + int _value = (int)Mathf.Clamp(value, 0f, float.MaxValue); + if (_requestedWidth != _value) + { + _requestedWidth = _value; + if (hasInitDone) + Initialize(); + } + } + } + + /// + /// Set the height of camera. + /// + [SerializeField, FormerlySerializedAs("requestedHeight"), TooltipAttribute("Set the height of camera.")] + protected int _requestedHeight = 480; + + public virtual int requestedHeight + { + get { return _requestedHeight; } + set + { + int _value = (int)Mathf.Clamp(value, 0f, float.MaxValue); + if (_requestedHeight != _value) + { + _requestedHeight = _value; + if (hasInitDone) + Initialize(); + } + } + } + + /// + /// Set whether to use the front facing camera. + /// + [SerializeField, FormerlySerializedAs("requestedIsFrontFacing"), TooltipAttribute("Set whether to use the front facing camera.")] + protected bool _requestedIsFrontFacing = false; + + public virtual bool requestedIsFrontFacing + { + get { return _requestedIsFrontFacing; } + set + { + if (_requestedIsFrontFacing != value) + { + _requestedIsFrontFacing = value; + if (hasInitDone) + Initialize(_requestedIsFrontFacing, requestedFPS, rotate90Degree); + } + } + } + + /// + /// Set the frame rate of camera. + /// + [SerializeField, FormerlySerializedAs("requestedFPS"), TooltipAttribute("Set the frame rate of camera.")] + protected float _requestedFPS = 30f; + + public virtual float requestedFPS + { + get { return _requestedFPS; } + set + { + float _value = Mathf.Clamp(value, -1f, float.MaxValue); + if (_requestedFPS != _value) + { + _requestedFPS = _value; + if (hasInitDone) + { + bool isPlaying = IsPlaying(); + Stop(); + uvcTexture.requestedFPS = _requestedFPS; + if (isPlaying) + Play(); + } + } + } + } + + /// + /// Sets whether to rotate camera frame 90 degrees. (clockwise) + /// + [SerializeField, FormerlySerializedAs("rotate90Degree"), TooltipAttribute("Sets whether to rotate camera frame 90 degrees. (clockwise)")] + protected bool _rotate90Degree = false; + + public virtual bool rotate90Degree + { + get { return _rotate90Degree; } + set + { + if (_rotate90Degree != value) + { + _rotate90Degree = value; + if (hasInitDone) + Initialize(); + } + } + } + + /// + /// Determines if flips vertically. + /// + [SerializeField, FormerlySerializedAs("flipVertical"), TooltipAttribute("Determines if flips vertically.")] + protected bool _flipVertical = false; + + public virtual bool flipVertical + { + get { return _flipVertical; } + set { _flipVertical = value; } + } + + /// + /// Determines if flips horizontal. + /// + [SerializeField, FormerlySerializedAs("flipHorizontal"), TooltipAttribute("Determines if flips horizontal.")] + protected bool _flipHorizontal = false; + + public virtual bool flipHorizontal + { + get { return _flipHorizontal; } + set { _flipHorizontal = value; } + } + + /// + /// Select the output color format. + /// + [SerializeField, FormerlySerializedAs("outputColorFormat"), TooltipAttribute("Select the output color format.")] + protected ColorFormat _outputColorFormat = ColorFormat.RGBA; + + public virtual ColorFormat outputColorFormat + { + get { return _outputColorFormat; } + set + { + if (_outputColorFormat != value) + { + _outputColorFormat = value; + if (hasInitDone) + Initialize(); + } + } + } + + /// + /// The number of frames before the initialization process times out. + /// + [SerializeField, FormerlySerializedAs("timeoutFrameCount"), TooltipAttribute("The number of frames before the initialization process times out.")] + protected int _timeoutFrameCount = 300; + + public virtual int timeoutFrameCount + { + get { return _timeoutFrameCount; } + set { _timeoutFrameCount = (int)Mathf.Clamp(value, 0f, float.MaxValue); } + } + + /// + /// UnityEvent that is triggered when this instance is initialized. + /// + public UnityEvent onInitialized; + + /// + /// UnityEvent that is triggered when this instance is disposed. + /// + public UnityEvent onDisposed; + + /// + /// UnityEvent that is triggered when this instance is error Occurred. + /// + public ErrorUnityEvent onErrorOccurred; + + /// + /// The active uvc camera Texture. + /// + public UVCTexture uvcTexture; + + /// + /// The frame mat. + /// + protected Mat frameMat; + + /// + /// The base mat. + /// + protected Mat baseMat; + + /// + /// The rotated frame mat + /// + protected Mat rotatedFrameMat; + + /// + /// The buffer colors. + /// + protected Color32[] colors; + + /// + /// The base color format. + /// + protected ColorFormat baseColorFormat = ColorFormat.RGBA; + + /// + /// Indicates whether this instance is waiting for initialization to complete. + /// + protected bool isInitWaiting = false; + + /// + /// Indicates whether this instance has been initialized. + /// + protected bool hasInitDone = false; + + /// + /// The initialization coroutine. + /// + protected IEnumerator initCoroutine; + + /// + /// The orientation of the screen. + /// + protected ScreenOrientation screenOrientation; + + /// + /// The width of the screen. + /// + protected int screenWidth; + + /// + /// The height of the screen. + /// + protected int screenHeight; + + /// + /// Indicates whether this instance avoids the front camera low light issue that occurs in only some Android devices (e.g. Google Pixel, Pixel2). + /// Sets compulsorily the requestedFPS parameter to 15 (only when using the front camera), to avoid the problem of the WebCamTexture image becoming low light. + /// https://forum.unity.com/threads/android-webcamtexture-in-low-light-only-some-models.520656/ + /// https://forum.unity.com/threads/released-opencv-for-unity.277080/page-33#post-3445178 + /// + public bool avoidAndroidFrontCameraLowLightIssue = false; + + public enum ColorFormat : int + { + GRAY = 0, + RGB, + BGR, + RGBA, + BGRA, + } + + public enum ErrorCode : int + { + UNKNOWN = 0, + CAMERA_DEVICE_NOT_EXIST, + CAMERA_PERMISSION_DENIED, + TIMEOUT, + } + + [Serializable] + public class ErrorUnityEvent : UnityEvent + { + + } + + protected virtual void OnValidate() + { + _requestedWidth = (int)Mathf.Clamp(_requestedWidth, 0f, float.MaxValue); + _requestedHeight = (int)Mathf.Clamp(_requestedHeight, 0f, float.MaxValue); + _requestedFPS = Mathf.Clamp(_requestedFPS, -1f, float.MaxValue); + _timeoutFrameCount = (int)Mathf.Clamp(_timeoutFrameCount, 0f, float.MaxValue); + } + +#if !UNITY_EDITOR && !UNITY_ANDROID + protected bool isScreenSizeChangeWaiting = false; +#endif + + // Update is called once per frame + protected virtual void Update() + { + if (hasInitDone) + { + // Catch the orientation change of the screen and correct the mat image to the correct direction. + if (screenOrientation != Screen.orientation) + { + +#if !UNITY_EDITOR && !UNITY_ANDROID + // Wait one frame until the Screen.width/Screen.height property changes. + if (!isScreenSizeChangeWaiting) + { + isScreenSizeChangeWaiting = true; + return; + } + isScreenSizeChangeWaiting = false; +#endif + + if (onDisposed != null) + onDisposed.Invoke(); + + if (frameMat != null) + { + frameMat.Dispose(); + frameMat = null; + } + if (baseMat != null) + { + baseMat.Dispose(); + baseMat = null; + } + if (rotatedFrameMat != null) + { + rotatedFrameMat.Dispose(); + rotatedFrameMat = null; + } + + baseMat = new Mat(uvcTexture.height, uvcTexture.width, CvType.CV_8UC4, new Scalar(0, 0, 0, 255)); + + if (baseColorFormat == outputColorFormat) + { + frameMat = baseMat; + } + else + { + frameMat = new Mat(baseMat.rows(), baseMat.cols(), CvType.CV_8UC(Channels(outputColorFormat)), new Scalar(0, 0, 0, 255)); + } + + screenOrientation = Screen.orientation; + screenWidth = Screen.width; + screenHeight = Screen.height; + + bool isRotatedFrame = false; +#if !UNITY_EDITOR && !(UNITY_STANDALONE || UNITY_WEBGL) + if (screenOrientation == ScreenOrientation.Portrait || screenOrientation == ScreenOrientation.PortraitUpsideDown) + { + if (!rotate90Degree) + isRotatedFrame = true; + } + else if (rotate90Degree) + { + isRotatedFrame = true; + } +#else + if (rotate90Degree) + isRotatedFrame = true; +#endif + if (isRotatedFrame) + rotatedFrameMat = new Mat(frameMat.cols(), frameMat.rows(), CvType.CV_8UC(Channels(outputColorFormat)), new Scalar(0, 0, 0, 255)); + + if (onInitialized != null) + onInitialized.Invoke(); + } + } + } + + protected virtual IEnumerator OnApplicationFocus(bool hasFocus) + { +#if ((UNITY_IOS || UNITY_WEBGL) && UNITY_2018_1_OR_NEWER) || (UNITY_ANDROID && UNITY_2018_3_OR_NEWER) + yield return null; + + if (isUserRequestingPermission && hasFocus) + isUserRequestingPermission = false; +#endif + yield break; + } + + /// + /// Raises the destroy event. + /// + protected virtual void OnDestroy() + { + Dispose(); + } + + /// + /// Initializes this instance. + /// + public virtual void Initialize() + { + if (isInitWaiting) + { + CancelInitCoroutine(); + ReleaseResources(); + } + + if (onInitialized == null) + onInitialized = new UnityEvent(); + if (onDisposed == null) + onDisposed = new UnityEvent(); + if (onErrorOccurred == null) + onErrorOccurred = new ErrorUnityEvent(); + + initCoroutine = _Initialize(); + Debug.Log(initCoroutine); + StartCoroutine(initCoroutine); + } + + /// + /// Initializes this instance. + /// + /// Requested width. + /// Requested height. + public virtual void Initialize(int requestedWidth, int requestedHeight) + { + if (isInitWaiting) + { + CancelInitCoroutine(); + ReleaseResources(); + } + + _requestedWidth = requestedWidth; + _requestedHeight = requestedHeight; + if (onInitialized == null) + onInitialized = new UnityEvent(); + if (onDisposed == null) + onDisposed = new UnityEvent(); + if (onErrorOccurred == null) + onErrorOccurred = new ErrorUnityEvent(); + + initCoroutine = _Initialize(); + StartCoroutine(initCoroutine); + } + + /// + /// Initializes this instance. + /// + /// If set to true requested to using the front camera. + /// Requested FPS. + /// If set to true requested to rotate camera frame 90 degrees. (clockwise) + public virtual void Initialize(bool requestedIsFrontFacing, float requestedFPS = 30f, bool rotate90Degree = false) + { + if (isInitWaiting) + { + CancelInitCoroutine(); + ReleaseResources(); + } + + _requestedDeviceName = null; + _requestedIsFrontFacing = requestedIsFrontFacing; + _requestedFPS = requestedFPS; + _rotate90Degree = rotate90Degree; + if (onInitialized == null) + onInitialized = new UnityEvent(); + if (onDisposed == null) + onDisposed = new UnityEvent(); + if (onErrorOccurred == null) + onErrorOccurred = new ErrorUnityEvent(); + + initCoroutine = _Initialize(); + StartCoroutine(initCoroutine); + } + + /// + /// Initializes this instance. + /// + /// Device name. + /// Requested width. + /// Requested height. + /// If set to true requested to using the front camera. + /// Requested FPS. + /// If set to true requested to rotate camera frame 90 degrees. (clockwise) + public virtual void Initialize(string deviceName, int requestedWidth, int requestedHeight, bool requestedIsFrontFacing = false, float requestedFPS = 30f, bool rotate90Degree = false) + { + if (isInitWaiting) + { + CancelInitCoroutine(); + ReleaseResources(); + } + + _requestedDeviceName = deviceName; + _requestedWidth = requestedWidth; + _requestedHeight = requestedHeight; + _requestedIsFrontFacing = requestedIsFrontFacing; + _requestedFPS = requestedFPS; + _rotate90Degree = rotate90Degree; + if (onInitialized == null) + onInitialized = new UnityEvent(); + if (onDisposed == null) + onDisposed = new UnityEvent(); + if (onErrorOccurred == null) + onErrorOccurred = new ErrorUnityEvent(); + + initCoroutine = _Initialize(); + StartCoroutine(initCoroutine); + } + + /// + /// Initializes this instance by coroutine. + /// + protected virtual IEnumerator _Initialize() + { + Debug.Log("1"); + if (hasInitDone) + { + ReleaseResources(); + + if (onDisposed != null) + onDisposed.Invoke(); + } + + isInitWaiting = true; + +#if (UNITY_IOS || UNITY_WEBGL || UNITY_ANDROID) && !UNITY_EDITOR + // Checks camera permission state. + IEnumerator coroutine = hasUserAuthorizedCameraPermission(); + yield return coroutine; + + if (!(bool)coroutine.Current) + { + isInitWaiting = false; + initCoroutine = null; + + if (onErrorOccurred != null) + onErrorOccurred.Invoke(ErrorCode.CAMERA_PERMISSION_DENIED); + + yield break; + } +#endif + + float requestedFPS = this.requestedFPS; + // Creates the camera + + // Starts the camera + uvcTexture.Play(); + Debug.Log("2"); + + int initFrameCount = 0; + bool isTimeout = false; + + while (true) + { + if (initFrameCount > timeoutFrameCount) + { + isTimeout = true; + break; + } + else if (uvcTexture.didUpdateThisFrame) + { + Debug.Log("UVCTextureToMatHelper:: " + " name:" + uvcTexture.name + " width:" + uvcTexture.width + " height:" + uvcTexture.height + " fps:" + uvcTexture.requestedFPS); + + if (colors == null || colors.Length != uvcTexture.width * uvcTexture.height) + colors = new Color32[uvcTexture.width * uvcTexture.height]; + + baseMat = new Mat(uvcTexture.height, uvcTexture.width, CvType.CV_8UC4); + + if (baseColorFormat == outputColorFormat) + { + frameMat = baseMat; + } + else + { + frameMat = new Mat(baseMat.rows(), baseMat.cols(), CvType.CV_8UC(Channels(outputColorFormat)), new Scalar(0, 0, 0, 255)); + } + + screenOrientation = Screen.orientation; + screenWidth = Screen.width; + screenHeight = Screen.height; + + bool isRotatedFrame = false; +#if !UNITY_EDITOR && !(UNITY_STANDALONE || UNITY_WEBGL) + if (screenOrientation == ScreenOrientation.Portrait || screenOrientation == ScreenOrientation.PortraitUpsideDown) + { + if (!rotate90Degree) + isRotatedFrame = true; + } + else if (rotate90Degree) + { + isRotatedFrame = true; + } +#else + if (rotate90Degree) + isRotatedFrame = true; +#endif + if (isRotatedFrame) + rotatedFrameMat = new Mat(frameMat.cols(), frameMat.rows(), CvType.CV_8UC(Channels(outputColorFormat)), new Scalar(0, 0, 0, 255)); + + isInitWaiting = false; + hasInitDone = true; + initCoroutine = null; + + if (onInitialized != null) + onInitialized.Invoke(); + + break; + } + else + { + initFrameCount++; + yield return null; + } + } + + if (isTimeout) + { + uvcTexture.Stop(); + Debug.LogError("uvc timeout"); + isInitWaiting = false; + initCoroutine = null; + + if (onErrorOccurred != null) + onErrorOccurred.Invoke(ErrorCode.TIMEOUT); + } + } + + /// + /// Checks camera permission state by coroutine. + /// + protected virtual IEnumerator hasUserAuthorizedCameraPermission() + { +#if (UNITY_IOS || UNITY_WEBGL) && UNITY_2018_1_OR_NEWER + UserAuthorization mode = UserAuthorization.WebCam; + if (!Application.HasUserAuthorization(mode)) + { + yield return RequestUserAuthorization(mode); + } + yield return Application.HasUserAuthorization(mode); +#elif UNITY_ANDROID && UNITY_2018_3_OR_NEWER + string permission = UnityEngine.Android.Permission.Camera; + if (!UnityEngine.Android.Permission.HasUserAuthorizedPermission(permission)) + { + yield return RequestUserPermission(permission); + } + yield return UnityEngine.Android.Permission.HasUserAuthorizedPermission(permission); +#else + yield return true; +#endif + } + +#if ((UNITY_IOS || UNITY_WEBGL) && UNITY_2018_1_OR_NEWER) || (UNITY_ANDROID && UNITY_2018_3_OR_NEWER) + protected bool isUserRequestingPermission; +#endif + +#if (UNITY_IOS || UNITY_WEBGL) && UNITY_2018_1_OR_NEWER + protected virtual IEnumerator RequestUserAuthorization(UserAuthorization mode) + { + isUserRequestingPermission = true; + yield return Application.RequestUserAuthorization(mode); + + float timeElapsed = 0; + while (isUserRequestingPermission) + { + if (timeElapsed > 0.25f) + { + isUserRequestingPermission = false; + yield break; + } + timeElapsed += Time.deltaTime; + + yield return null; + } + yield break; + } +#elif UNITY_ANDROID && UNITY_2018_3_OR_NEWER + protected virtual IEnumerator RequestUserPermission(string permission) + { + isUserRequestingPermission = true; + UnityEngine.Android.Permission.RequestUserPermission(permission); + + float timeElapsed = 0; + while (isUserRequestingPermission) + { + if (timeElapsed > 0.25f) + { + isUserRequestingPermission = false; + yield break; + } + timeElapsed += Time.deltaTime; + + yield return null; + } + yield break; + } +#endif + + /// + /// Indicates whether this instance has been initialized. + /// + /// true, if this instance has been initialized, false otherwise. + public virtual bool IsInitialized() + { + return hasInitDone; + } + + /// + /// Starts the camera. + /// + public virtual void Play() + { + if (hasInitDone) + uvcTexture.Play(); + } + + /// + /// Pauses the active camera. + /// + public virtual void Pause() + { + if (hasInitDone) + uvcTexture.Pause(); + } + + /// + /// Stops the active camera. + /// + public virtual void Stop() + { + if (hasInitDone) + uvcTexture.Stop(); + } + + /// + /// Indicates whether the active camera is currently playing. + /// + /// true, if the active camera is playing, false otherwise. + public virtual bool IsPlaying() + { + return hasInitDone ? uvcTexture.isPlaying : false; + } + + /// + /// Indicates whether the active camera device is currently front facng. + /// + /// true, if the active camera device is front facng, false otherwise. + public virtual bool IsFrontFacing() + { + return true; + } + + /// + /// Returns the active camera device name. + /// + /// The active camera device name. + public virtual string GetDeviceName() + { + return "usb cam"; + } + + /// + /// Returns the active camera width. + /// + /// The active camera width. + public virtual int GetWidth() + { + if (!hasInitDone) + return -1; + return (rotatedFrameMat != null) ? frameMat.height() : frameMat.width(); + } + + /// + /// Returns the active camera height. + /// + /// The active camera height. + public virtual int GetHeight() + { + if (!hasInitDone) + return -1; + return (rotatedFrameMat != null) ? frameMat.width() : frameMat.height(); + } + + /// + /// Returns the active camera framerate. + /// + /// The active camera framerate. + public virtual float GetFPS() + { + return hasInitDone ? uvcTexture.requestedFPS : -1f; + } + + /// + /// Returns the active WebcamTexture. + /// + /// The active WebcamTexture. + public virtual Texture2D GetTexture() + { + return hasInitDone ? uvcTexture.texture : null; + } + + /// + /// Returns the camera to world matrix. + /// + /// The camera to world matrix. + public virtual Matrix4x4 GetCameraToWorldMatrix() + { + return Camera.main.cameraToWorldMatrix; + } + + /// + /// Returns the projection matrix matrix. + /// + /// The projection matrix. + public virtual Matrix4x4 GetProjectionMatrix() + { + return Camera.main.projectionMatrix; + } + + /// + /// Indicates whether the video buffer of the frame has been updated. + /// + /// true, if the video buffer has been updated false otherwise. + public virtual bool DidUpdateThisFrame() + { + if (!hasInitDone) + return false; + + return uvcTexture.didUpdateThisFrame; + } + + /// + /// Gets the mat of the current frame. + /// The Mat object's type is 'CV_8UC4' or 'CV_8UC3' or 'CV_8UC1' (ColorFormat is determined by the outputColorFormat setting). + /// Please do not dispose of the returned mat as it will be reused. + /// + /// The mat of the current frame. + public virtual Mat GetMat() + { + if (!hasInitDone || !uvcTexture.isPlaying) + { + return (rotatedFrameMat != null) ? rotatedFrameMat : frameMat; + } + + if (baseColorFormat == outputColorFormat) + { + Utils.texture2DToMat(uvcTexture.texture, frameMat, flipHorizontal); + } + else + { + Utils.texture2DToMat(uvcTexture.texture, baseMat, flipHorizontal); + Imgproc.cvtColor(baseMat, frameMat, ColorConversionCodes(baseColorFormat, outputColorFormat)); + } + +#if !UNITY_EDITOR && !(UNITY_STANDALONE || UNITY_WEBGL) + if (rotatedFrameMat != null) + { + if (screenOrientation == ScreenOrientation.Portrait || screenOrientation == ScreenOrientation.PortraitUpsideDown) + { + // (Orientation is Portrait, rotate90Degree is false) + if (uvcTexture.isFrontFacing) + { + FlipMat(frameMat, !flipHorizontal, !flipVertical); + } + else + { + FlipMat(frameMat, flipHorizontal, flipVertical); + } + } + else + { + // (Orientation is Landscape, rotate90Degrees=true) + FlipMat(frameMat, flipVertical, flipHorizontal); + } + Core.rotate(frameMat, rotatedFrameMat, Core.ROTATE_90_CLOCKWISE); + return rotatedFrameMat; + } + else + { + if (screenOrientation == ScreenOrientation.Portrait || screenOrientation == ScreenOrientation.PortraitUpsideDown) + { + // (Orientation is Portrait, rotate90Degree is ture) + if (uvcTexture.isFrontFacing) + { + FlipMat(frameMat, flipHorizontal, flipVertical); + } + else + { + FlipMat(frameMat, !flipHorizontal, !flipVertical); + } + } + else + { + // (Orientation is Landscape, rotate90Degree is false) + FlipMat(frameMat, flipVertical, flipHorizontal); + } + return frameMat; + } +#else + FlipMat(frameMat, flipVertical, flipHorizontal); + if (rotatedFrameMat != null) + { + Core.rotate(frameMat, rotatedFrameMat, Core.ROTATE_90_CLOCKWISE); + return rotatedFrameMat; + } + else + { + return frameMat; + } +#endif + } + + /// + /// Flips the mat. + /// + /// Mat. + protected virtual void FlipMat(Mat mat, bool flipVertical, bool flipHorizontal) + { + //Since the order of pixels of WebCamTexture and Mat is opposite, the initial value of flipCode is set to 0 (flipVertical). + int flipCode = 0; + + if (uvcTexture.isFrontFacing) + { + flipCode = -1; + //if (uvcTexture.videoRotationAngle == 0 || uvcTexture.videoRotationAngle == 90) + //{ + // flipCode = -1; + //} + //else if (uvcTexture.videoRotationAngle == 180 || uvcTexture.videoRotationAngle == 270) + //{ + // flipCode = int.MinValue; + //} + } + else + { + flipCode = 1; + //if (uvcTexture.videoRotationAngle == 180 || uvcTexture.videoRotationAngle == 270) + //{ + // flipCode = 1; + //} + } + + if (flipVertical) + { + if (flipCode == int.MinValue) + { + flipCode = 0; + } + else if (flipCode == 0) + { + flipCode = int.MinValue; + } + else if (flipCode == 1) + { + flipCode = -1; + } + else if (flipCode == -1) + { + flipCode = 1; + } + } + + if (flipHorizontal) + { + if (flipCode == int.MinValue) + { + flipCode = 1; + } + else if (flipCode == 0) + { + flipCode = -1; + } + else if (flipCode == 1) + { + flipCode = int.MinValue; + } + else if (flipCode == -1) + { + flipCode = 0; + } + } + + if (flipCode > int.MinValue) + { + Core.flip(mat, mat, flipCode); + } + } + + protected virtual int Channels(ColorFormat type) + { + switch (type) + { + case ColorFormat.GRAY: + return 1; + case ColorFormat.RGB: + case ColorFormat.BGR: + return 3; + case ColorFormat.RGBA: + case ColorFormat.BGRA: + return 4; + default: + return 4; + } + } + protected virtual int ColorConversionCodes(ColorFormat srcType, ColorFormat dstType) + { + if (srcType == ColorFormat.GRAY) + { + if (dstType == ColorFormat.RGB) return Imgproc.COLOR_GRAY2RGB; + else if (dstType == ColorFormat.BGR) return Imgproc.COLOR_GRAY2BGR; + else if (dstType == ColorFormat.RGBA) return Imgproc.COLOR_GRAY2RGBA; + else if (dstType == ColorFormat.BGRA) return Imgproc.COLOR_GRAY2BGRA; + } + else if (srcType == ColorFormat.RGB) + { + if (dstType == ColorFormat.GRAY) return Imgproc.COLOR_RGB2GRAY; + else if (dstType == ColorFormat.BGR) return Imgproc.COLOR_RGB2BGR; + else if (dstType == ColorFormat.RGBA) return Imgproc.COLOR_RGB2RGBA; + else if (dstType == ColorFormat.BGRA) return Imgproc.COLOR_RGB2BGRA; + } + else if (srcType == ColorFormat.BGR) + { + if (dstType == ColorFormat.GRAY) return Imgproc.COLOR_BGR2GRAY; + else if (dstType == ColorFormat.RGB) return Imgproc.COLOR_BGR2RGB; + else if (dstType == ColorFormat.RGBA) return Imgproc.COLOR_BGR2RGBA; + else if (dstType == ColorFormat.BGRA) return Imgproc.COLOR_BGR2BGRA; + } + else if (srcType == ColorFormat.RGBA) + { + if (dstType == ColorFormat.GRAY) return Imgproc.COLOR_RGBA2GRAY; + else if (dstType == ColorFormat.RGB) return Imgproc.COLOR_RGBA2RGB; + else if (dstType == ColorFormat.BGR) return Imgproc.COLOR_RGBA2BGR; + else if (dstType == ColorFormat.BGRA) return Imgproc.COLOR_RGBA2BGRA; + } + else if (srcType == ColorFormat.BGRA) + { + if (dstType == ColorFormat.GRAY) return Imgproc.COLOR_BGRA2GRAY; + else if (dstType == ColorFormat.RGB) return Imgproc.COLOR_BGRA2RGB; + else if (dstType == ColorFormat.BGR) return Imgproc.COLOR_BGRA2BGR; + else if (dstType == ColorFormat.RGBA) return Imgproc.COLOR_BGRA2RGBA; + } + + return -1; + } + + /// + /// Gets the buffer colors. + /// + /// The buffer colors. + public virtual Color32[] GetBufferColors() + { + return colors; + } + + /// + /// Cancel Init Coroutine. + /// + protected virtual void CancelInitCoroutine() + { + if (initCoroutine != null) + { + StopCoroutine(initCoroutine); + ((IDisposable)initCoroutine).Dispose(); + initCoroutine = null; + } + } + + /// + /// To release the resources. + /// + protected virtual void ReleaseResources() + { + isInitWaiting = false; + hasInitDone = false; + + if (uvcTexture != null) + { + uvcTexture.Stop(); + } + if (frameMat != null) + { + frameMat.Dispose(); + frameMat = null; + } + if (baseMat != null) + { + baseMat.Dispose(); + baseMat = null; + } + if (rotatedFrameMat != null) + { + rotatedFrameMat.Dispose(); + rotatedFrameMat = null; + } + } + + /// + /// Releases all resource used by the object. + /// + /// Call when you are finished using the . The + /// method leaves the in an unusable state. After + /// calling , you must release all references to the so + /// the garbage collector can reclaim the memory that the was occupying. + public virtual void Dispose() + { + if (colors != null) + colors = null; + + if (isInitWaiting) + { + CancelInitCoroutine(); + ReleaseResources(); + } + else if (hasInitDone) + { + ReleaseResources(); + + if (onDisposed != null) + onDisposed.Invoke(); + } + } + } +} + +#endif +#endif \ No newline at end of file diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCCameraToMatHelper.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCCameraToMatHelper.cs.meta new file mode 100644 index 0000000..b1ad44c --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCCameraToMatHelper.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 84a7daacad6b09f48b400beb5b4ddb06 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCTexture.cs b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCTexture.cs new file mode 100644 index 0000000..1f07b02 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCTexture.cs @@ -0,0 +1,256 @@ +using OpenCVForUnity.UnityUtils; +using Serenegiant.UVC; +using System; +using System.Collections; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.UI; + +public class UVCTexture : MonoBehaviour, IUVCDrawer +{ + /// + /// 图片尺寸裁剪 + /// + public float textureClipArea + { + get + { + if(_textureClipArea<=0) + { + _textureClipArea = PlayerPrefs.GetFloat("clipArea", 0.5f); + } + return _textureClipArea; + } + } + float _textureClipArea = -1; + /// + /// 图片裁剪位置X + /// + public float clipOffsetX + { + get + { + if(_clipOffsetX < -1) + { + _clipOffsetX = PlayerPrefs.GetFloat("clipOffsetX", 0); + } + return _clipOffsetX; + } + } + + float _clipOffsetX = -2; + /// + /// 图片裁剪位置 + /// + public float clipOffsetY + { + get + { + if (_clipOffsetY < -1) + { + _clipOffsetY = PlayerPrefs.GetFloat("clipOffsetY", 0); + } + return _clipOffsetY; + } + } + + float _clipOffsetY = -2; + + public int height + { + get + { + return texture.height; + } + } + public int width + { + get + { + return texture.width; + } + } + + public float requestedFPS + { + get + { + return _requestedFPS; + } + set + { + _requestedFPS = value; + } + } + float _requestedFPS; + + + public bool didUpdateThisFrame + { + get + { + return _didUpdateThisFrame; + } + } + bool _didUpdateThisFrame = false; + /// + /// 图片缩放,最好不要缩放,影响识别效果 + /// + [Range(0.3f,1)] + public float sizeScale = 0.5f; + + public bool isPlaying + { + get + { + return _isPlaying; + } + } + bool _isPlaying; + /// + /// 是否为前置相机 + /// + public bool isFrontFacing = false; + public UVCFilter[] UVCFilters; + private const string TAG = "UVCDrawer#"; + UVCManager uvcManager; + public Texture2D texture + { + get + { + return camTexture; + } + } + + Texture2D camTexture; + public bool CanDraw(UVCManager manager, UVCDevice device) + { + return UVCFilter.Match(device, UVCFilters); + } + + public bool OnUVCAttachEvent(UVCManager manager, UVCDevice device) + { + var result = !device.IsRicoh || device.IsTHETA; + + result &= UVCFilter.Match(device, UVCFilters); + + return result; + } + + public void OnUVCDetachEvent(UVCManager manager, UVCDevice device) + { + Debug.Log("uvc detach event"); + } + + public void OnUVCStartEvent(UVCManager manager, UVCDevice device, Texture tex) + { + uvcManager = manager; + HandleOnStartPreview(tex); + } + + public void OnUVCStopEvent(UVCManager manager, UVCDevice device) + { + HandleOnStopPreview(); + } + + private void HandleOnStartPreview(Texture tex) + { + int width = (int)(tex.width * sizeScale * textureClipArea); + int height = (int)(tex.height * sizeScale * textureClipArea); + camTexture = new Texture2D(width, height, TextureFormat.RGB24, false);// (Texture2D)tex; + Debug.Log("uvc texture start"); + _isPlaying = true; + + _didUpdateThisFrame = true; + } + + void Update() + { + if (uvcManager != null) + { + var devices = uvcManager.GetAttachedDevices(); + if(devices.Count > 0) + { + textureToTexture2D(devices[0].previewTexture, camTexture); + } + } + + //if (uvcManager != null) + //{ + // camTexture = (Texture2D)uvcManager.GetAttachedDevices()[0].previewTexture; + // FindObjectOfType().texture = camTexture; + //} + + //if (camTexture != null) + //{ + // frameTimer += Time.deltaTime; + // float fTime = 1 / FPS; + // if (frameTimer >= fTime) + // { + // _didUpdateThisFrame = true; + // frameTimer -= fTime; + // } + // else + // { + // _didUpdateThisFrame = false; + // } + //} + } + + private void HandleOnStopPreview() + { + Debug.Log("uvc stop preview"); + } + + public void Play() + { + + } + public void Pause() + { + + } + public void Stop() + { + Debug.Log("uvc texture stop"); + } + + public void textureToTexture2D(Texture texture,Texture2D texture2D) + { + if (texture == null) + throw new ArgumentNullException("texture"); + + if (texture2D == null) + throw new ArgumentNullException("texture2D"); + + //if (texture.width != texture2D.width || texture.height != texture2D.height) + // throw new ArgumentException("texture and texture2D need to be the same size."); + + RenderTexture prevRT = RenderTexture.active; + + if (texture is RenderTexture) + { + RenderTexture.active = (RenderTexture)texture; + texture2D.ReadPixels(new UnityEngine.Rect(0f, 0f, texture.width, texture.height), 0, 0, false); + texture2D.Apply(false, false); + } + else + { + int width = (int)(texture.width * sizeScale); + int height = (int)(texture.height * sizeScale); + RenderTexture tempRT = RenderTexture.GetTemporary(width, height, 0, RenderTextureFormat.ARGB32); + Graphics.Blit(texture, tempRT); + RenderTexture.active = tempRT; + + Rect rect = new Rect(0, 0, width * textureClipArea, height * textureClipArea); + rect.x = (width - rect.width) * 0.5f * (1 + clipOffsetX); + rect.y = (height - rect.height) * 0.5f * (1 + clipOffsetY); + + texture2D.ReadPixels(rect, 0, 0, false); + texture2D.Apply(false, false); + RenderTexture.ReleaseTemporary(tempRT); + } + + RenderTexture.active = prevRT; + } +} diff --git a/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCTexture.cs.meta b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCTexture.cs.meta new file mode 100644 index 0000000..350ed32 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/FaceExpression/UVCTexture.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b48c16e283709764bb9d934a3f73886c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/Scripts/RobotAnimControl.cs b/Assets/_VoiceAssistant/Scripts/RobotAnimControl.cs index d6ad6f0..3d215a8 100644 --- a/Assets/_VoiceAssistant/Scripts/RobotAnimControl.cs +++ b/Assets/_VoiceAssistant/Scripts/RobotAnimControl.cs @@ -40,4 +40,9 @@ public class RobotAnimControl : CharacterAnimControlBase { animator.SetTrigger("idle"); } + + public override void Dance() + { + animator.SetTrigger("dance"); + } } diff --git a/Assets/_VoiceAssistant/Scripts/UI/ChatBox.cs b/Assets/_VoiceAssistant/Scripts/UI/ChatBox.cs new file mode 100644 index 0000000..6358059 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/UI/ChatBox.cs @@ -0,0 +1,40 @@ +using System.Collections; +using System.Collections.Generic; +using TMPro; +using UnityEngine; + +public class ChatBox : MonoBehaviour +{ + public TextMeshPro textMeshPro; + + public void SetText(string text, CarAssistant.Expression expression = CarAssistant.Expression.Neutral) + { + int emojiIndex = -1; + switch (expression) + { + case CarAssistant.Expression.Neutral: + break; + case CarAssistant.Expression.Happy: + emojiIndex = 5; + break; + case CarAssistant.Expression.Sad: + emojiIndex = 15; + break; + case CarAssistant.Expression.Doubt: + emojiIndex = 12; + break; + case CarAssistant.Expression.Suprised: + break; + case CarAssistant.Expression.Smile: + emojiIndex = 0; + break; + default: + break; + } + if(emojiIndex >= 0) + { + text += $""; + } + textMeshPro.text = text; + } +} diff --git a/Assets/_VoiceAssistant/Scripts/UI/ChatBox.cs.meta b/Assets/_VoiceAssistant/Scripts/UI/ChatBox.cs.meta new file mode 100644 index 0000000..96d4226 --- /dev/null +++ b/Assets/_VoiceAssistant/Scripts/UI/ChatBox.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d7a321df2a6cc0143875c6264f77afea +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/_Arts/Audio/Care.meta b/Assets/_VoiceAssistant/_Arts/Audio/Care.meta new file mode 100644 index 0000000..23d6d5d --- /dev/null +++ b/Assets/_VoiceAssistant/_Arts/Audio/Care.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b1997c85496fbb041a9c98b22510ccbb +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/_Arts/Audio/Care/Can I help you out.wav b/Assets/_VoiceAssistant/_Arts/Audio/Care/Can I help you out.wav new file mode 100644 index 0000000..a65cfa2 Binary files /dev/null and b/Assets/_VoiceAssistant/_Arts/Audio/Care/Can I help you out.wav differ diff --git a/Assets/_VoiceAssistant/_Arts/Audio/Care/Can I help you out.wav.meta b/Assets/_VoiceAssistant/_Arts/Audio/Care/Can I help you out.wav.meta new file mode 100644 index 0000000..178a175 --- /dev/null +++ b/Assets/_VoiceAssistant/_Arts/Audio/Care/Can I help you out.wav.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: 1a832d6973b62754e8b3ed14465a278b +AudioImporter: + externalObjects: {} + serializedVersion: 7 + defaultSettings: + serializedVersion: 2 + loadType: 0 + sampleRateSetting: 0 + sampleRateOverride: 44100 + compressionFormat: 0 + quality: 1 + conversionMode: 0 + preloadAudioData: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + loadInBackground: 0 + ambisonic: 0 + 3D: 1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/_Arts/Audio/Care/look surprised.wav b/Assets/_VoiceAssistant/_Arts/Audio/Care/look surprised.wav new file mode 100644 index 0000000..16b5a40 Binary files /dev/null and b/Assets/_VoiceAssistant/_Arts/Audio/Care/look surprised.wav differ diff --git a/Assets/_VoiceAssistant/_Arts/Audio/Care/look surprised.wav.meta b/Assets/_VoiceAssistant/_Arts/Audio/Care/look surprised.wav.meta new file mode 100644 index 0000000..04eda50 --- /dev/null +++ b/Assets/_VoiceAssistant/_Arts/Audio/Care/look surprised.wav.meta @@ -0,0 +1,23 @@ +fileFormatVersion: 2 +guid: 3c6e71f6457937b469d6f6fae991700c +AudioImporter: + externalObjects: {} + serializedVersion: 7 + defaultSettings: + serializedVersion: 2 + loadType: 0 + sampleRateSetting: 0 + sampleRateOverride: 44100 + compressionFormat: 0 + quality: 1 + conversionMode: 0 + preloadAudioData: 0 + platformSettingOverrides: {} + forceToMono: 0 + normalize: 1 + loadInBackground: 0 + ambisonic: 0 + 3D: 1 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/_Arts/Models/Robot/Animations/SK_RYU_CASUAL_02@Wave Hip Hop Dance.fbx b/Assets/_VoiceAssistant/_Arts/Models/Robot/Animations/SK_RYU_CASUAL_02@Wave Hip Hop Dance.fbx new file mode 100644 index 0000000..95f8df6 Binary files /dev/null and b/Assets/_VoiceAssistant/_Arts/Models/Robot/Animations/SK_RYU_CASUAL_02@Wave Hip Hop Dance.fbx differ diff --git a/Assets/_VoiceAssistant/_Arts/Models/Robot/Animations/SK_RYU_CASUAL_02@Wave Hip Hop Dance.fbx.meta b/Assets/_VoiceAssistant/_Arts/Models/Robot/Animations/SK_RYU_CASUAL_02@Wave Hip Hop Dance.fbx.meta new file mode 100644 index 0000000..7b38026 --- /dev/null +++ b/Assets/_VoiceAssistant/_Arts/Models/Robot/Animations/SK_RYU_CASUAL_02@Wave Hip Hop Dance.fbx.meta @@ -0,0 +1,1199 @@ +fileFormatVersion: 2 +guid: 2a38c6a844640844baf14284c7046cee +ModelImporter: + serializedVersion: 22200 + internalIDToNameTable: [] + externalObjects: {} + materials: + materialImportMode: 2 + materialName: 0 + materialSearch: 1 + materialLocation: 1 + animations: + legacyGenerateAnimations: 4 + bakeSimulation: 0 + resampleCurves: 1 + optimizeGameObjects: 0 + removeConstantScaleCurves: 0 + motionNodeName: + animationImportErrors: + animationImportWarnings: + animationRetargetingWarnings: + animationDoRetargetingWarnings: 0 + importAnimatedCustomProperties: 0 + importConstraints: 0 + animationCompression: 3 + animationRotationError: 0.5 + animationPositionError: 0.5 + animationScaleError: 0.5 + animationWrapMode: 0 + extraExposedTransformPaths: [] + extraUserProperties: [] + clipAnimations: [] + isReadable: 0 + meshes: + lODScreenPercentages: [] + globalScale: 1 + meshCompression: 0 + addColliders: 0 + useSRGBMaterialColor: 1 + sortHierarchyByName: 1 + importPhysicalCameras: 1 + importVisibility: 1 + importBlendShapes: 1 + importCameras: 1 + importLights: 1 + nodeNameCollisionStrategy: 1 + fileIdsGeneration: 2 + swapUVChannels: 0 + generateSecondaryUV: 0 + useFileUnits: 1 + keepQuads: 0 + weldVertices: 1 + bakeAxisConversion: 0 + preserveHierarchy: 0 + skinWeightsMode: 0 + maxBonesPerVertex: 4 + minBoneWeight: 0.001 + optimizeBones: 1 + meshOptimizationFlags: -1 + indexFormat: 0 + secondaryUVAngleDistortion: 8 + secondaryUVAreaDistortion: 15.000001 + secondaryUVHardAngle: 88 + secondaryUVMarginMethod: 1 + secondaryUVMinLightmapResolution: 40 + secondaryUVMinObjectScale: 1 + secondaryUVPackMargin: 4 + useFileScale: 1 + strictVertexDataChecks: 0 + tangentSpace: + normalSmoothAngle: 60 + normalImportMode: 0 + tangentImportMode: 3 + normalCalculationMode: 4 + legacyComputeAllNormalsFromSmoothingGroupsWhenMeshHasBlendShapes: 0 + blendShapeNormalImportMode: 1 + normalSmoothingSource: 0 + referencedClips: [] + importAnimation: 1 + humanDescription: + serializedVersion: 3 + human: + - boneName: pelvis + humanName: Hips + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thigh_l + humanName: LeftUpperLeg + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thigh_r + humanName: RightUpperLeg + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: calf_l + humanName: LeftLowerLeg + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: calf_r + humanName: RightLowerLeg + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: foot_l + humanName: LeftFoot + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: foot_r + humanName: RightFoot + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: spine_01 + humanName: Spine + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: spine_02 + humanName: Chest + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: neck_01 + humanName: Neck + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: head + humanName: Head + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: clavicle_l + humanName: LeftShoulder + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: clavicle_r + humanName: RightShoulder + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: upperarm_l + humanName: LeftUpperArm + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: upperarm_r + humanName: RightUpperArm + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: lowerarm_l + humanName: LeftLowerArm + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: lowerarm_r + humanName: RightLowerArm + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: hand_l + humanName: LeftHand + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: hand_r + humanName: RightHand + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ball_l + humanName: LeftToes + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ball_r + humanName: RightToes + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: eye_l + humanName: LeftEye + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: eye_r + humanName: RightEye + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thumb_01_l + humanName: Left Thumb Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thumb_02_l + humanName: Left Thumb Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thumb_03_l + humanName: Left Thumb Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: index_01_l + humanName: Left Index Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: index_02_l + humanName: Left Index Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: index_03_l + humanName: Left Index Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: middle_01_l + humanName: Left Middle Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: middle_02_l + humanName: Left Middle Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: middle_03_l + humanName: Left Middle Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ring_01_l + humanName: Left Ring Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ring_02_l + humanName: Left Ring Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ring_03_l + humanName: Left Ring Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: pinky_01_l + humanName: Left Little Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: pinky_02_l + humanName: Left Little Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: pinky_03_l + humanName: Left Little Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thumb_01_r + humanName: Right Thumb Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thumb_02_r + humanName: Right Thumb Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: thumb_03_r + humanName: Right Thumb Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: index_01_r + humanName: Right Index Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: index_02_r + humanName: Right Index Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: index_03_r + humanName: Right Index Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: middle_01_r + humanName: Right Middle Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: middle_02_r + humanName: Right Middle Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: middle_03_r + humanName: Right Middle Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ring_01_r + humanName: Right Ring Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ring_02_r + humanName: Right Ring Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: ring_03_r + humanName: Right Ring Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: pinky_01_r + humanName: Right Little Proximal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: pinky_02_r + humanName: Right Little Intermediate + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: pinky_03_r + humanName: Right Little Distal + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + - boneName: spine_03 + humanName: UpperChest + limit: + min: {x: 0, y: 0, z: 0} + max: {x: 0, y: 0, z: 0} + value: {x: 0, y: 0, z: 0} + length: 0 + modified: 0 + skeleton: + - name: SK_RYU_CASUAL_02@Wave Hip Hop Dance(Clone) + parentName: + position: {x: 0, y: 0, z: 0} + rotation: {x: 0, y: 0, z: 0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: root + parentName: SK_RYU_CASUAL_02@Wave Hip Hop Dance(Clone) + position: {x: 0.042481437, y: -0.010758362, z: 0.081192456} + rotation: {x: -0.72876817, y: 0.02748016, z: 0.051519256, w: 0.6822665} + scale: {x: 1, y: 1, z: 1} + - name: pelvis + parentName: root + position: {x: -0, y: 0.010562, z: 1.0347699} + rotation: {x: 0.0012921153, y: 0.7071056, z: 0.0012921153, w: 0.70710564} + scale: {x: 1, y: 1, z: 1} + - name: spine_01 + parentName: pelvis + position: {x: -0.108089, y: -0.008514, z: 0} + rotation: {x: 0.018583003, y: 0.018685037, z: 0.13187358, w: 0.9909162} + scale: {x: 1, y: 1, z: 1} + - name: spine_02 + parentName: spine_01 + position: {x: -0.141847, y: 0.031949997, z: 0} + rotation: {x: 0.0025395192, y: -0.010007739, z: -0.123831674, w: 0.99224955} + scale: {x: 1, y: 1, z: 1} + - name: spine_03 + parentName: spine_02 + position: {x: -0.108559, y: 0.007202, z: 0} + rotation: {x: 0.0038531392, y: -0.0095904395, z: -0.025635244, w: 0.99961793} + scale: {x: 1, y: 1, z: 1} + - name: clavicle_l + parentName: spine_03 + position: {x: -0.075201, y: -0.020034999, z: -0.03782} + rotation: {x: 0.13863407, y: -0.67364883, z: -0.083891265, w: 0.72106874} + scale: {x: 1, y: 1, z: 1} + - name: upperarm_l + parentName: clavicle_l + position: {x: -0.09909199, y: -0.029779999, z: 0.0133} + rotation: {x: 0.5733433, y: 0.084192015, z: 0.19806334, w: 0.7905442} + scale: {x: 1, y: 1, z: 1} + - name: lowerarm_l + parentName: upperarm_l + position: {x: -0.242702, y: 0.015062999, z: -0.028861} + rotation: {x: -0.0685485, y: -0.04322698, z: 0.057321906, w: 0.9950612} + scale: {x: 1, y: 1, z: 1} + - name: hand_l + parentName: lowerarm_l + position: {x: -0.22265498, y: 0.038561, z: 0.000955} + rotation: {x: -0.6679268, y: 0.092461914, z: -0.0050374833, w: 0.7384438} + scale: {x: 1, y: 1, z: 1} + - name: index_01_l + parentName: hand_l + position: {x: -0.08913, y: 0.017725, z: -0.021001} + rotation: {x: 0.13465597, y: -0.054959103, z: -0.108885735, w: 0.98335713} + scale: {x: 1, y: 1, z: 1} + - name: index_02_l + parentName: index_01_l + position: {x: -0.034856997, y: 0.003088, z: 0.00293} + rotation: {x: 0.017035939, y: 0.0072858003, z: -0.035733815, w: 0.99918956} + scale: {x: 1, y: 1, z: 1} + - name: index_03_l + parentName: index_02_l + position: {x: -0.027228998, y: 0.0026879997, z: 0.001267} + rotation: {x: 0.010611449, y: -0.007851115, z: 0.082854904, w: 0.9964742} + scale: {x: 1, y: 1, z: 1} + - name: middle_01_l + parentName: hand_l + position: {x: -0.087161995, y: 0.012798, z: 0.0014470001} + rotation: {x: 0.022019595, y: -0.0376932, z: -0.0748736, w: 0.9962371} + scale: {x: 1, y: 1, z: 1} + - name: middle_02_l + parentName: middle_01_l + position: {x: -0.036494996, y: 0.005328, z: 0.0033309998} + rotation: {x: 0.005211368, y: 0.0052661537, z: 0.11793828, w: 0.99299324} + scale: {x: 1, y: 1, z: 1} + - name: middle_03_l + parentName: middle_02_l + position: {x: -0.025468, y: 0.0125899995, z: 0.0021839999} + rotation: {x: 0.0016209402, y: 0.038867347, z: 0.13362423, w: 0.9902683} + scale: {x: 1, y: 1, z: 1} + - name: pinky_01_l + parentName: hand_l + position: {x: -0.07193, y: 0.017662, z: 0.042512998} + rotation: {x: -0.14511009, y: 0.032894902, z: -0.031928886, w: 0.98835295} + scale: {x: 1, y: 1, z: 1} + - name: pinky_02_l + parentName: pinky_01_l + position: {x: -0.023021, y: 0.0047899997, z: 0.0011069999} + rotation: {x: 0.014791664, y: -0.08836678, z: 0.22367913, w: 0.970536} + scale: {x: 1, y: 1, z: 1} + - name: pinky_03_l + parentName: pinky_02_l + position: {x: -0.012778999, y: 0.0117069995, z: 0.003519} + rotation: {x: 0.0035809563, y: -0.033796687, z: -0.008930309, w: 0.99938244} + scale: {x: 1, y: 1, z: 1} + - name: ring_01_l + parentName: hand_l + position: {x: -0.080726005, y: 0.013911, z: 0.022336999} + rotation: {x: -0.113491766, y: -0.033885874, z: -0.025896268, w: 0.99262315} + scale: {x: 1, y: 1, z: 1} + - name: ring_02_l + parentName: ring_01_l + position: {x: -0.030043, y: 0.0066619995, z: 0.004618} + rotation: {x: 0.036065906, y: -0.0011862365, z: 0.11794605, w: 0.9923641} + scale: {x: 1, y: 1, z: 1} + - name: ring_03_l + parentName: ring_02_l + position: {x: -0.021405, y: 0.012720999, z: 0.003534} + rotation: {x: -0.00019909619, y: -0.026258081, z: 0.11221322, w: 0.99333715} + scale: {x: 1, y: 1, z: 1} + - name: thumb_01_l + parentName: hand_l + position: {x: -0.019053, y: 0.028185999, z: -0.024036} + rotation: {x: 0.74854165, y: 0.16323642, z: 0.32851443, w: 0.55237454} + scale: {x: 1, y: 1, z: 1} + - name: thumb_02_l + parentName: thumb_01_l + position: {x: -0.033513, y: 0.000305, z: -0.007274} + rotation: {x: -0.20607509, y: -0.0043507507, z: 0.019072488, w: 0.9783406} + scale: {x: 1, y: 1, z: 1} + - name: thumb_03_l + parentName: thumb_02_l + position: {x: -0.02756, y: 0.0052839997, z: -0.003532} + rotation: {x: 0.02139941, y: -0.0018833912, z: 0.107938, w: 0.9939255} + scale: {x: 1, y: 1, z: 1} + - name: lowerarm_twist_01_l + parentName: lowerarm_l + position: {x: -0.130469, y: 0.019730998, z: 0.0036250001} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: upperarm_twist_01_l + parentName: upperarm_l + position: {x: -0.005, y: 0, z: 0} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: neck_01 + parentName: spine_03 + position: {x: -0.114855, y: -0.030027999, z: 0} + rotation: {x: 0.0033892817, y: 0.0056904596, z: 0.2009078, w: 0.9795878} + scale: {x: 1, y: 1, z: 1} + - name: head + parentName: neck_01 + position: {x: -0.09650099, y: -0.011027, z: 0} + rotation: {x: 0.00548028, y: 0.020191718, z: -0.136735, w: 0.9903867} + scale: {x: 1, y: 1, z: 1} + - name: eye_l + parentName: head + position: {x: -0.044864997, y: -0.045482, z: -0.029238999} + rotation: {x: 0.50572807, y: -0.49420562, z: 0.50572807, w: 0.49420562} + scale: {x: 1, y: 1, z: 1} + - name: eye_r + parentName: head + position: {x: -0.044866, y: -0.045482, z: 0.028733999} + rotation: {x: -0.4942056, y: -0.505728, z: -0.4942056, w: 0.505728} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_01_l + parentName: head + position: {x: 0.044523, y: 0.108448, z: -0.09345999} + rotation: {x: -0.1947739, y: 0.9418043, z: -0.26951483, w: -0.049291767} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_02_l + parentName: hair_back_01_l + position: {x: -0.115673, y: 0, z: 0} + rotation: {x: 0.20440336, y: 0.05882074, z: 0.10204856, w: 0.9717744} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_03_l + parentName: hair_back_02_l + position: {x: -0.120216, y: 0.0038339999, z: 0} + rotation: {x: 0.18586376, y: 0.22173636, z: -0.61491615, w: 0.7335979} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_01_r + parentName: head + position: {x: 0.044520997, y: 0.108448, z: 0.09345999} + rotation: {x: 0.928171, y: 0.23021944, z: 0.05804743, w: -0.28658003} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_02_r + parentName: hair_back_01_r + position: {x: 0.11567, y: -0.000001, z: 0} + rotation: {x: 0.20440336, y: 0.05882074, z: 0.10204856, w: 0.9717744} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_03_r + parentName: hair_back_02_r + position: {x: 0.120218, y: -0.0038339999, z: 0} + rotation: {x: 0.18586376, y: 0.22173636, z: -0.61491615, w: 0.7335979} + scale: {x: 1, y: 1, z: 1} + - name: hair_front_01_l + parentName: head + position: {x: 0.011313, y: -0.020185001, z: -0.080077} + rotation: {x: -0.045471508, y: 0.7755918, z: -0.62919784, w: -0.022356136} + scale: {x: 1, y: 1, z: 1} + - name: hair_front_02_l + parentName: hair_front_01_l + position: {x: -0.081454, y: 0, z: 0} + rotation: {x: 0.34891507, y: 0.10974992, z: -0.19462712, w: 0.9101283} + scale: {x: 1, y: 1, z: 1} + - name: hair_front_03_l + parentName: hair_front_02_l + position: {x: -0.091561, y: 0, z: 0} + rotation: {x: -0.13435382, y: -0.23052588, z: -0.4852814, w: 0.8326517} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_01_mid + parentName: head + position: {x: 0.044387996, y: 0.134525, z: -0.003607} + rotation: {x: -0.14505926, y: 0.97197014, z: -0.18357259, w: -0.023086706} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_02_mid + parentName: hair_back_01_mid + position: {x: -0.134798, y: 0, z: 0} + rotation: {x: 0.046490423, y: 0.0123186875, z: 0.014221102, w: 0.9987415} + scale: {x: 1, y: 1, z: 1} + - name: hair_back_03_mid + parentName: hair_back_02_mid + position: {x: -0.097555995, y: 0, z: 0} + rotation: {x: 0.322336, y: 0.4127546, z: -0.5243371, w: 0.6714192} + scale: {x: 1, y: 1, z: 1} + - name: earring_r + parentName: head + position: {x: -0.012135, y: 0.006571, z: 0.067659} + rotation: {x: 0.50572807, y: -0.49420562, z: 0.50572807, w: 0.49420562} + scale: {x: 1, y: 1, z: 1} + - name: earring_l + parentName: head + position: {x: -0.012853, y: 0.005542, z: -0.068551995} + rotation: {x: -0.4942056, y: -0.505728, z: -0.4942056, w: 0.505728} + scale: {x: 1, y: 1, z: 1} + - name: clavicle_r + parentName: spine_03 + position: {x: -0.075201, y: -0.020034999, z: 0.03782} + rotation: {x: 0.7104444, y: 0.085247144, z: 0.6985613, w: -0.0037152658} + scale: {x: 1, y: 1, z: 1} + - name: upperarm_r + parentName: clavicle_r + position: {x: 0.09909199, y: 0.029779999, z: -0.0133} + rotation: {x: 0.5917966, y: 0.049380776, z: 0.11630351, w: 0.796123} + scale: {x: 1, y: 1, z: 1} + - name: lowerarm_r + parentName: upperarm_r + position: {x: 0.24270299, y: -0.015062999, z: 0.028861} + rotation: {x: -0.07102852, y: -0.04015321, z: 0.044822138, w: 0.9956574} + scale: {x: 1, y: 1, z: 1} + - name: hand_r + parentName: lowerarm_r + position: {x: 0.222657, y: -0.038562, z: -0.000952} + rotation: {x: -0.7171861, y: 0.0973944, z: -0.058974933, w: 0.6875176} + scale: {x: 1, y: 1, z: 1} + - name: index_01_r + parentName: hand_r + position: {x: 0.089125, y: -0.017719999, z: 0.021001998} + rotation: {x: 0.13466133, y: -0.05488255, z: -0.10896412, w: 0.983352} + scale: {x: 1, y: 1, z: 1} + - name: index_02_r + parentName: index_01_r + position: {x: 0.034858, y: -0.003088, z: -0.00293} + rotation: {x: 0.017480237, y: 0.0085272, z: -0.030760977, w: 0.99933755} + scale: {x: 1, y: 1, z: 1} + - name: index_03_r + parentName: index_02_r + position: {x: 0.02723, y: -0.0026879997, z: -0.001267} + rotation: {x: 0.010612319, y: -0.007851188, z: 0.0828549, w: 0.9964742} + scale: {x: 1, y: 1, z: 1} + - name: middle_01_r + parentName: hand_r + position: {x: 0.087158, y: -0.012793999, z: -0.001446} + rotation: {x: 0.021863699, y: -0.037450522, z: -0.07830084, w: 0.9959862} + scale: {x: 1, y: 1, z: 1} + - name: middle_02_r + parentName: middle_01_r + position: {x: 0.036496, y: -0.005328, z: -0.0033309998} + rotation: {x: 0.0054952106, y: 0.0052296617, z: 0.12128732, w: 0.9925884} + scale: {x: 1, y: 1, z: 1} + - name: middle_03_r + parentName: middle_02_r + position: {x: 0.025468, y: -0.0125899995, z: -0.0021839999} + rotation: {x: 0.0016218043, y: 0.03886723, z: 0.13362426, w: 0.9902683} + scale: {x: 1, y: 1, z: 1} + - name: pinky_01_r + parentName: hand_r + position: {x: 0.071928, y: -0.01766, z: -0.042512} + rotation: {x: -0.15889259, y: 0.029839493, z: -0.037469868, w: 0.9861332} + scale: {x: 1, y: 1, z: 1} + - name: pinky_02_r + parentName: pinky_01_r + position: {x: 0.02302, y: -0.004789, z: -0.001106} + rotation: {x: 0.0128346095, y: -0.07936799, z: 0.22590989, w: 0.9708248} + scale: {x: 1, y: 1, z: 1} + - name: pinky_03_r + parentName: pinky_02_r + position: {x: 0.012777999, y: -0.0117069995, z: -0.003519} + rotation: {x: 0.0035818284, y: -0.03379668, z: -0.008930339, w: 0.99938244} + scale: {x: 1, y: 1, z: 1} + - name: ring_01_r + parentName: hand_r + position: {x: 0.080721, y: -0.013904999, z: -0.022335999} + rotation: {x: -0.11368631, y: -0.03288986, z: -0.030841999, w: 0.99249315} + scale: {x: 1, y: 1, z: 1} + - name: ring_02_r + parentName: ring_01_r + position: {x: 0.030048, y: -0.006664, z: -0.004619} + rotation: {x: 0.03614783, y: -0.0015026735, z: 0.119234525, w: 0.9922068} + scale: {x: 1, y: 1, z: 1} + - name: ring_03_r + parentName: ring_02_r + position: {x: 0.021403, y: -0.012720999, z: -0.003534} + rotation: {x: -0.00019822933, y: -0.02625818, z: 0.112213194, w: 0.99333715} + scale: {x: 1, y: 1, z: 1} + - name: thumb_01_r + parentName: hand_r + position: {x: 0.019053, y: -0.028185999, z: 0.024036} + rotation: {x: 0.59792644, y: 0.08412402, z: 0.34683713, w: 0.7177124} + scale: {x: 1, y: 1, z: 1} + - name: thumb_02_r + parentName: thumb_01_r + position: {x: 0.033512, y: -0.000305, z: 0.007275} + rotation: {x: -0.09396948, y: -0.04275565, z: 0.044308696, w: 0.9936692} + scale: {x: 1, y: 1, z: 1} + - name: thumb_03_r + parentName: thumb_02_r + position: {x: 0.027559, y: -0.005283, z: 0.0035309999} + rotation: {x: 0.021400278, y: -0.0018834854, z: 0.107938, w: 0.9939255} + scale: {x: 1, y: 1, z: 1} + - name: lowerarm_twist_01_r + parentName: lowerarm_r + position: {x: 0.130466, y: -0.019729, z: -0.0036269997} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: upperarm_twist_01_r + parentName: upperarm_r + position: {x: 0.004997, y: 0, z: -0.000003} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: breast_l + parentName: spine_02 + position: {x: -0.031542, y: -0.132582, z: -0.084584996} + rotation: {x: 0.5283645, y: -0.46992663, z: 0.5283645, w: 0.46992663} + scale: {x: 1, y: 1, z: 1} + - name: breast_r + parentName: spine_02 + position: {x: -0.031537, y: -0.132581, z: 0.084584996} + rotation: {x: -0.46992663, y: -0.5283645, z: -0.46992663, w: 0.5283645} + scale: {x: 1, y: 1, z: 1} + - name: perf_belt_01 + parentName: spine_01 + position: {x: -0.006013, y: -0.104219, z: -0.030703} + rotation: {x: 0.06041575, y: 0.99719536, z: -0.04407218, w: -0.0030018126} + scale: {x: 1, y: 1, z: 1} + - name: perf_belt_02 + parentName: perf_belt_01 + position: {x: -0.058222998, y: 0, z: 0} + rotation: {x: 0.9960109, y: 0.022482073, z: -0.0013015779, w: 0.08634334} + scale: {x: 1, y: 1, z: 1} + - name: perf_belt_03 + parentName: perf_belt_02 + position: {x: -0.051581, y: 0, z: 0} + rotation: {x: -0.4693339, y: -0.487344, z: -0.5107903, w: 0.5303912} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_02_01 + parentName: spine_01 + position: {x: 0.001873, y: -0.074255995, z: 0.104313} + rotation: {x: -0.045497425, y: 0.6849307, z: 0.71342695, w: 0.14079086} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_02_02 + parentName: perf_skirt_02_01 + position: {x: -0.058028, y: 0, z: 0} + rotation: {x: -0.25721082, y: -0.052873418, z: 0.05634615, w: 0.9632612} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_02_03 + parentName: perf_skirt_02_02 + position: {x: -0.049473, y: 0, z: 0} + rotation: {x: 0.135534, y: 0.020849934, z: -0.008243936, w: 0.990519} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_02_04 + parentName: perf_skirt_02_03 + position: {x: -0.106043994, y: 0, z: 0} + rotation: {x: 0.6400063, y: 0.7523014, z: 0.10128803, w: -0.11905997} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_03_01 + parentName: spine_01 + position: {x: -0.000961, y: -0.012790999, z: 0.130907} + rotation: {x: -0.17902566, y: 0.9085082, z: 0.35804054, w: 0.119873494} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_03_02 + parentName: perf_skirt_03_01 + position: {x: -0.060762, y: 0, z: 0} + rotation: {x: 0.06517687, y: 0.037975717, z: -0.009900045, w: 0.9971017} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_03_03 + parentName: perf_skirt_03_02 + position: {x: -0.055175, y: 0, z: 0} + rotation: {x: -0.05194978, y: -0.024606822, z: 0.09482824, w: 0.99383265} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_03_04 + parentName: perf_skirt_03_03 + position: {x: -0.116537, y: 0, z: 0} + rotation: {x: 0.52529407, y: 0.74873793, z: -0.2321994, w: 0.33096984} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_04_01 + parentName: spine_01 + position: {x: -0.002116, y: 0.054954, z: 0.084204994} + rotation: {x: -0.28150734, y: 0.94856197, z: 0.13244458, w: 0.058670856} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_04_02 + parentName: perf_skirt_04_01 + position: {x: -0.062524, y: 0, z: 0} + rotation: {x: 0.059703905, y: 0.03896399, z: 0.12661351, w: 0.98938686} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_04_03 + parentName: perf_skirt_04_02 + position: {x: -0.080236994, y: 0, z: 0} + rotation: {x: 0.22684374, y: 0.08277742, z: 0.09788691, w: 0.96545744} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_04_04 + parentName: perf_skirt_04_03 + position: {x: -0.090085, y: 0, z: 0} + rotation: {x: 0.35445002, y: 0.45578846, z: -0.5012177, w: 0.64451754} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_05_01 + parentName: spine_01 + position: {x: -0.003429, y: 0.060967997, z: -0.051836} + rotation: {x: -0.27736986, y: 0.9539544, z: -0.10464929, w: -0.04566705} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_05_02 + parentName: perf_skirt_05_01 + position: {x: -0.062691, y: 0, z: 0} + rotation: {x: 0.028725822, y: 0.019463189, z: 0.09870781, w: 0.99451137} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_05_03 + parentName: perf_skirt_05_02 + position: {x: -0.069497, y: 0, z: 0} + rotation: {x: -0.32820046, y: -0.083656095, z: 0.23003732, w: 0.9123426} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_05_04 + parentName: perf_skirt_05_03 + position: {x: -0.103478, y: 0, z: 0} + rotation: {x: 0.5871939, y: 0.5887157, z: -0.39231262, w: 0.39332935} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_01_01 + parentName: spine_01 + position: {x: 0.0016979999, y: -0.103238, z: 0.0065649995} + rotation: {x: -0.008718207, y: 0.8532736, z: 0.5163813, w: 0.072100684} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_01_02 + parentName: perf_skirt_01_01 + position: {x: -0.062635, y: 0, z: 0} + rotation: {x: 0.31742528, y: 0.04207435, z: 0.01626263, w: 0.94720984} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_01_03 + parentName: perf_skirt_01_02 + position: {x: -0.048784, y: 0, z: 0} + rotation: {x: 0.12435352, y: 0.012624819, z: 0.013327894, w: 0.9920682} + scale: {x: 1, y: 1, z: 1} + - name: perf_skirt_01_04 + parentName: perf_skirt_01_03 + position: {x: -0.099256, y: 0, z: 0} + rotation: {x: 0.5216908, y: 0.5695999, z: -0.4289777, w: 0.46837264} + scale: {x: 1, y: 1, z: 1} + - name: thigh_l + parentName: pelvis + position: {x: 0.0144879995, y: -0.005314, z: -0.090058} + rotation: {x: 0.09626626, y: 0.12863211, z: -0.0393442, w: 0.9862244} + scale: {x: 1, y: 1, z: 1} + - name: calf_l + parentName: thigh_l + position: {x: 0.44063, y: 0.0047879997, z: 0.03568} + rotation: {x: 0.025952565, y: -0.048038855, z: 0.23947439, w: 0.9693662} + scale: {x: 1, y: 1, z: 1} + - name: calf_twist_01_l + parentName: calf_l + position: {x: 0.200009, y: -0.024786, z: 0.011615} + rotation: {x: 0.002809286, y: 0.0019334576, z: 0.0076128454, w: 0.99996525} + scale: {x: 1, y: 1, z: 1} + - name: foot_l + parentName: calf_l + position: {x: 0.48915598, y: -0.062794, z: 0.028357} + rotation: {x: 0.030625416, y: -0.055604387, z: -0.14812088, w: 0.98692983} + scale: {x: 1, y: 1, z: 1} + - name: ball_l + parentName: foot_l + position: {x: 0.049241, y: -0.076171994, z: -0.0041179997} + rotation: {x: 0.00008010817, y: -0.000030157775, z: 0.71863383, w: 0.6953887} + scale: {x: 1, y: 1, z: 1} + - name: thigh_twist_01_l + parentName: thigh_l + position: {x: 0.218945, y: 0.002411, z: 0.016009001} + rotation: {x: -0.047443792, y: -0.000021566257, z: 0.00049083977, w: 0.99887383} + scale: {x: 1, y: 1, z: 1} + - name: thigh_r + parentName: pelvis + position: {x: 0.014491, y: -0.005314, z: 0.090058} + rotation: {x: -0.04661217, y: 0.058616072, z: 0.9965251, w: 0.036457505} + scale: {x: 1, y: 1, z: 1} + - name: calf_r + parentName: thigh_r + position: {x: -0.440628, y: -0.0047879997, z: -0.03568} + rotation: {x: 0.023077702, y: 0.0095890965, z: 0.22151525, w: 0.97483665} + scale: {x: 1, y: 1, z: 1} + - name: calf_twist_01_r + parentName: calf_r + position: {x: -0.200009, y: 0.024786, z: -0.011615} + rotation: {x: 0.002809286, y: 0.0019334576, z: 0.0076128454, w: 0.99996525} + scale: {x: 1, y: 1, z: 1} + - name: foot_r + parentName: calf_r + position: {x: -0.48915598, y: 0.062794, z: -0.028357} + rotation: {x: 0.03323449, y: -0.05867556, z: -0.13756222, w: 0.988195} + scale: {x: 1, y: 1, z: 1} + - name: ball_r + parentName: foot_r + position: {x: -0.049241, y: 0.076171994, z: 0.004119} + rotation: {x: 0.00008010817, y: -0.000030157775, z: 0.71863383, w: 0.6953887} + scale: {x: 1, y: 1, z: 1} + - name: thigh_twist_01_r + parentName: thigh_r + position: {x: -0.21894199, y: -0.002411, z: -0.016008} + rotation: {x: -0.047443792, y: -0.000021566257, z: 0.00049083977, w: 0.99887383} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_back_01_l + parentName: pelvis + position: {x: -0.017114, y: 0.11324, z: -0.082959004} + rotation: {x: -0.08337371, y: 0.8065541, z: -0.58192575, w: -0.062303916} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_back_02_l + parentName: casual_skirt_back_01_l + position: {x: -0.058548, y: 0, z: 0} + rotation: {x: 0.6552278, y: 0.15054807, z: -0.011979215, w: 0.74018127} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_back_03_l + parentName: casual_skirt_back_02_l + position: {x: -0.079828, y: 0, z: 0} + rotation: {x: -0.3364031, y: -0.4295485, z: -0.5167182, w: 0.65979046} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_back_01_r + parentName: pelvis + position: {x: -0.017115999, y: 0.11324, z: 0.082959004} + rotation: {x: -0.8065541, y: -0.08337376, z: -0.062303882, w: 0.58192575} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_back_02_r + parentName: casual_skirt_back_01_r + position: {x: 0.058548998, y: 0, z: 0} + rotation: {x: 0.6552278, y: 0.15054807, z: -0.011979215, w: 0.74018127} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_back_03_r + parentName: casual_skirt_back_02_r + position: {x: 0.079829, y: 0, z: 0} + rotation: {x: -0.3364031, y: -0.4295485, z: -0.5167182, w: 0.65979046} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_side_01_l + parentName: pelvis + position: {x: -0.037093997, y: -0.008417999, z: -0.151604} + rotation: {x: -0.13351302, y: 0.778969, z: -0.6034959, w: -0.105709} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_side_02_l + parentName: casual_skirt_side_01_l + position: {x: -0.064488, y: 0, z: 0} + rotation: {x: 0.051947605, y: 0.014196222, z: 0.07619183, w: 0.9956379} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_side_03_l + parentName: casual_skirt_side_02_l + position: {x: -0.087133, y: 0, z: 0} + rotation: {x: 0.0458449, y: 0.05552432, z: -0.6350388, w: 0.76911706} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_side_01_r + parentName: pelvis + position: {x: -0.037091, y: -0.008417999, z: 0.151604} + rotation: {x: -0.77896905, y: -0.13351299, z: -0.105709024, w: 0.60349584} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_side_02_r + parentName: casual_skirt_side_01_r + position: {x: 0.06448, y: -0.000002, z: 0} + rotation: {x: 0.051947605, y: 0.014196222, z: 0.07619183, w: 0.9956379} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_side_03_r + parentName: casual_skirt_side_02_r + position: {x: 0.087138005, y: 0.000001, z: 0} + rotation: {x: 0.0458449, y: 0.05552432, z: -0.6350388, w: 0.76911706} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_front_01_l + parentName: pelvis + position: {x: -0.0108010005, y: -0.090255, z: -0.081971996} + rotation: {x: -0.079964064, y: 0.714993, z: -0.6899536, w: -0.079716936} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_front_02_l + parentName: casual_skirt_front_01_l + position: {x: -0.066020995, y: 0, z: 0} + rotation: {x: 0.01851862, y: 0.0026384932, z: 0.084778965, w: 0.9962242} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_front_03_l + parentName: casual_skirt_front_02_l + position: {x: -0.082205996, y: 0, z: 0} + rotation: {x: -0.0007509918, y: -0.00079475855, z: -0.68680996, w: 0.72683626} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_front_01_r + parentName: pelvis + position: {x: -0.010799, y: -0.090255, z: 0.081973} + rotation: {x: -0.714993, y: -0.07996411, z: -0.07971689, w: 0.6899536} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_front_02_r + parentName: casual_skirt_front_01_r + position: {x: 0.066020004, y: 0, z: 0} + rotation: {x: 0.01851862, y: 0.0026384932, z: 0.084778965, w: 0.9962242} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_front_03_r + parentName: casual_skirt_front_02_r + position: {x: 0.082205996, y: 0, z: 0} + rotation: {x: -0.0007509918, y: -0.00079475855, z: -0.68680996, w: 0.72683626} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_fix_bone_front_01 + parentName: pelvis + position: {x: 0.062161002, y: -0.089499, z: 0.0020909999} + rotation: {x: -0.014931882, y: 0.8746436, z: 0.48443237, w: 0.010041123} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_fix_bone_front_02 + parentName: casual_skirt_fix_bone_front_01 + position: {x: -0.07358699, y: 0, z: 0} + rotation: {x: 0.66668934, y: 0.6923754, z: -0.19139552, w: 0.19876957} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_fix_bone_back_01 + parentName: pelvis + position: {x: 0.071269, y: 0.112418, z: -0.0035309999} + rotation: {x: 0.0016485082, y: -0.024729569, z: 0.9972304, w: 0.0701232} + scale: {x: 1, y: 1, z: 1} + - name: casual_skirt_fix_bone_back_02 + parentName: casual_skirt_fix_bone_back_01 + position: {x: -0.07897, y: 0, z: 0} + rotation: {x: -0.45301136, y: -0.5196188, z: -0.47604474, w: 0.54603887} + scale: {x: 1, y: 1, z: 1} + - name: ik_foot_root + parentName: root + position: {x: -0, y: 0, z: 0} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: ik_foot_l + parentName: ik_foot_root + position: {x: -0.118823, y: 0.029732, z: 0.085803} + rotation: {x: 0.02053001, y: 0.71223325, z: -0.011723445, w: 0.70154464} + scale: {x: 1, y: 1, z: 1} + - name: ik_foot_r + parentName: ik_foot_root + position: {x: 0.119242996, y: 0.029732, z: 0.085766} + rotation: {x: 0.70154464, y: 0.011724066, z: 0.71223325, w: -0.020530622} + scale: {x: 1, y: 1, z: 1} + - name: ik_hand_root + parentName: root + position: {x: -0, y: 0, z: 0} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + - name: ik_hand_gun + parentName: ik_hand_root + position: {x: 0.421472, y: 0.015881, z: 1.1062349} + rotation: {x: 0.61884946, y: 0.069540836, z: -0.3891363, w: 0.6787948} + scale: {x: 1, y: 1, z: 1} + - name: ik_hand_l + parentName: ik_hand_gun + position: {x: -0.579445, y: -0.51781696, z: 0.326376} + rotation: {x: 0.68747425, y: 0.61435795, z: -0.38722533, w: -0.0000007917663} + scale: {x: 1, y: 1, z: 1} + - name: ik_hand_r + parentName: ik_hand_gun + position: {x: -0, y: 0, z: 0} + rotation: {x: 0, y: -0, z: -0, w: 1} + scale: {x: 1, y: 1, z: 1} + armTwist: 0.5 + foreArmTwist: 0.5 + upperLegTwist: 0.5 + legTwist: 0.5 + armStretch: 0.05 + legStretch: 0.05 + feetSpacing: 0 + globalScale: 1 + rootMotionBoneName: + hasTranslationDoF: 0 + hasExtraRoot: 1 + skeletonHasParents: 1 + lastHumanDescriptionAvatarSource: {instanceID: 0} + autoGenerateAvatarMappingIfUnspecified: 1 + animationType: 3 + humanoidOversampling: 1 + avatarSetup: 1 + addHumanoidExtraRootOnlyWhenUsingAvatar: 1 + importBlendShapeDeformPercent: 1 + remapMaterialsIfMaterialImportModeIsNone: 0 + additionalBone: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/_VoiceAssistant/_Arts/Models/Robot/robotAnim 1.controller b/Assets/_VoiceAssistant/_Arts/Models/Robot/robotAnim 1.controller index 940f6a3..b09f9ba 100644 --- a/Assets/_VoiceAssistant/_Arts/Models/Robot/robotAnim 1.controller +++ b/Assets/_VoiceAssistant/_Arts/Models/Robot/robotAnim 1.controller @@ -152,6 +152,33 @@ AnimatorStateTransition: m_InterruptionSource: 0 m_OrderedInterruption: 1 m_CanTransitionToSelf: 1 +--- !u!1102 &-3881533873121950449 +AnimatorState: + serializedVersion: 6 + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: Robot Hip Hop Dance + m_Speed: 1 + m_CycleOffset: 0 + m_Transitions: + - {fileID: 5560828704810626401} + 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: -203655887218126122, guid: 2a38c6a844640844baf14284c7046cee, type: 3} + m_Tag: + m_SpeedParameter: + m_MirrorParameter: + m_CycleOffsetParameter: + m_TimeParameter: --- !u!1102 &-3752492594145465479 AnimatorState: serializedVersion: 6 @@ -201,6 +228,31 @@ AnimatorStateTransition: m_InterruptionSource: 0 m_OrderedInterruption: 1 m_CanTransitionToSelf: 1 +--- !u!1101 &-2049146169530471879 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: + - m_ConditionMode: 1 + m_ConditionEvent: dance + m_EventTreshold: 0 + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: -3881533873121950449} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 0 + serializedVersion: 3 + m_TransitionDuration: 0.25 + m_TransitionOffset: 0 + m_ExitTime: 0.75 + m_HasExitTime: 0 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 --- !u!1101 &-1458154305767465992 AnimatorStateTransition: m_ObjectHideFlags: 1 @@ -240,43 +292,49 @@ AnimatorController: m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} - m_Name: blink m_Type: 9 m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} - m_Name: angry m_Type: 9 m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} - m_Name: happy m_Type: 9 m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} - m_Name: sad m_Type: 9 m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} - m_Name: idle m_Type: 9 m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} - m_Name: hi m_Type: 9 m_DefaultFloat: 0 m_DefaultInt: 0 m_DefaultBool: 0 - m_Controller: {fileID: 9100000} + m_Controller: {fileID: 0} + - m_Name: dance + m_Type: 9 + m_DefaultFloat: 0 + m_DefaultInt: 0 + m_DefaultBool: 0 + m_Controller: {fileID: 0} m_AnimatorLayers: - serializedVersion: 5 m_Name: Base Layer @@ -680,6 +738,28 @@ AnimatorState: m_MirrorParameter: m_CycleOffsetParameter: m_TimeParameter: +--- !u!1101 &5560828704810626401 +AnimatorStateTransition: + m_ObjectHideFlags: 1 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_Name: + m_Conditions: [] + m_DstStateMachine: {fileID: 0} + m_DstState: {fileID: 0} + m_Solo: 0 + m_Mute: 0 + m_IsExit: 1 + serializedVersion: 3 + m_TransitionDuration: 0.25 + m_TransitionOffset: 0 + m_ExitTime: 0.9837838 + m_HasExitTime: 1 + m_HasFixedDuration: 1 + m_InterruptionSource: 0 + m_OrderedInterruption: 1 + m_CanTransitionToSelf: 1 --- !u!1107 &5974105379841103025 AnimatorStateMachine: serializedVersion: 6 @@ -881,6 +961,9 @@ AnimatorStateMachine: - serializedVersion: 1 m_State: {fileID: 3852747646935075765} m_Position: {x: 550, y: 470, z: 0} + - serializedVersion: 1 + m_State: {fileID: -3881533873121950449} + m_Position: {x: 550, y: 570, z: 0} m_ChildStateMachines: - serializedVersion: 1 m_StateMachine: {fileID: 5974105379841103025} @@ -889,6 +972,7 @@ AnimatorStateMachine: - {fileID: -1458154305767465992} - {fileID: -6492649378429786868} - {fileID: 367154791439637850} + - {fileID: -2049146169530471879} m_EntryTransitions: [] m_StateMachineTransitions: - first: {fileID: 5974105379841103025} diff --git a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/Singleton.cs b/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/Singleton.cs deleted file mode 100644 index 0c3fd8f..0000000 --- a/Assets/_VoiceAssistant/com.richframe.frame/Runtime/Util/Singleton.cs +++ /dev/null @@ -1,23 +0,0 @@ -using System.Collections; -using System.Collections.Generic; -using UnityEngine; - -/// -/// 单例 -/// -/// -public class Singleton : MonoBehaviour where T : MonoBehaviour -{ - public static T Instance - { - get - { - if (_Instance == null) - { - _Instance = FindObjectOfType(); - } - return _Instance; - } - } - static T _Instance; -} diff --git a/Health.sln b/Health.sln index baf2cf0..35169f6 100644 --- a/Health.sln +++ b/Health.sln @@ -11,14 +11,14 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StompyRobot.SRDebugger", "S EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StompyRobot.SRF", "StompyRobot.SRF.csproj", "{D8E6FCCA-686A-0FF5-1956-9A7EE37839AA}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "com.richframe.frame", "com.richframe.frame.csproj", "{A1452F01-7562-84D8-FEFD-9FC63712C72A}" -EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StompyRobot.SRF.Editor", "StompyRobot.SRF.Editor.csproj", "{90FE4C7C-EB1B-93AA-DA9C-CA7BF2F58D4B}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StompyRobot.SRDebugger.Editor", "StompyRobot.SRDebugger.Editor.csproj", "{D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "com.richframe.frame", "com.richframe.frame.csproj", "{A1452F01-7562-84D8-FEFD-9FC63712C72A}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "com.richframe.test", "com.richframe.test.csproj", "{FE183B87-8612-2E98-8A90-F248AAF50D10}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "StompyRobot.SRDebugger.Editor", "StompyRobot.SRDebugger.Editor.csproj", "{D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}" +EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "EnoxSoftware.OpenCVForUnity.Editor", "EnoxSoftware.OpenCVForUnity.Editor.csproj", "{81B7A7AE-8EC2-866E-0C01-1CE46F30A594}" EndProject Global @@ -47,22 +47,22 @@ Global {D8E6FCCA-686A-0FF5-1956-9A7EE37839AA}.Debug|Any CPU.Build.0 = Debug|Any CPU {D8E6FCCA-686A-0FF5-1956-9A7EE37839AA}.Release|Any CPU.ActiveCfg = Release|Any CPU {D8E6FCCA-686A-0FF5-1956-9A7EE37839AA}.Release|Any CPU.Build.0 = Release|Any CPU - {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Debug|Any CPU.Build.0 = Debug|Any CPU - {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Release|Any CPU.ActiveCfg = Release|Any CPU - {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Release|Any CPU.Build.0 = Release|Any CPU {90FE4C7C-EB1B-93AA-DA9C-CA7BF2F58D4B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {90FE4C7C-EB1B-93AA-DA9C-CA7BF2F58D4B}.Debug|Any CPU.Build.0 = Debug|Any CPU {90FE4C7C-EB1B-93AA-DA9C-CA7BF2F58D4B}.Release|Any CPU.ActiveCfg = Release|Any CPU {90FE4C7C-EB1B-93AA-DA9C-CA7BF2F58D4B}.Release|Any CPU.Build.0 = Release|Any CPU - {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Debug|Any CPU.Build.0 = Debug|Any CPU - {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Release|Any CPU.ActiveCfg = Release|Any CPU - {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Release|Any CPU.Build.0 = Release|Any CPU + {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Debug|Any CPU.Build.0 = Debug|Any CPU + {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Release|Any CPU.ActiveCfg = Release|Any CPU + {A1452F01-7562-84D8-FEFD-9FC63712C72A}.Release|Any CPU.Build.0 = Release|Any CPU {FE183B87-8612-2E98-8A90-F248AAF50D10}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {FE183B87-8612-2E98-8A90-F248AAF50D10}.Debug|Any CPU.Build.0 = Debug|Any CPU {FE183B87-8612-2E98-8A90-F248AAF50D10}.Release|Any CPU.ActiveCfg = Release|Any CPU {FE183B87-8612-2E98-8A90-F248AAF50D10}.Release|Any CPU.Build.0 = Release|Any CPU + {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Debug|Any CPU.Build.0 = Debug|Any CPU + {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Release|Any CPU.ActiveCfg = Release|Any CPU + {D94325F2-C3DE-1CDD-02FC-08D656EC4C7A}.Release|Any CPU.Build.0 = Release|Any CPU {81B7A7AE-8EC2-866E-0C01-1CE46F30A594}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {81B7A7AE-8EC2-866E-0C01-1CE46F30A594}.Debug|Any CPU.Build.0 = Debug|Any CPU {81B7A7AE-8EC2-866E-0C01-1CE46F30A594}.Release|Any CPU.ActiveCfg = Release|Any CPU diff --git a/ProjectSettings/AudioManager.asset b/ProjectSettings/AudioManager.asset index df1e809..582cd09 100644 --- a/ProjectSettings/AudioManager.asset +++ b/ProjectSettings/AudioManager.asset @@ -5,8 +5,8 @@ AudioManager: m_ObjectHideFlags: 0 serializedVersion: 2 m_Volume: 1 - Rolloff Scale: 1 - Doppler Factor: 1 + Rolloff Scale: 0 + Doppler Factor: 0 Default Speaker Mode: 2 m_SampleRate: 0 m_DSPBufferSize: 1024