diff --git a/Assets/Editor/ConvertNormalMaps.cs b/Assets/Editor/ConvertNormalMaps.cs new file mode 100644 index 0000000000..60a802f2e9 --- /dev/null +++ b/Assets/Editor/ConvertNormalMaps.cs @@ -0,0 +1,94 @@ +using UnityEngine; +using UnityEditor; +using System.IO; +using Unity.Collections; + +public static class ConvertNormalMaps +{ + [MenuItem("Open Brush/Toolkit/Convert Bump Maps to Normal Maps")] + static void Convert() + { + foreach (Object obj in Selection.objects) + { + if (obj is Material) + { + Material material = (Material)obj; + Shader shader = material.shader; + int propertiesCount = ShaderUtil.GetPropertyCount(shader); + + for (int j = 0; j < propertiesCount; j++) + { + if (ShaderUtil.GetPropertyType(shader, j) == ShaderUtil.ShaderPropertyType.TexEnv) + { + string propertyName = ShaderUtil.GetPropertyName(shader, j); + Texture texture = material.GetTexture(propertyName); + + if (texture is Texture2D normalMap) + { + string texturePath = AssetDatabase.GetAssetPath(normalMap); + bool isNormal = ReimportTexture(texturePath, true); + if (!isNormal) continue; + Texture2D remappedTexture = new Texture2D(normalMap.width, normalMap.height); + + // Get the pixels from the source texture + NativeArray pixels = normalMap.GetPixelData(0); + + for (int i = 0; i < pixels.Length; i++) + { + byte red = pixels[i].a; + byte green = pixels[i].g; + byte blue = 255; // pixels[i].b; + byte alpha = 255; // pixels[i].r; + pixels[i] = new Color32(red, green, blue, alpha); + } + remappedTexture.SetPixels32(pixels.ToArray()); + + // Apply changes + remappedTexture.Apply(); + + File.WriteAllBytes(texturePath, remappedTexture.EncodeToPNG()); + Debug.Log("Exported Normal Map: " + texturePath); + RemoveConversion(texturePath); + } + else + { + Debug.LogWarning("No normal map found in material: " + material.name); + } + } + } + } + } + AssetDatabase.Refresh(); + } + + private static bool ReimportTexture(string assetPath, bool isReadable) + { + TextureImporter textureImporter = AssetImporter.GetAtPath(assetPath) as TextureImporter; + if (textureImporter != null) + { + if (textureImporter.textureType != TextureImporterType.NormalMap) + { + return false; + } + textureImporter.isReadable = isReadable; + textureImporter.textureCompression = TextureImporterCompression.Uncompressed; + AssetDatabase.ImportAsset(assetPath, ImportAssetOptions.ForceUpdate); + } + return true; + } + + private static bool RemoveConversion(string assetPath) + { + TextureImporter textureImporter = AssetImporter.GetAtPath(assetPath) as TextureImporter; + if (textureImporter != null) + { + if (textureImporter.textureType != TextureImporterType.NormalMap) + { + return false; + } + textureImporter.convertToNormalmap = false; + AssetDatabase.ImportAsset(assetPath, ImportAssetOptions.ForceUpdate); + } + return true; + } +} \ No newline at end of file diff --git a/Assets/Editor/ConvertNormalMaps.cs.meta b/Assets/Editor/ConvertNormalMaps.cs.meta new file mode 100644 index 0000000000..84a89e8cea --- /dev/null +++ b/Assets/Editor/ConvertNormalMaps.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: af50bbcf833642dba919cd889cbd5fea +timeCreated: 1706369730 \ No newline at end of file diff --git a/Assets/Editor/GlTF_EditorExporter.cs b/Assets/Editor/GlTF_EditorExporter.cs index b6b5828096..e80bb9087f 100644 --- a/Assets/Editor/GlTF_EditorExporter.cs +++ b/Assets/Editor/GlTF_EditorExporter.cs @@ -233,7 +233,7 @@ private static int RunCommand(string command, params string[] commandArgs) { System.Diagnostics.Process proc = new System.Diagnostics.Process(); proc.StartInfo = new System.Diagnostics.ProcessStartInfo( - command, string.Join(" ", commandArgs)); + command, string.Join(" ", commandArgs.Select(arg => $"\"{arg}\""))); proc.StartInfo.RedirectStandardOutput = true; proc.StartInfo.RedirectStandardError = true; proc.StartInfo.UseShellExecute = false; diff --git a/Assets/Models/SceneLightCone.obj b/Assets/Models/SceneLightCone.obj new file mode 100644 index 0000000000..446bf5cb6e --- /dev/null +++ b/Assets/Models/SceneLightCone.obj @@ -0,0 +1,103 @@ +# Blender 4.0.2 +# www.blender.org +o Cone +v 0.000000 1.000000 -2.000000 +v 0.195090 0.980785 -2.000000 +v 0.382683 0.923880 -2.000000 +v 0.555570 0.831470 -2.000000 +v 0.707107 0.707107 -2.000000 +v 0.831470 0.555570 -2.000000 +v 0.923880 0.382683 -2.000000 +v 0.980785 0.195090 -2.000000 +v 1.000000 0.000000 -2.000000 +v 0.980785 -0.195090 -2.000000 +v 0.923880 -0.382683 -2.000000 +v 0.831470 -0.555570 -2.000000 +v 0.707107 -0.707107 -2.000000 +v 0.555570 -0.831470 -2.000000 +v 0.382683 -0.923879 -2.000000 +v 0.195090 -0.980785 -2.000000 +v 0.000000 -1.000000 -2.000000 +v -0.195090 -0.980785 -2.000000 +v -0.382683 -0.923879 -2.000000 +v -0.555570 -0.831470 -2.000000 +v -0.707107 -0.707107 -2.000000 +v -0.831470 -0.555570 -2.000000 +v -0.923880 -0.382683 -2.000000 +v -0.980785 -0.195090 -2.000000 +v -1.000000 0.000000 -2.000000 +v -0.980785 0.195090 -2.000000 +v -0.923880 0.382683 -2.000000 +v -0.831470 0.555570 -2.000000 +v -0.707107 0.707107 -2.000000 +v -0.555570 0.831470 -2.000000 +v -0.382683 0.923880 -2.000000 +v -0.195090 0.980785 -2.000000 +v 0.000000 -0.000000 0.000000 +vn 0.0878 0.8910 0.4455 +vn 0.2599 0.8567 0.4455 +vn 0.4220 0.7896 0.4455 +vn 0.5680 0.6921 0.4455 +vn 0.6921 0.5680 0.4455 +vn 0.7896 0.4220 0.4455 +vn 0.8567 0.2599 0.4455 +vn 0.8910 0.0878 0.4455 +vn 0.8910 -0.0878 0.4455 +vn 0.8567 -0.2599 0.4455 +vn 0.7896 -0.4220 0.4455 +vn 0.6921 -0.5680 0.4455 +vn 0.5680 -0.6921 0.4455 +vn 0.4220 -0.7896 0.4455 +vn 0.2599 -0.8567 0.4455 +vn 0.0878 -0.8910 0.4455 +vn -0.0878 -0.8910 0.4455 +vn -0.2599 -0.8567 0.4455 +vn -0.4220 -0.7896 0.4455 +vn -0.5680 -0.6921 0.4455 +vn -0.6921 -0.5680 0.4455 +vn -0.7896 -0.4220 0.4455 +vn -0.8567 -0.2599 0.4455 +vn -0.8910 -0.0878 0.4455 +vn -0.8910 0.0878 0.4455 +vn -0.8567 0.2599 0.4455 +vn -0.7896 0.4220 0.4455 +vn -0.6921 0.5680 0.4455 +vn -0.5680 0.6921 0.4455 +vn -0.4220 0.7896 0.4455 +vn -0.0000 -0.0000 -1.0000 +vn -0.2599 0.8567 0.4455 +vn -0.0878 0.8910 0.4455 +s 0 +f 1//1 33//1 2//1 +f 2//2 33//2 3//2 +f 3//3 33//3 4//3 +f 4//4 33//4 5//4 +f 5//5 33//5 6//5 +f 6//6 33//6 7//6 +f 7//7 33//7 8//7 +f 8//8 33//8 9//8 +f 9//9 33//9 10//9 +f 10//10 33//10 11//10 +f 11//11 33//11 12//11 +f 12//12 33//12 13//12 +f 13//13 33//13 14//13 +f 14//14 33//14 15//14 +f 15//15 33//15 16//15 +f 16//16 33//16 17//16 +f 17//17 33//17 18//17 +f 18//18 33//18 19//18 +f 19//19 33//19 20//19 +f 20//20 33//20 21//20 +f 21//21 33//21 22//21 +f 22//22 33//22 23//22 +f 23//23 33//23 24//23 +f 24//24 33//24 25//24 +f 25//25 33//25 26//25 +f 26//26 33//26 27//26 +f 27//27 33//27 28//27 +f 28//28 33//28 29//28 +f 29//29 33//29 30//29 +f 30//30 33//30 31//30 +f 1//31 2//31 3//31 4//31 5//31 6//31 7//31 8//31 9//31 10//31 11//31 12//31 13//31 14//31 15//31 16//31 17//31 18//31 19//31 20//31 21//31 22//31 23//31 24//31 25//31 26//31 27//31 28//31 29//31 30//31 31//31 32//31 +f 31//32 33//32 32//32 +f 32//33 33//33 1//33 diff --git a/Assets/Models/SceneLightCone.obj.meta b/Assets/Models/SceneLightCone.obj.meta new file mode 100644 index 0000000000..9768a0f4f8 --- /dev/null +++ b/Assets/Models/SceneLightCone.obj.meta @@ -0,0 +1,106 @@ +fileFormatVersion: 2 +guid: e43176c932e39cc4e9f15348aee46bc5 +ModelImporter: + serializedVersion: 21300 + internalIDToNameTable: [] + externalObjects: {} + materials: + materialImportMode: 0 + materialName: 0 + materialSearch: 1 + materialLocation: 1 + animations: + legacyGenerateAnimations: 4 + bakeSimulation: 0 + resampleCurves: 1 + optimizeGameObjects: 0 + removeConstantScaleCurves: 1 + motionNodeName: + rigImportErrors: + rigImportWarnings: + animationImportErrors: + animationImportWarnings: + animationRetargetingWarnings: + animationDoRetargetingWarnings: 0 + importAnimatedCustomProperties: 0 + importConstraints: 0 + animationCompression: 1 + animationRotationError: 0.5 + animationPositionError: 0.5 + animationScaleError: 0.5 + animationWrapMode: 0 + extraExposedTransformPaths: [] + extraUserProperties: [] + clipAnimations: [] + isReadable: 1 + meshes: + lODScreenPercentages: [] + globalScale: 1 + meshCompression: 0 + addColliders: 0 + useSRGBMaterialColor: 1 + sortHierarchyByName: 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 + tangentSpace: + normalSmoothAngle: 60 + normalImportMode: 0 + tangentImportMode: 3 + normalCalculationMode: 4 + legacyComputeAllNormalsFromSmoothingGroupsWhenMeshHasBlendShapes: 0 + blendShapeNormalImportMode: 1 + normalSmoothingSource: 0 + referencedClips: [] + importAnimation: 0 + humanDescription: + serializedVersion: 3 + human: [] + skeleton: [] + 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: 0 + skeletonHasParents: 1 + lastHumanDescriptionAvatarSource: {instanceID: 0} + autoGenerateAvatarMappingIfUnspecified: 1 + animationType: 0 + humanoidOversampling: 1 + avatarSetup: 0 + addHumanoidExtraRootOnlyWhenUsingAvatar: 1 + remapMaterialsIfMaterialImportModeIsNone: 0 + additionalBone: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/BrushBaker.prefab b/Assets/Prefabs/BrushBaker.prefab new file mode 100644 index 0000000000..32afb95d7b --- /dev/null +++ b/Assets/Prefabs/BrushBaker.prefab @@ -0,0 +1,128 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &2530997363061912793 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 167830897998540590} + - component: {fileID: 5059187324052258821} + m_Layer: 0 + m_Name: BrushBaker + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &167830897998540590 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2530997363061912793} + 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: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &5059187324052258821 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 2530997363061912793} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d368cec5bd044465b36255fcc3090a66, type: 3} + m_Name: + m_EditorClassIdentifier: + computeShaders: + - name: Mylar + shader: {fileID: 4800000, guid: 073d6ba13e511e24bb3ba4f7c8f744ee, type: 3} + brushGuid: 8e58ceea-7830-49b4-aba9-6215104ab52a + computeShader: {fileID: 7200000, guid: a8cd83718b2e48db9570f9195dfde315, type: 3} + - name: Double Tapered Flat + shader: {fileID: 4800000, guid: 4496a9baf3f2fc446bbaff38336003df, type: 3} + brushGuid: 0d3889f3-3ede-470c-8af4-f44813306126 + computeShader: {fileID: 7200000, guid: 67c631d4aac299f4bbaad06dd830312e, type: 3} + - name: Double Tapered Marker + shader: {fileID: 4800000, guid: e412fb1c98a347b4ab08429cbf1d0894, type: 3} + brushGuid: 0d3889f3-3ede-470c-8af4-de4813306126 + computeShader: {fileID: 7200000, guid: 67c631d4aac299f4bbaad06dd830312e, type: 3} + - name: Dots + shader: {fileID: 4800000, guid: 732f16cce31764a49a67b2c782bf444a, type: 3} + brushGuid: 6a1cf9f9-032c-45ec-9b1d-a6680bee30f7 + computeShader: {fileID: 7200000, guid: 2daa4d77d81adc84a88e67f8a7b22ac8, type: 3} + - name: Embers + shader: {fileID: 4800000, guid: f62b84c7d6bc5f24487edcd3a458ce88, type: 3} + brushGuid: 02ffb866-7fb2-4d15-b761-1012cefb1360 + computeShader: {fileID: 7200000, guid: df2047dd556be4d47ba22aba4f71c0f5, type: 3} + - name: Bubbles + shader: {fileID: 4800000, guid: ecfbf36005cdcc94d881047728719bd8, type: 3} + brushGuid: 89d104cd-d012-426b-b5b3-bbaee63ac43c + computeShader: {fileID: 7200000, guid: bbd51e4e329047f439104cbc04383597, type: 3} + - name: Snow + shader: {fileID: 4800000, guid: 731f18bedecafd24f8a663a28a1e1b42, type: 3} + brushGuid: d902ed8b-d0d1-476c-a8de-878a79e3a34c + computeShader: {fileID: 7200000, guid: c7771aa61c3be544eae35185c59c39c4, type: 3} + - name: Stars + shader: {fileID: 4800000, guid: c5ccca3779289ff49a2768609995604b, type: 3} + brushGuid: 0eb4db27-3f82-408d-b5a1-19ebd7d5b711 + computeShader: {fileID: 7200000, guid: 88c0f5ccf81e44249b28909e1a12e099, type: 3} + - name: Smoke + shader: {fileID: 4800000, guid: b00f8a3e2356b6144b32fe4a62905a7b, type: 3} + brushGuid: 70d79cca-b159-4f35-990c-f02193947fe8 + computeShader: {fileID: 7200000, guid: ed79d827aabdf284f96a5bac36a050ba, type: 3} + - name: Rising Bubbles + shader: {fileID: 4800000, guid: c4285dcf87bf5b84d8d4bbec752f1883, type: 3} + brushGuid: a8147ce1-005e-abe4-88e8-09a1eaadcc89 + computeShader: {fileID: 7200000, guid: d5d5ade2144b877458cb85b63f87db45, type: 3} + - name: LightWire + shader: {fileID: 4800000, guid: 3b4cc34a39a839049b4387ce42e3b56c, type: 3} + brushGuid: 4391aaaa-df81-4396-9e33-31e4e4930b27 + computeShader: {fileID: 7200000, guid: f1766ed0ee9b8634d9ad77ef8ec34e0d, type: 3} + - name: Disco + shader: {fileID: 4800000, guid: 2d606fd47b43446739974645ed823957, type: 3} + brushGuid: 4391aaaa-df73-4396-9e33-31e4e4930b27 + computeShader: {fileID: 7200000, guid: 612bca9f4c2f46e4da8c23150c4fcac5, type: 3} + - name: Electricity + shader: {fileID: 4800000, guid: 698f6f8dc012a8b4e9d6f36db04f0dd3, type: 3} + brushGuid: f6e85de3-6dcc-4e7f-87fd-cee8c3d25d51 + computeShader: {fileID: 7200000, guid: 94bcafbff8d69c044a155b7a7254904b, type: 3} + - name: HyperGrid + shader: {fileID: 4800000, guid: a2fa29912c23a774898a1b8b236ed79d, type: 3} + brushGuid: 6a1cf9f9-032c-45ec-9b6e-a6680bee32e9 + computeShader: {fileID: 7200000, guid: cfa508c5ac021eb4484efcd508d86f28, type: 3} + - name: Sparks + shader: {fileID: 4800000, guid: f10b4ff7ab4b8bc49b4cabd89f56378f, type: 3} + brushGuid: 50e99447-3861-05f4-697d-a1b96e771b98 + computeShader: {fileID: 7200000, guid: 95faa217ff7d8694fafbe2851266042a, type: 3} + - name: BubbleWand + shader: {fileID: 4800000, guid: 0291fdb46401c4826bc02d7ec6d76cbb, type: 3} + brushGuid: EBA3F993-F9A1-4D35-B84E-BB08F48981A4 + computeShader: {fileID: 7200000, guid: 81ca801fea8092f41be21fb73d2f30d4, type: 3} + - name: DanceFloor + shader: {fileID: 4800000, guid: 14968e66fc8cfe441b31a7c23a07897c, type: 3} + brushGuid: 6a1cf9f9-032c-45ec-311e-a6680bee32e9 + computeShader: {fileID: 7200000, guid: db29274d68efa2048a8c96cb6cac4f90, type: 3} + - name: KeijiroTube + shader: {fileID: 4800000, guid: 54cf55a2c62eff1458edd3f1e68d0f0a, type: 3} + brushGuid: f8ba3d18-01fc-4d7b-b2d9-b99d10b8e7cf + computeShader: {fileID: 7200000, guid: 7aaef9828dec8e745a7078f169541071, type: 3} + - name: WaveformParticles + shader: {fileID: 4800000, guid: e12e59eb54a018044abc88e7ccf3d195, type: 3} + brushGuid: 6a1cf9f9-032c-45ec-9b6e-a6680bee30f7 + computeShader: {fileID: 7200000, guid: a79673b84c7f0ce4cac3f2d9d312b765, type: 3} + - name: Rain + shader: {fileID: 4800000, guid: a7b2cc37e7b92574483d5e8e4d08ecb7, type: 3} + brushGuid: 03a529e1-f519-3dd4-582d-2d5cd92c3f4f + computeShader: {fileID: 7200000, guid: 177e3315ef9abb4419da277431781388, type: 3} + squeezeAmount: 0.873 diff --git a/Assets/Prefabs/BrushBaker.prefab.meta b/Assets/Prefabs/BrushBaker.prefab.meta new file mode 100644 index 0000000000..a69c599814 --- /dev/null +++ b/Assets/Prefabs/BrushBaker.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: cb0a1a7968495024690ad9a1c0d38548 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/LightWidget.prefab b/Assets/Prefabs/LightWidget.prefab new file mode 100644 index 0000000000..5e7c3704c9 --- /dev/null +++ b/Assets/Prefabs/LightWidget.prefab @@ -0,0 +1,288 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &104792 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 413480} + - component: {fileID: 11466202} + m_Layer: 0 + m_Name: LightWidget + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &413480 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 104792} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 2.146, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 435884} + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &11466202 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 104792} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 9e25501290d544bfb149945101d12d6e, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ShowDuration: 0.2 + m_GrabDistance: 1 + m_CollisionRadius: 1.2 + m_AllowTwoHandGrab: 1 + m_DestroyOnHide: 0 + m_AllowHideWithToss: 1 + m_DisableDrift: 0 + m_RecordMovements: 1 + m_AllowSnapping: 1 + m_SnapDisabledDelay: 0.2 + m_AllowPinning: 1 + m_AllowDormancy: 1 + m_TossDuration: 0.25 + m_TintableMeshes: [] + m_SpawnPlacementOffset: {x: 0, y: 0, z: 0} + m_IntroAnimSpinAmount: 360 + m_BoxCollider: {fileID: 0} + m_Mesh: {fileID: 0} + m_HighlightMeshXfs: [] + m_ValidSnapRotationStickyAngle: 65 + m_SnapGhostMaterial: {fileID: 2100000, guid: 43172d360a2f0f44798d94e9c440e24b, type: 2} + m_SelectionIndicatorRenderer: {fileID: 0} + m_ContainerBloat: {x: 0, y: 0, z: 0.4} + m_UngrabbableFromInside: 0 + m_MinSize_CS: 0.05 + m_MaxSize_CS: 2000 +--- !u!1 &114356 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 435884} + m_Layer: 18 + m_Name: Missing + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &435884 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 114356} + 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: 433034} + - {fileID: 478790} + m_Father: {fileID: 413480} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &149674 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 478790} + - component: {fileID: 3322804} + - component: {fileID: 2375594} + m_Layer: 18 + m_Name: QuestionMark + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &478790 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 149674} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -0.011} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 435884} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &3322804 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 149674} + m_Mesh: {fileID: 10210, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &2375594 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 149674} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: fcfcb94554ebd814aa6f067fe1cba536, 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!1 &173606 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 433034} + - component: {fileID: 2352122} + - component: {fileID: 10267632} + m_Layer: 18 + m_Name: Text + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &433034 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 173606} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -0.011} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 435884} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!23 &2352122 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 173606} + m_Enabled: 0 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 10100, guid: 0000000000000000e000000000000000, type: 0} + 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!102 &10267632 +TextMesh: + serializedVersion: 3 + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 173606} + m_Text: 'Missing Image: + + file.png' + m_OffsetZ: 0 + m_CharacterSize: 0.05 + m_LineSpacing: 1 + m_Anchor: 4 + m_Alignment: 1 + m_TabSize: 4 + m_FontSize: 20 + m_FontStyle: 0 + m_RichText: 1 + m_Font: {fileID: 0} + m_Color: + serializedVersion: 2 + rgba: 4294967295 diff --git a/Assets/Prefabs/LightWidget.prefab.meta b/Assets/Prefabs/LightWidget.prefab.meta new file mode 100644 index 0000000000..40adfe7cdf --- /dev/null +++ b/Assets/Prefabs/LightWidget.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e061cff5394e32940bb00495b287bb38 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Prefabs/ModelWidget.prefab b/Assets/Prefabs/ModelWidget.prefab index a383c0c006..c2ab1e0f54 100644 --- a/Assets/Prefabs/ModelWidget.prefab +++ b/Assets/Prefabs/ModelWidget.prefab @@ -27,6 +27,7 @@ Transform: m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: -5.8055434, y: 18.56388, z: -6.6038275} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: - {fileID: 410718} - {fileID: 421666} @@ -74,6 +75,8 @@ MonoBehaviour: m_MaxSize_CS: 5000 m_MinContainerRatio: 0.1 m_MaxBloat: 4 + m_SceneLightGizmo: {fileID: 6544834572293484432, guid: f28bfd6efbf3cb046be485c6573ca207, + type: 3} --- !u!1 &108072 GameObject: m_ObjectHideFlags: 0 @@ -102,6 +105,7 @@ Transform: 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: 421666} m_RootOrder: 0 @@ -125,9 +129,12 @@ MeshRenderer: m_CastShadows: 0 m_ReceiveShadows: 0 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 m_RenderingLayerMask: 1 m_RendererPriority: 0 m_Materials: @@ -139,6 +146,7 @@ MeshRenderer: m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 + m_ReceiveGI: 1 m_PreserveUVs: 1 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 @@ -151,6 +159,7 @@ MeshRenderer: m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} --- !u!1 &113492 GameObject: m_ObjectHideFlags: 0 @@ -178,6 +187,7 @@ Transform: 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: 473572} m_Father: {fileID: 413480} @@ -225,6 +235,7 @@ RectTransform: m_LocalRotation: {x: 0, y: 1, z: 0, w: -0.00000016292068} m_LocalPosition: {x: 0, y: 0, z: 0.1} m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 410718} m_RootOrder: 0 @@ -245,9 +256,12 @@ MeshRenderer: m_CastShadows: 0 m_ReceiveShadows: 0 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 m_RenderingLayerMask: 1 m_RendererPriority: 0 m_Materials: @@ -259,6 +273,7 @@ MeshRenderer: m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 + m_ReceiveGI: 1 m_PreserveUVs: 0 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 @@ -271,6 +286,7 @@ MeshRenderer: m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} --- !u!33 &3309324 MeshFilter: m_ObjectHideFlags: 0 @@ -294,11 +310,11 @@ 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: m_Calls: [] - m_TypeName: UnityEngine.UI.MaskableGraphic+CullStateChangedEvent, UnityEngine.UI, - Version=1.0.0.0, Culture=neutral, PublicKeyToken=null m_text: Missing Model m_isRightToLeft: 0 m_fontAsset: {fileID: 11400000, guid: fce54057bad3d2d4cb3c36ee394be518, type: 2} @@ -311,6 +327,7 @@ MonoBehaviour: rgba: 4294967295 m_fontColor: {r: 1, g: 1, b: 1, a: 1} m_enableVertexGradient: 0 + m_colorMode: 3 m_fontColorGradient: topLeft: {r: 1, g: 1, b: 1, a: 1} topRight: {r: 1, g: 1, b: 1, a: 1} @@ -319,13 +336,12 @@ MonoBehaviour: m_fontColorGradientPreset: {fileID: 0} m_spriteAsset: {fileID: 0} m_tintAllSprites: 0 + m_StyleSheet: {fileID: 0} + m_TextStyleHashCode: 0 m_overrideHtmlColors: 0 m_faceColor: serializedVersion: 2 rgba: 4294967295 - m_outlineColor: - serializedVersion: 2 - rgba: 4278190080 m_fontSize: 3 m_fontSizeBase: 3 m_fontWeight: 400 @@ -333,8 +349,9 @@ MonoBehaviour: m_fontSizeMin: 18 m_fontSizeMax: 72 m_fontStyle: 0 + m_HorizontalAlignment: 1 + m_VerticalAlignment: 256 m_textAlignment: 1 - m_isAlignmentEnumConverted: 0 m_characterSpacing: 0 m_wordSpacing: 0 m_lineSpacing: 0 @@ -344,9 +361,8 @@ MonoBehaviour: m_enableWordWrapping: 1 m_wordWrappingRatios: 0.4 m_overflowMode: 0 - m_firstOverflowCharacterIndex: -1 m_linkedTextComponent: {fileID: 0} - m_isLinkedTextComponent: 0 + parentLinkedComponent: {fileID: 0} m_enableKerning: 1 m_enableExtraPadding: 0 checkPaddingRequired: 1 @@ -354,43 +370,22 @@ MonoBehaviour: m_parseCtrlCharacters: 1 m_isOrthographic: 0 m_isCullingEnabled: 0 - m_ignoreRectMaskCulling: 0 - m_ignoreCulling: 1 m_horizontalMapping: 0 m_verticalMapping: 0 m_uvLineOffset: 0 m_geometrySortingOrder: 0 - m_firstVisibleCharacter: 0 + m_IsTextObjectScaleStatic: 0 + m_VertexBufferAutoSizeReduction: 0 m_useMaxVisibleDescender: 1 m_pageToDisplay: 1 m_margin: {x: 0, y: 0, z: 0, w: 0} - m_textInfo: - textComponent: {fileID: 0} - characterCount: 0 - spriteCount: 0 - spaceCount: 0 - wordCount: 0 - linkCount: 0 - lineCount: 0 - pageCount: 0 - materialCount: 0 - m_havePropertiesChanged: 1 m_isUsingLegacyAnimationComponent: 0 m_isVolumetricText: 0 - m_spriteAnimator: {fileID: 0} - m_isInputParsingRequired: 1 - m_inputSource: 0 + _SortingLayer: 0 + _SortingLayerID: 0 + _SortingOrder: 0 m_hasFontAssetChanged: 0 m_renderer: {fileID: 2306418} - m_subTextObjects: - - {fileID: 0} - - {fileID: 0} - - {fileID: 0} - - {fileID: 0} - - {fileID: 0} - - {fileID: 0} - - {fileID: 0} - - {fileID: 0} m_maskType: 0 --- !u!1 &186286 GameObject: @@ -418,6 +413,7 @@ Transform: 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: 22416866} - {fileID: 444552} @@ -452,6 +448,7 @@ Transform: m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} m_LocalPosition: {x: 0, y: 0.5, z: 0.05} m_LocalScale: {x: 2.5, y: 2.5, z: 2.5} + m_ConstrainProportionsScale: 0 m_Children: [] m_Father: {fileID: 410718} m_RootOrder: 1 @@ -475,9 +472,12 @@ MeshRenderer: m_CastShadows: 0 m_ReceiveShadows: 0 m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 m_MotionVectors: 1 m_LightProbeUsage: 1 m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 m_RenderingLayerMask: 1 m_RendererPriority: 0 m_Materials: @@ -489,6 +489,7 @@ MeshRenderer: m_ProbeAnchor: {fileID: 0} m_LightProbeVolumeOverride: {fileID: 0} m_ScaleInLightmap: 1 + m_ReceiveGI: 1 m_PreserveUVs: 0 m_IgnoreNormalsForChartDetection: 0 m_ImportantGI: 0 @@ -501,3 +502,4 @@ MeshRenderer: m_SortingLayerID: 0 m_SortingLayer: 0 m_SortingOrder: 0 + m_AdditionalVertexStreams: {fileID: 0} diff --git a/Assets/Prefabs/SceneLightGizmo.prefab b/Assets/Prefabs/SceneLightGizmo.prefab new file mode 100644 index 0000000000..a92da4610c --- /dev/null +++ b/Assets/Prefabs/SceneLightGizmo.prefab @@ -0,0 +1,726 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!1 &227534067517633913 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3984815595832274732} + - component: {fileID: 4937434955253523706} + - component: {fileID: 8152133190199139702} + - component: {fileID: 3588559030059955323} + m_Layer: 5 + m_Name: Cylinder + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &3984815595832274732 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 227534067517633913} + m_LocalRotation: {x: 0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalPosition: {x: 0, y: 0, z: 1} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 6544834572293484432} + m_RootOrder: 4 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!33 &4937434955253523706 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 227534067517633913} + m_Mesh: {fileID: 10206, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &8152133190199139702 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 227534067517633913} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 43172d360a2f0f44798d94e9c440e24b, 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: 1 + 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!65 &3588559030059955323 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 227534067517633913} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1.0000001, y: 2.0000005, z: 1.0000005} + m_Center: {x: 0.000000059604645, y: 0, z: -0.00000008940699} +--- !u!1 &3260137040905130980 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 6806151281215145714} + - component: {fileID: 4840591824128894572} + - component: {fileID: 8007561655143450726} + - component: {fileID: 8609456473538563090} + m_Layer: 5 + m_Name: Disc + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &6806151281215145714 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3260137040905130980} + 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: 6544834572293484432} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 90, y: 0, z: 0} +--- !u!33 &4840591824128894572 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3260137040905130980} + m_Mesh: {fileID: 4300000, guid: bc324ad4a3122f049abaacc87115b660, type: 3} +--- !u!23 &8007561655143450726 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3260137040905130980} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 43172d360a2f0f44798d94e9c440e24b, 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: 1 + 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!65 &8609456473538563090 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3260137040905130980} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 2, y: 2, z: 0.01} + m_Center: {x: 0, y: 0, z: -0.005} +--- !u!1 &3304568507484320585 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 3304568507484352361} + - component: {fileID: 3304568507487252297} + - component: {fileID: 3304568507486252425} + - component: {fileID: 7028555633448640744} + m_Layer: 5 + m_Name: Cone + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &3304568507484352361 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3304568507484320585} + m_LocalRotation: {x: -1, y: -0, z: -0, w: 0} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 6544834572293484432} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} +--- !u!33 &3304568507487252297 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3304568507484320585} + m_Mesh: {fileID: -2432090755550338912, guid: e43176c932e39cc4e9f15348aee46bc5, type: 3} +--- !u!23 &3304568507486252425 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3304568507484320585} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 43172d360a2f0f44798d94e9c440e24b, 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: 1 + 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!65 &7028555633448640744 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 3304568507484320585} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 2, y: 2, z: 2} + m_Center: {x: 0, y: 0, z: -1} +--- !u!1 &7286680547921827011 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7283100317033263399} + - component: {fileID: 7307597878368003501} + - component: {fileID: 7299568328302993421} + m_Layer: 5 + m_Name: Rays + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7283100317033263399 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680547921827011} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0.014234543, z: -0.058} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 7283100319867345441} + m_RootOrder: 1 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &7307597878368003501 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680547921827011} + m_Mesh: {fileID: 4300000, guid: a35723c1804442142a017d3924ba7ef2, type: 3} +--- !u!23 &7299568328302993421 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680547921827011} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 84f6b50a8cb11b3449f9dc0bfe53b439, 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!1 &7286680548473993419 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7283100317131260687} + - component: {fileID: 7307597880339878091} + - component: {fileID: 7299568327413363583} + m_Layer: 5 + m_Name: Arrow + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7283100317131260687 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548473993419} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0.125} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 7283100319867345441} + m_RootOrder: 2 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &7307597880339878091 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548473993419} + m_Mesh: {fileID: 4300004, guid: ef544b9123fcfad40a80fff600625738, type: 3} +--- !u!23 &7299568327413363583 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548473993419} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 84f6b50a8cb11b3449f9dc0bfe53b439, 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!1 &7286680548654881655 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7283100320160541949} + - component: {fileID: 7307597878358308493} + - component: {fileID: 7299568329705981379} + m_Layer: 5 + m_Name: Bulb + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7283100320160541949 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548654881655} + m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: -0.053} + m_LocalScale: {x: 1, y: 1, z: 1} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 7283100319867345441} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!33 &7307597878358308493 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548654881655} + m_Mesh: {fileID: 4300006, guid: ef544b9123fcfad40a80fff600625738, type: 3} +--- !u!23 &7299568329705981379 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548654881655} + m_Enabled: 1 + m_CastShadows: 0 + m_ReceiveShadows: 0 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: d50a0f758579fb844b2b9fc0da5febe7, 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!1 &7286680548782823497 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 7283100319867345441} + m_Layer: 5 + m_Name: Icon + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &7283100319867345441 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 7286680548782823497} + m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} + m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalScale: {x: 0.7, y: 0.7, z: 0.7} + m_ConstrainProportionsScale: 0 + m_Children: + - {fileID: 7283100320160541949} + - {fileID: 7283100317033263399} + - {fileID: 7283100317131260687} + m_Father: {fileID: 6544834572293484432} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!1 &8258460353034129754 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 6544834572293484432} + - component: {fileID: 1712584378369130260} + m_Layer: 5 + m_Name: SceneLightGizmo + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 1 +--- !u!4 &6544834572293484432 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8258460353034129754} + 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: 7283100319867345441} + - {fileID: 3304568507484352361} + - {fileID: 6806151281215145714} + - {fileID: 1359379475829431086} + - {fileID: 3984815595832274732} + m_Father: {fileID: 0} + m_RootOrder: 0 + m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} +--- !u!114 &1712584378369130260 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8258460353034129754} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 21fca40525754f4582e7c9846669adb2, type: 3} + m_Name: + m_EditorClassIdentifier: + m_ConeMesh: {fileID: 3304568507484352361} + m_SphereMesh: {fileID: 1359379475829431086} + m_CylinderMesh: {fileID: 3984815595832274732} + m_Icon: {fileID: 7283100319867345441} +--- !u!1 &8969376719368318966 +GameObject: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + serializedVersion: 6 + m_Component: + - component: {fileID: 1359379475829431086} + - component: {fileID: 7064209086560615380} + - component: {fileID: 9101521164758966731} + - component: {fileID: 989251878098191412} + m_Layer: 5 + m_Name: Sphere + m_TagString: Untagged + m_Icon: {fileID: 0} + m_NavMeshLayer: 0 + m_StaticEditorFlags: 0 + m_IsActive: 0 +--- !u!4 &1359379475829431086 +Transform: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8969376719368318966} + m_LocalRotation: {x: -0.7071068, y: 0, z: 0, w: 0.7071068} + m_LocalPosition: {x: 0, y: -0.002, z: -0} + m_LocalScale: {x: 2, y: 2, z: 2} + m_ConstrainProportionsScale: 0 + m_Children: [] + m_Father: {fileID: 6544834572293484432} + m_RootOrder: 3 + m_LocalEulerAnglesHint: {x: -90, y: 0, z: 0} +--- !u!33 &7064209086560615380 +MeshFilter: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8969376719368318966} + m_Mesh: {fileID: 10207, guid: 0000000000000000e000000000000000, type: 0} +--- !u!23 &9101521164758966731 +MeshRenderer: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8969376719368318966} + m_Enabled: 1 + m_CastShadows: 1 + m_ReceiveShadows: 1 + m_DynamicOccludee: 1 + m_StaticShadowCaster: 0 + m_MotionVectors: 1 + m_LightProbeUsage: 1 + m_ReflectionProbeUsage: 1 + m_RayTracingMode: 2 + m_RayTraceProcedural: 0 + m_RenderingLayerMask: 1 + m_RendererPriority: 0 + m_Materials: + - {fileID: 2100000, guid: 43172d360a2f0f44798d94e9c440e24b, 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: 1 + 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!65 &989251878098191412 +BoxCollider: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 8969376719368318966} + m_Material: {fileID: 0} + m_IsTrigger: 0 + m_Enabled: 1 + serializedVersion: 2 + m_Size: {x: 1, y: 1.0000002, z: 1.0000002} + m_Center: {x: 0, y: 0, z: 0} diff --git a/Assets/Prefabs/SceneLightGizmo.prefab.meta b/Assets/Prefabs/SceneLightGizmo.prefab.meta new file mode 100644 index 0000000000..6605b1b009 --- /dev/null +++ b/Assets/Prefabs/SceneLightGizmo.prefab.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: f28bfd6efbf3cb046be485c6573ca207 +PrefabImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/Brushes/Basic/Bubbles/Bubbles.asset b/Assets/Resources/Brushes/Basic/Bubbles/Bubbles.asset index 08201d827b..d6b8038dfc 100644 --- a/Assets/Resources/Brushes/Basic/Bubbles/Bubbles.asset +++ b/Assets/Resources/Brushes/Basic/Bubbles/Bubbles.asset @@ -26,7 +26,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: a59fca343a215574999d575e84cf4769, type: 3} - m_Description: BRUSH_BUBBLES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -72,7 +71,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/CelVinyl/CelVinyl.asset b/Assets/Resources/Brushes/Basic/CelVinyl/CelVinyl.asset index b8416663a8..cee3222cc1 100644 --- a/Assets/Resources/Brushes/Basic/CelVinyl/CelVinyl.asset +++ b/Assets/Resources/Brushes/Basic/CelVinyl/CelVinyl.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 790f53d255df3e94fa92a897e7d998e4, type: 3} - m_Description: BRUSH_CELVINYL m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/ChromaticWave/ChromaticWave.asset b/Assets/Resources/Brushes/Basic/ChromaticWave/ChromaticWave.asset index 847f3f8a25..ea9d6d70a3 100644 --- a/Assets/Resources/Brushes/Basic/ChromaticWave/ChromaticWave.asset +++ b/Assets/Resources/Brushes/Basic/ChromaticWave/ChromaticWave.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: f27bc47b4f0005e49ad1f9e57952a294, type: 3} - m_Description: BRUSH_CHROMATICWAVE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 1 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristles.asset b/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristles.asset index 4fdcecb018..89496d1ef4 100644 --- a/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristles.asset +++ b/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristles.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 491ce00afea904f4e83a83267ec30c5a, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: 845c3308efec6274f979c40fd5232709, type: 3} - m_Description: BRUSH_COARSEBRISTLES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristlesSingleSided.asset b/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristlesSingleSided.asset index f7607083c9..38fcabd4a5 100644 --- a/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristlesSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/CoarseBristles/CoarseBristlesSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 845c3308efec6274f979c40fd5232709, type: 3} - m_Description: BRUSH_COARSEBRISTLES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Comet/Comet.asset b/Assets/Resources/Brushes/Basic/Comet/Comet.asset index 58ccc70ab7..3341b591a4 100644 --- a/Assets/Resources/Brushes/Basic/Comet/Comet.asset +++ b/Assets/Resources/Brushes/Basic/Comet/Comet.asset @@ -26,7 +26,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: dec2b8d1ad427d84db576791a6608dfc, type: 3} - m_Description: BRUSH_COMET m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -72,7 +71,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DanceFloor/DanceFloor.asset b/Assets/Resources/Brushes/Basic/DanceFloor/DanceFloor.asset index 496d3109ff..28c4b84ae3 100644 --- a/Assets/Resources/Brushes/Basic/DanceFloor/DanceFloor.asset +++ b/Assets/Resources/Brushes/Basic/DanceFloor/DanceFloor.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: f3d935b42c8fc0b4c83b41ef446002fa, type: 3} - m_Description: BRUSH_DANCEFLOOR m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DiamondHull/DiamondHull.asset b/Assets/Resources/Brushes/Basic/DiamondHull/DiamondHull.asset index 8c5ab2d8b4..fa2096eb33 100644 --- a/Assets/Resources/Brushes/Basic/DiamondHull/DiamondHull.asset +++ b/Assets/Resources/Brushes/Basic/DiamondHull/DiamondHull.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: d6681ae7742bb62499aacdcbeb246bd9, type: 3} - m_Description: BRUSH_DIAMOND m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 1 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DotMarker/DotMarker.asset b/Assets/Resources/Brushes/Basic/DotMarker/DotMarker.asset index 125bb7b631..c7263aba23 100644 --- a/Assets/Resources/Brushes/Basic/DotMarker/DotMarker.asset +++ b/Assets/Resources/Brushes/Basic/DotMarker/DotMarker.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 908e6cb2410cac845b4401855e9e0e28, type: 3} - m_Description: BRUSH_DOTMARKER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Dots/Dots.asset b/Assets/Resources/Brushes/Basic/Dots/Dots.asset index 4eeafd0c7a..afd8b7c058 100644 --- a/Assets/Resources/Brushes/Basic/Dots/Dots.asset +++ b/Assets/Resources/Brushes/Basic/Dots/Dots.asset @@ -28,7 +28,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 56970a2bf45d3e2409eb173126801e05, type: 3} - m_Description: BRUSH_DOTS m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -74,7 +73,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DoubleTaperedFlat/DoubleTaperedFlat.asset b/Assets/Resources/Brushes/Basic/DoubleTaperedFlat/DoubleTaperedFlat.asset index 22181d8e0a..8c4dc8b03c 100644 --- a/Assets/Resources/Brushes/Basic/DoubleTaperedFlat/DoubleTaperedFlat.asset +++ b/Assets/Resources/Brushes/Basic/DoubleTaperedFlat/DoubleTaperedFlat.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: c0474dfa491aaf14b8b201edb16d75c4, type: 3} - m_Description: BRUSH_PINCHEDFLAT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 1 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DoubleTaperedMarker/DoubleTaperedMarker.asset b/Assets/Resources/Brushes/Basic/DoubleTaperedMarker/DoubleTaperedMarker.asset index a713fec962..373b155be8 100644 --- a/Assets/Resources/Brushes/Basic/DoubleTaperedMarker/DoubleTaperedMarker.asset +++ b/Assets/Resources/Brushes/Basic/DoubleTaperedMarker/DoubleTaperedMarker.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: f4b62478e1061ef4387d29ff8bc81781, type: 3} - m_Description: BRUSH_PINCHEDMARKER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 1 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DuctTape/DuctTape.asset b/Assets/Resources/Brushes/Basic/DuctTape/DuctTape.asset index 19ee675e9f..35b322f300 100644 --- a/Assets/Resources/Brushes/Basic/DuctTape/DuctTape.asset +++ b/Assets/Resources/Brushes/Basic/DuctTape/DuctTape.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: e853bc8fe41bf9d4cacbf15f1239a2b0, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: 987b425505fd9904c864627f4de6b625, type: 3} - m_Description: BRUSH_DUCTTAPE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DuctTape/DuctTapeSingleSided.asset b/Assets/Resources/Brushes/Basic/DuctTape/DuctTapeSingleSided.asset index 3605511f58..42427d0cdd 100644 --- a/Assets/Resources/Brushes/Basic/DuctTape/DuctTapeSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/DuctTape/DuctTapeSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 987b425505fd9904c864627f4de6b625, type: 3} - m_Description: BRUSH_DUCTTAPE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/DuctTape/normal.png b/Assets/Resources/Brushes/Basic/DuctTape/normal.png index e4745033c2..c83010b40c 100644 Binary files a/Assets/Resources/Brushes/Basic/DuctTape/normal.png and b/Assets/Resources/Brushes/Basic/DuctTape/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/DuctTape/normal.png.meta b/Assets/Resources/Brushes/Basic/DuctTape/normal.png.meta index cc5682a900..bb2a02b001 100644 --- a/Assets/Resources/Brushes/Basic/DuctTape/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/DuctTape/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 23192df5929e8904ba29a31ec2c68e46 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.011 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,9 +33,9 @@ TextureImporter: maxTextureSize: 512 textureSettings: serializedVersion: 2 - filterMode: -1 + filterMode: 2 aniso: 4 - mipBias: -100 + mipBias: 0 wrapU: 0 wrapV: 0 wrapW: 0 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 512 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 512 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 512 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 512 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 512 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Electricity/Electricity.asset b/Assets/Resources/Brushes/Basic/Electricity/Electricity.asset index aa78f4075e..42c5facf84 100644 --- a/Assets/Resources/Brushes/Basic/Electricity/Electricity.asset +++ b/Assets/Resources/Brushes/Basic/Electricity/Electricity.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 4c5312dd65489c04e821db0e7f6e50cf, type: 3} - m_Description: BRUSH_ELECTRICITY m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 1 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Embers/Embers.asset b/Assets/Resources/Brushes/Basic/Embers/Embers.asset index 7e12f7503a..1dc4de7385 100644 --- a/Assets/Resources/Brushes/Basic/Embers/Embers.asset +++ b/Assets/Resources/Brushes/Basic/Embers/Embers.asset @@ -27,7 +27,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: f73a16644bc3f564fa5f3e0b87b6c435, type: 3} - m_Description: BRUSH_EMBERS m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -73,7 +72,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0.63 diff --git a/Assets/Resources/Brushes/Basic/FacetedTube/FacetedTube.asset b/Assets/Resources/Brushes/Basic/FacetedTube/FacetedTube.asset index f532a84840..0b08d16230 100644 --- a/Assets/Resources/Brushes/Basic/FacetedTube/FacetedTube.asset +++ b/Assets/Resources/Brushes/Basic/FacetedTube/FacetedTube.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 3d58509c6afad4668a3365c30f7562f1, type: 3} - m_Description: BRUSH_FACETEDTUBE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 diff --git a/Assets/Resources/Brushes/Basic/Felt/normal.png b/Assets/Resources/Brushes/Basic/Felt/normal.png index 02d1ca1491..7cacbd6e60 100644 Binary files a/Assets/Resources/Brushes/Basic/Felt/normal.png and b/Assets/Resources/Brushes/Basic/Felt/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/Felt/normal.png.meta b/Assets/Resources/Brushes/Basic/Felt/normal.png.meta index af724b5fa2..fe28043970 100644 --- a/Assets/Resources/Brushes/Basic/Felt/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/Felt/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 20d359c06a9a9f644a99fd8ba2b37d94 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.018 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,9 +33,9 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 + filterMode: 2 aniso: 4 - mipBias: -100 + mipBias: 0 wrapU: 0 wrapV: 0 wrapW: 0 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Fire/Fire.asset b/Assets/Resources/Brushes/Basic/Fire/Fire.asset index 87c39de007..a0d33f2c9e 100644 --- a/Assets/Resources/Brushes/Basic/Fire/Fire.asset +++ b/Assets/Resources/Brushes/Basic/Fire/Fire.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 0d0b8a5b978c94841905671944dac51e, type: 3} - m_Description: BRUSH_FIRE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Flat/Flat.asset b/Assets/Resources/Brushes/Basic/Flat/Flat.asset index a629d18e1a..a2dba1fb74 100644 --- a/Assets/Resources/Brushes/Basic/Flat/Flat.asset +++ b/Assets/Resources/Brushes/Basic/Flat/Flat.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 9c9fdb9e65c5dc2458d2db5ca8183471, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: de0f4d89c1f1e8643a83ccc3ec66c965, type: 3} - m_Description: BRUSH_FLAT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -57,7 +56,7 @@ MonoBehaviour: m_Opacity: 1 m_PressureOpacityRange: {x: 1, y: 1} m_ColorLuminanceMin: 0 - m_ColorSaturationMax: 1 + m_ColorSaturationMax: 0 m_ParticleSpeed: 0 m_ParticleRate: 1 m_ParticleInitialRotationRange: 0 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Flat/FlatSingleSided.asset b/Assets/Resources/Brushes/Basic/Flat/FlatSingleSided.asset index 49135d9ca4..431b069830 100644 --- a/Assets/Resources/Brushes/Basic/Flat/FlatSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/Flat/FlatSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 510688aabb25f344daa830c8b8f5af16, type: 2} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: de0f4d89c1f1e8643a83ccc3ec66c965, type: 3} - m_Description: BRUSH_FLAT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 diff --git a/Assets/Resources/Brushes/Basic/Highlighter/Highlighter.asset b/Assets/Resources/Brushes/Basic/Highlighter/Highlighter.asset index 01413af286..fd06730ac1 100644 --- a/Assets/Resources/Brushes/Basic/Highlighter/Highlighter.asset +++ b/Assets/Resources/Brushes/Basic/Highlighter/Highlighter.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 17d833e2715afa6469d4db1c72ddc186, type: 3} - m_Description: BRUSH_HIGHLIGHTER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/HyperGrid/HyperGrid.asset b/Assets/Resources/Brushes/Basic/HyperGrid/HyperGrid.asset index 6926de54b2..892d3a29a0 100644 --- a/Assets/Resources/Brushes/Basic/HyperGrid/HyperGrid.asset +++ b/Assets/Resources/Brushes/Basic/HyperGrid/HyperGrid.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 1a6ba8e7f34c0b34faa2114158186eb8, type: 3} - m_Description: BRUSH_HYPERGRID m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Hypercolor/Hypercolor.asset b/Assets/Resources/Brushes/Basic/Hypercolor/Hypercolor.asset index 04670a4f9a..3adadc2560 100644 --- a/Assets/Resources/Brushes/Basic/Hypercolor/Hypercolor.asset +++ b/Assets/Resources/Brushes/Basic/Hypercolor/Hypercolor.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 4120e9061251b374d8fed28110fc9b70, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: c7bcf44fbc077c449b28a2b962a3b826, type: 3} - m_Description: BRUSH_HYPERCOLOR m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Hypercolor/normal.png b/Assets/Resources/Brushes/Basic/Hypercolor/normal.png index 942e54678c..f7c21ac76f 100644 Binary files a/Assets/Resources/Brushes/Basic/Hypercolor/normal.png and b/Assets/Resources/Brushes/Basic/Hypercolor/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/Hypercolor/normal.png.meta b/Assets/Resources/Brushes/Basic/Hypercolor/normal.png.meta index 0180b9c0b4..14b189e7bc 100644 --- a/Assets/Resources/Brushes/Basic/Hypercolor/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/Hypercolor/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 7c4d1ee0e90a536468404363fb2bef1d TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.066 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Icing/normal.png b/Assets/Resources/Brushes/Basic/Icing/normal.png index 39ade51049..973012426b 100644 Binary files a/Assets/Resources/Brushes/Basic/Icing/normal.png and b/Assets/Resources/Brushes/Basic/Icing/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/Icing/normal.png.meta b/Assets/Resources/Brushes/Basic/Icing/normal.png.meta index 8415c719f3..c8ff31ab7d 100644 --- a/Assets/Resources/Brushes/Basic/Icing/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/Icing/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 5130495e7534a264da464eec3b7c43d2 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.02 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Ink/Ink.asset b/Assets/Resources/Brushes/Basic/Ink/Ink.asset index d84b17824b..8f16c32ea4 100644 --- a/Assets/Resources/Brushes/Basic/Ink/Ink.asset +++ b/Assets/Resources/Brushes/Basic/Ink/Ink.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 11adf4e049619d54696db54bcdd0c724, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: bf436fffd0b90734b94ac4d97b08a070, type: 3} - m_Description: BRUSH_INK m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Ink/InkSingleSided.asset b/Assets/Resources/Brushes/Basic/Ink/InkSingleSided.asset index a01b40c456..e093f189a5 100644 --- a/Assets/Resources/Brushes/Basic/Ink/InkSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/Ink/InkSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: bf436fffd0b90734b94ac4d97b08a070, type: 3} - m_Description: BRUSH_INK m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png b/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png index 24708da801..cf8c0987d8 100644 Binary files a/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png and b/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png differ diff --git a/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png.meta b/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png.meta index e25b669f52..5f54238bd1 100644 --- a/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png.meta +++ b/Assets/Resources/Brushes/Basic/Ink/maintexture_normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 599e16957e2a8a84c81e8e72b55312d7 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.089 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Leaves/Leaves.asset b/Assets/Resources/Brushes/Basic/Leaves/Leaves.asset index 6b592440b3..a2dc6e392a 100644 --- a/Assets/Resources/Brushes/Basic/Leaves/Leaves.asset +++ b/Assets/Resources/Brushes/Basic/Leaves/Leaves.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 9d74e4f2898082d48885a67bc6f6e97d, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: d2c1795cbad88974887818098c0f59a5, type: 3} - m_Description: BRUSH_LEAVES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -66,7 +65,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Leaves/LeavesSingleSided.asset b/Assets/Resources/Brushes/Basic/Leaves/LeavesSingleSided.asset index ed12c7c468..8bd438f247 100644 --- a/Assets/Resources/Brushes/Basic/Leaves/LeavesSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/Leaves/LeavesSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: d2c1795cbad88974887818098c0f59a5, type: 3} - m_Description: BRUSH_LEAVES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -66,7 +65,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Leaves/normal.png b/Assets/Resources/Brushes/Basic/Leaves/normal.png index 33d0084025..8a65b651ff 100644 Binary files a/Assets/Resources/Brushes/Basic/Leaves/normal.png and b/Assets/Resources/Brushes/Basic/Leaves/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/Leaves/normal.png.meta b/Assets/Resources/Brushes/Basic/Leaves/normal.png.meta index 4b53f7ec88..46ec246c4f 100644 --- a/Assets/Resources/Brushes/Basic/Leaves/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/Leaves/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 735a5f2fd14c4764682ef32fc6822de5 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.046 normalMapFilter: 0 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Light/Light.asset b/Assets/Resources/Brushes/Basic/Light/Light.asset index cf3853de34..fa5481478e 100644 --- a/Assets/Resources/Brushes/Basic/Light/Light.asset +++ b/Assets/Resources/Brushes/Basic/Light/Light.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 842678e3e8f0299499a9366773e7e9b6, type: 3} - m_Description: BRUSH_LIGHT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Marker/Marker.asset b/Assets/Resources/Brushes/Basic/Marker/Marker.asset index 295c357366..742ccf01f8 100644 --- a/Assets/Resources/Brushes/Basic/Marker/Marker.asset +++ b/Assets/Resources/Brushes/Basic/Marker/Marker.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 6e665ea69b3463c47ae0660d94d50b93, type: 3} - m_Description: BRUSH_MARKER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/OilPaint/OilPaint.asset b/Assets/Resources/Brushes/Basic/OilPaint/OilPaint.asset index 37d6da8b86..13bb48d9f5 100644 --- a/Assets/Resources/Brushes/Basic/OilPaint/OilPaint.asset +++ b/Assets/Resources/Brushes/Basic/OilPaint/OilPaint.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: c1105f80e6e305d42a2368476c5e8948, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: 5d389e49c32371c4aaf832d61e52302e, type: 3} - m_Description: BRUSH_OILPAINT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/OilPaint/OilPaintSingleSided.asset b/Assets/Resources/Brushes/Basic/OilPaint/OilPaintSingleSided.asset index ed1478098d..ce818e9b5d 100644 --- a/Assets/Resources/Brushes/Basic/OilPaint/OilPaintSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/OilPaint/OilPaintSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 5d389e49c32371c4aaf832d61e52302e, type: 3} - m_Description: BRUSH_OILPAINT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/OilPaint/normal.png b/Assets/Resources/Brushes/Basic/OilPaint/normal.png index 2034fbf792..0d08764ef7 100644 Binary files a/Assets/Resources/Brushes/Basic/OilPaint/normal.png and b/Assets/Resources/Brushes/Basic/OilPaint/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/OilPaint/normal.png.meta b/Assets/Resources/Brushes/Basic/OilPaint/normal.png.meta index eed12905aa..2f537a1ad9 100644 --- a/Assets/Resources/Brushes/Basic/OilPaint/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/OilPaint/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 432d5c408cd625945ab19bb572a6f8e4 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.018 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,9 +33,9 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 + filterMode: 2 aniso: 4 - mipBias: -100 + mipBias: 0 wrapU: 0 wrapV: 0 wrapW: 0 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Paper/Paper.asset b/Assets/Resources/Brushes/Basic/Paper/Paper.asset index cdc7d1773a..feb290f755 100644 --- a/Assets/Resources/Brushes/Basic/Paper/Paper.asset +++ b/Assets/Resources/Brushes/Basic/Paper/Paper.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: d55d8be5dac1cf748abe4ae1ae7fc341, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: 9fc22eeaa38b9dd42b4ffa44cac359a5, type: 3} - m_Description: BRUSH_PAPER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Paper/PaperSingleSided.asset b/Assets/Resources/Brushes/Basic/Paper/PaperSingleSided.asset index 42c1ca8e2a..bd6978c37a 100644 --- a/Assets/Resources/Brushes/Basic/Paper/PaperSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/Paper/PaperSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 9fc22eeaa38b9dd42b4ffa44cac359a5, type: 3} - m_Description: BRUSH_PAPER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Paper/bump.png b/Assets/Resources/Brushes/Basic/Paper/bump.png index c99f914cf3..b24ed8cb29 100644 Binary files a/Assets/Resources/Brushes/Basic/Paper/bump.png and b/Assets/Resources/Brushes/Basic/Paper/bump.png differ diff --git a/Assets/Resources/Brushes/Basic/Paper/bump.png.meta b/Assets/Resources/Brushes/Basic/Paper/bump.png.meta index b39df78f3c..c8e94b5667 100644 --- a/Assets/Resources/Brushes/Basic/Paper/bump.png.meta +++ b/Assets/Resources/Brushes/Basic/Paper/bump.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 72b554b36eb21d445a97a119717a00e9 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.05 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/Petal/Petal.asset b/Assets/Resources/Brushes/Basic/Petal/Petal.asset index 69e777a244..b78d213c37 100644 --- a/Assets/Resources/Brushes/Basic/Petal/Petal.asset +++ b/Assets/Resources/Brushes/Basic/Petal/Petal.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 1fb6bccc613df8f48b3b35f266b29d3a, type: 3} - m_Description: BRUSH_PETAL m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Plasma/Plasma.asset b/Assets/Resources/Brushes/Basic/Plasma/Plasma.asset index b794e995ad..aef2f8b5da 100644 --- a/Assets/Resources/Brushes/Basic/Plasma/Plasma.asset +++ b/Assets/Resources/Brushes/Basic/Plasma/Plasma.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 34010fe6ad9c1cc4e89e11bdc5227251, type: 3} - m_Description: BRUSH_PLASMA m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Rainbow/Rainbow.asset b/Assets/Resources/Brushes/Basic/Rainbow/Rainbow.asset index e1dbb486b8..185a8643eb 100644 --- a/Assets/Resources/Brushes/Basic/Rainbow/Rainbow.asset +++ b/Assets/Resources/Brushes/Basic/Rainbow/Rainbow.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 63602c4cd80896844945e18da56b62e4, type: 3} - m_Description: BRUSH_RAINBOW m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Smoke/Smoke.asset b/Assets/Resources/Brushes/Basic/Smoke/Smoke.asset index a1358963de..3ea4cabf3e 100644 --- a/Assets/Resources/Brushes/Basic/Smoke/Smoke.asset +++ b/Assets/Resources/Brushes/Basic/Smoke/Smoke.asset @@ -26,7 +26,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: c23d417008975d249ac66a67f7841d56, type: 3} - m_Description: BRUSH_SMOKE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -72,7 +71,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Snow/Snow.asset b/Assets/Resources/Brushes/Basic/Snow/Snow.asset index 860776e510..a7dc12d353 100644 --- a/Assets/Resources/Brushes/Basic/Snow/Snow.asset +++ b/Assets/Resources/Brushes/Basic/Snow/Snow.asset @@ -27,7 +27,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 3aebc1f61692f694fafe1c4e6f8d0940, type: 3} - m_Description: BRUSH_SNOW m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -73,7 +72,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0.31 diff --git a/Assets/Resources/Brushes/Basic/SoftHighlighter/SoftHighlighter.asset b/Assets/Resources/Brushes/Basic/SoftHighlighter/SoftHighlighter.asset index f3ae15ee58..67c978ded7 100644 --- a/Assets/Resources/Brushes/Basic/SoftHighlighter/SoftHighlighter.asset +++ b/Assets/Resources/Brushes/Basic/SoftHighlighter/SoftHighlighter.asset @@ -26,7 +26,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 4f9ba9c27f3d67c4cbde2cf76973669c, type: 3} - m_Description: BRUSH_SOFTHIGHLIGHTER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Splatter/Splatter.asset b/Assets/Resources/Brushes/Basic/Splatter/Splatter.asset index 7a4f58f39d..98f8da8f8a 100644 --- a/Assets/Resources/Brushes/Basic/Splatter/Splatter.asset +++ b/Assets/Resources/Brushes/Basic/Splatter/Splatter.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: f3974944e708baf4e8bd5059dfa0c828, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: f22b8b31df5ec524baf9042a3a2c2041, type: 3} - m_Description: BRUSH_SPLATTER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Splatter/SplatterSingleSided.asset b/Assets/Resources/Brushes/Basic/Splatter/SplatterSingleSided.asset index a15cfbec94..6d415bfe1b 100644 --- a/Assets/Resources/Brushes/Basic/Splatter/SplatterSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/Splatter/SplatterSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: f22b8b31df5ec524baf9042a3a2c2041, type: 3} - m_Description: BRUSH_SPLATTER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Stars/Stars.asset b/Assets/Resources/Brushes/Basic/Stars/Stars.asset index f84305552c..df1055c623 100644 --- a/Assets/Resources/Brushes/Basic/Stars/Stars.asset +++ b/Assets/Resources/Brushes/Basic/Stars/Stars.asset @@ -27,7 +27,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 4242ebaeed2cfe04e86dd996d79f52c0, type: 3} - m_Description: BRUSH_STARS m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -73,7 +72,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Streamers/Streamers.asset b/Assets/Resources/Brushes/Basic/Streamers/Streamers.asset index 157fa73c20..b098bace11 100644 --- a/Assets/Resources/Brushes/Basic/Streamers/Streamers.asset +++ b/Assets/Resources/Brushes/Basic/Streamers/Streamers.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 6faf16ac3f9509645829d9a8ab5a51f6, type: 3} - m_Description: BRUSH_STREAMERS m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlat.asset b/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlat.asset index 97730eb81d..b61cdaf95c 100644 --- a/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlat.asset +++ b/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlat.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: c2166d6b2c9b4ac459f21599dd57aa9f, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: d07e3cd96d6dccb4587edbd30ca846ac, type: 3} - m_Description: BRUSH_TAPEREDFLAT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlatSingleSided.asset b/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlatSingleSided.asset index 0f035f2f77..28f409764f 100644 --- a/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlatSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/TaperedFlat/TaperedFlatSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: d07e3cd96d6dccb4587edbd30ca846ac, type: 3} - m_Description: BRUSH_TAPEREDFLAT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker.asset b/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker.asset index a88a2cdca4..8816b75b55 100644 --- a/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker.asset +++ b/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: e617036dc63ede649a1c716ac255dd88, type: 2} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 2874bc75bee3f4846a2ed9a07dd9c468, type: 3} - m_Description: BRUSH_TAPEREDMARKER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker_Flat.asset b/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker_Flat.asset index 9a01a96255..695949b3da 100644 --- a/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker_Flat.asset +++ b/Assets/Resources/Brushes/Basic/TaperedMarker/TaperedMarker_Flat.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 2874bc75bee3f4846a2ed9a07dd9c468, type: 3} - m_Description: BRUSH_TAPEREDMARKER m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaint.asset b/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaint.asset index 444a048c8d..cbf0a88c93 100644 --- a/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaint.asset +++ b/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaint.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 39d13a832a0de9347a03735ffa0fa075, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: cf51bd35732fc5d4d88f33fafc0e246f, type: 3} - m_Description: BRUSH_THICKPAINT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaintSingleSided.asset b/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaintSingleSided.asset index f70b339aef..f1d3b13de2 100644 --- a/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaintSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/ThickPaint/ThickPaintSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: cf51bd35732fc5d4d88f33fafc0e246f, type: 3} - m_Description: BRUSH_THICKPAINT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png b/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png index ceb4dd2fdc..3fad7f488e 100644 Binary files a/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png and b/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png differ diff --git a/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png.meta b/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png.meta index 9e0e340510..5e644abfed 100644 --- a/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png.meta +++ b/Assets/Resources/Brushes/Basic/ThickPaint/streakystroke_bump.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: adae364a85e64564f8a75e1c0c9958e7 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.1 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/VelvetInk/VelvetInk.asset b/Assets/Resources/Brushes/Basic/VelvetInk/VelvetInk.asset index df8bb7648b..9516eeb7a0 100644 --- a/Assets/Resources/Brushes/Basic/VelvetInk/VelvetInk.asset +++ b/Assets/Resources/Brushes/Basic/VelvetInk/VelvetInk.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 2fff5dc14badf3c44af955ee4d4a64c9, type: 3} - m_Description: BRUSH_VELVETINK m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Waveform/Waveform.asset b/Assets/Resources/Brushes/Basic/Waveform/Waveform.asset index dbf9dfc15d..12d72d2502 100644 --- a/Assets/Resources/Brushes/Basic/Waveform/Waveform.asset +++ b/Assets/Resources/Brushes/Basic/Waveform/Waveform.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 61a36c571f9c5ad48aab443947f5bb98, type: 3} - m_Description: BRUSH_WAVEFORM m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WaveformFFT/WaveformFFT.asset b/Assets/Resources/Brushes/Basic/WaveformFFT/WaveformFFT.asset index 4a392c5eb9..a37ca8c0be 100644 --- a/Assets/Resources/Brushes/Basic/WaveformFFT/WaveformFFT.asset +++ b/Assets/Resources/Brushes/Basic/WaveformFFT/WaveformFFT.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 61a36c571f9c5ad48aab443947f5bb98, type: 3} - m_Description: BRUSH_WAVEFORMFFT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WaveformParticles/WaveformParticles.asset b/Assets/Resources/Brushes/Basic/WaveformParticles/WaveformParticles.asset index 662adb429e..7e673cbe57 100644 --- a/Assets/Resources/Brushes/Basic/WaveformParticles/WaveformParticles.asset +++ b/Assets/Resources/Brushes/Basic/WaveformParticles/WaveformParticles.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 3e063230f3451664a8ce497d5fce1da9, type: 3} - m_Description: BRUSH_WAVEFORMPARTICLES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WaveformPulse/NeonPulse.asset b/Assets/Resources/Brushes/Basic/WaveformPulse/NeonPulse.asset index 6732e907a6..720cda8183 100644 --- a/Assets/Resources/Brushes/Basic/WaveformPulse/NeonPulse.asset +++ b/Assets/Resources/Brushes/Basic/WaveformPulse/NeonPulse.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 5abc544b4038f1e41b67c9c840d90968, type: 3} - m_Description: BRUSH_NEONPULSE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 1 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WaveformTube/WaveformTube.asset b/Assets/Resources/Brushes/Basic/WaveformTube/WaveformTube.asset index 2e028d5df0..3cabaf0464 100644 --- a/Assets/Resources/Brushes/Basic/WaveformTube/WaveformTube.asset +++ b/Assets/Resources/Brushes/Basic/WaveformTube/WaveformTube.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: c657d2f02f04e854c9e2055802705ed7, type: 3} - m_Description: BRUSH_WAVEFORMTUBE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WetPaint/WetPaint.asset b/Assets/Resources/Brushes/Basic/WetPaint/WetPaint.asset index 5b308af74a..2d7165b364 100644 --- a/Assets/Resources/Brushes/Basic/WetPaint/WetPaint.asset +++ b/Assets/Resources/Brushes/Basic/WetPaint/WetPaint.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: dea67637cd1a27e4c9b152f4bbcb84e5, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: d6be492160ab10341bf92b5ecdb68319, type: 3} - m_Description: BRUSH_WETPAINT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -70,7 +69,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0.25 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WetPaint/WetPaintSingleSided.asset b/Assets/Resources/Brushes/Basic/WetPaint/WetPaintSingleSided.asset index 84982cdd53..a5e85084cd 100644 --- a/Assets/Resources/Brushes/Basic/WetPaint/WetPaintSingleSided.asset +++ b/Assets/Resources/Brushes/Basic/WetPaint/WetPaintSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: d6be492160ab10341bf92b5ecdb68319, type: 3} - m_Description: BRUSH_WETPAINT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0.25 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/WetPaint/normal.png b/Assets/Resources/Brushes/Basic/WetPaint/normal.png index d7a38bcd4e..7a2922ab4a 100644 Binary files a/Assets/Resources/Brushes/Basic/WetPaint/normal.png and b/Assets/Resources/Brushes/Basic/WetPaint/normal.png differ diff --git a/Assets/Resources/Brushes/Basic/WetPaint/normal.png.meta b/Assets/Resources/Brushes/Basic/WetPaint/normal.png.meta index 49a8cfbfed..e8394b6423 100644 --- a/Assets/Resources/Brushes/Basic/WetPaint/normal.png.meta +++ b/Assets/Resources/Brushes/Basic/WetPaint/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 2dc1a52e6c8e9734dbc80815d8732e8a TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.03 normalMapFilter: 0 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,7 +88,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Android maxTextureSize: 1024 resizeAlgorithm: 0 @@ -91,7 +100,8 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 1 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: WebGL maxTextureSize: 2048 resizeAlgorithm: 0 @@ -102,6 +112,31 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -109,10 +144,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/Brushes/Basic/WigglyGraphite/WigglyGraphite.asset b/Assets/Resources/Brushes/Basic/WigglyGraphite/WigglyGraphite.asset index 90027f16a4..3799101510 100644 --- a/Assets/Resources/Brushes/Basic/WigglyGraphite/WigglyGraphite.asset +++ b/Assets/Resources/Brushes/Basic/WigglyGraphite/WigglyGraphite.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: e814fef197fd71944a2f50c2bb918be2, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: a6785d12f113845459233c510a470475, type: 3} - m_Description: BRUSH_DRWIGGLEZ m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0.5 m_BoundsPadding: 0 diff --git a/Assets/Resources/Brushes/Basic/Wireframe/Wireframe.asset b/Assets/Resources/Brushes/Basic/Wireframe/Wireframe.asset index 9642979472..889e3bc70a 100644 --- a/Assets/Resources/Brushes/Basic/Wireframe/Wireframe.asset +++ b/Assets/Resources/Brushes/Basic/Wireframe/Wireframe.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: ff1c726402b236f4789dc6c15ac97d8a, type: 3} - m_Description: BRUSH_WIREFRAME m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/UnityGLTFSettings.asset b/Assets/Resources/UnityGLTFSettings.asset new file mode 100644 index 0000000000..b7aaddc95f --- /dev/null +++ b/Assets/Resources/UnityGLTFSettings.asset @@ -0,0 +1,358 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &-8630084581239784447 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5d19ac0d23e84c248f196d1afbe9b9d0, type: 3} + m_Name: MaterialExtensionsImport + m_EditorClassIdentifier: + KHR_materials_ior: 1 + KHR_materials_transmission: 1 + KHR_materials_volume: 1 + KHR_materials_iridescence: 1 + KHR_materials_specular: 1 + KHR_materials_clearcoat: 1 + KHR_materials_pbrSpecularGlossiness: 1 + KHR_materials_emissive_strength: 1 +--- !u!114 &-7716978867629807533 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 056f401eae1a4f76b6f580ebf76127a9, type: 3} + m_Name: GPUInstancingImport + m_EditorClassIdentifier: +--- !u!114 &-7373113640993280472 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5152940c6ada2f3449baca5def38ea64, type: 3} + m_Name: MaterialExtensionsExport + m_EditorClassIdentifier: + KHR_materials_ior: 1 + KHR_materials_transmission: 1 + KHR_materials_volume: 1 + KHR_materials_iridescence: 1 + KHR_materials_specular: 1 + KHR_materials_clearcoat: 1 + KHR_materials_emissive_strength: 1 +--- !u!114 &-6755212205620999988 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 9571021a85f04ddfb74e8aa5aad9cc5a, type: 3} + m_Name: UnlitMaterialsExport + m_EditorClassIdentifier: +--- !u!114 &-5728475199642485532 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3d9fe28b7eb945fd891714c55c74f44b, type: 3} + m_Name: CanvasExport + m_EditorClassIdentifier: +--- !u!114 &-5101350394804673800 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 0} + m_Name: ObMeshExportPlugin + m_EditorClassIdentifier: Assembly-CSharp:TiltBrush:ObMeshExportPlugin + k__BackingField: 1 +--- !u!114 &-5020980606651475385 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 60bb1ecd8af04e0e864c773a2aaf6263, type: 3} + m_Name: TextureTransformImport + m_EditorClassIdentifier: +--- !u!114 &-4300759631978224901 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5066402b4fbd41e79ab3d7023cca96c5, type: 3} + m_Name: MaterialVariantsPlugin + m_EditorClassIdentifier: +--- !u!114 &-1701294651066981149 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 5dd4c08c7d6d71f4ca7d83fb653d4f9b, type: 3} + m_Name: TextMeshGameObjectExport + m_EditorClassIdentifier: +--- !u!114 &-1473009081019275097 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: e63c00ddf0924f0c8bd05f7f16935dfe, type: 3} + m_Name: LodsExport + m_EditorClassIdentifier: +--- !u!114 &-1229656505305497778 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c261146868c45eb4eb6b9987bd8c9084, type: 3} + m_Name: ObMeshExportPlugin + m_EditorClassIdentifier: +--- !u!114 &-682178813687408182 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c261146868c45eb4eb6b9987bd8c9084, type: 3} + m_Name: OpenBrushExportPlugin + m_EditorClassIdentifier: +--- !u!114 &1 +MonoBehaviour: + m_ObjectHideFlags: 0 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 9d9a5969691dba845877d0a52b6d9397, type: 3} + m_Name: UnityGLTFSettings + m_EditorClassIdentifier: + ImportPlugins: + - {fileID: 6228052705860985836} + - {fileID: 5944692436833662843} + - {fileID: 6637830443630214129} + - {fileID: 6408916617862751518} + - {fileID: -8630084581239784447} + - {fileID: 1115410688402324010} + - {fileID: -5020980606651475385} + - {fileID: 8372111537548844026} + - {fileID: -7716978867629807533} + - {fileID: 6916234453510156686} + ExportPlugins: + - {fileID: 242952683485160214} + - {fileID: -5728475199642485532} + - {fileID: -4300759631978224901} + - {fileID: -1701294651066981149} + - {fileID: 6646381916753263187} + - {fileID: 5798040331557388862} + - {fileID: -1473009081019275097} + - {fileID: -7373113640993280472} + - {fileID: 7420168740226561727} + - {fileID: -6755212205620999988} + - {fileID: 8207833083978872644} + - {fileID: -682178813687408182} + exportNames: 1 + exportFullPath: 0 + requireExtensions: 0 + useMainCameraVisibility: 0 + exportDisabledGameObjects: 0 + tryExportTexturesFromDisk: 0 + useTextureFileTypeHeuristic: 1 + defaultJpegQuality: 90 + exportAnimations: 1 + bakeAnimationSpeed: 0 + uniqueAnimationNames: 0 + bakeSkinnedMeshes: 0 + blendShapeExportProperties: -1 + blendShapeExportSparseAccessors: 1 + exportVertexColors: 1 + UseCaching: 1 +--- !u!114 &242952683485160214 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: c85d7bc6d6ea44f46b33f0a3a2e09283, type: 3} + m_Name: BakeParticleSystem + m_EditorClassIdentifier: +--- !u!114 &1115410688402324010 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 837601ceb763400cadb3575e55885670, type: 3} + m_Name: MeshoptImport + m_EditorClassIdentifier: +--- !u!114 &5798040331557388862 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 3579a4c311b8427f81a0c1a29e9acfe8, type: 3} + m_Name: LightsPunctualExport + m_EditorClassIdentifier: +--- !u!114 &5944692436833662843 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 969cbb3ac6864c2f9e49e468eef2744c, type: 3} + m_Name: Ktx2Import + m_EditorClassIdentifier: +--- !u!114 &6228052705860985836 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 7dca6a7cdc544a17b19918041bc59d14, type: 3} + m_Name: DracoImport + m_EditorClassIdentifier: +--- !u!114 &6408916617862751518 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2239c10507484fb78bb19067a66500f2, type: 3} + m_Name: LodsImport + m_EditorClassIdentifier: +--- !u!114 &6637830443630214129 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: d48839dd2db84f9f94ec4e3bb77e9f9e, type: 3} + m_Name: LightsPunctualImport + m_EditorClassIdentifier: +--- !u!114 &6646381916753263187 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: b6d87ebf60834245a388cd150253839d, type: 3} + m_Name: AnimationPointerExport + m_EditorClassIdentifier: +--- !u!114 &6916234453510156686 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 6843a59b1a844430b7b7c08e8711a6d7, type: 3} + m_Name: OpenBrushLightsImport + m_EditorClassIdentifier: +--- !u!114 &7420168740226561727 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 984138db70144b97b48597182a21b46c, type: 3} + m_Name: TextureTransformExport + m_EditorClassIdentifier: +--- !u!114 &8207833083978872644 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 664d6e75fec3044eb9274db51fbb70da, type: 3} + m_Name: KHRAudioPlugin + m_EditorClassIdentifier: +--- !u!114 &8372111537548844026 +MonoBehaviour: + m_ObjectHideFlags: 3 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: 2d3bb2aeeab442db8c587d6e67450acc, type: 3} + m_Name: UnlitMaterialsImport + m_EditorClassIdentifier: diff --git a/Assets/Resources/UnityGLTFSettings.asset.meta b/Assets/Resources/UnityGLTFSettings.asset.meta new file mode 100644 index 0000000000..148ec6ee59 --- /dev/null +++ b/Assets/Resources/UnityGLTFSettings.asset.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4bcbc565b83276a46b0353b376d2a77d +NativeFormatImporter: + externalObjects: {} + mainObjectFileID: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Resources/X/Brushes/BubbleWand/BubbleWand.asset b/Assets/Resources/X/Brushes/BubbleWand/BubbleWand.asset index 602f96319f..d4103cc66f 100644 --- a/Assets/Resources/X/Brushes/BubbleWand/BubbleWand.asset +++ b/Assets/Resources/X/Brushes/BubbleWand/BubbleWand.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 240cf3d732acb9943acbf4e12f05ba6e, type: 3} - m_Description: BRUSH_BUBBLEWAND m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -67,7 +66,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Charcoal/normal.png b/Assets/Resources/X/Brushes/Charcoal/normal.png index a89ffbb7ca..d4ee81fd68 100644 Binary files a/Assets/Resources/X/Brushes/Charcoal/normal.png and b/Assets/Resources/X/Brushes/Charcoal/normal.png differ diff --git a/Assets/Resources/X/Brushes/Charcoal/normal.png.meta b/Assets/Resources/X/Brushes/Charcoal/normal.png.meta index 738aa57873..700f25572d 100644 --- a/Assets/Resources/X/Brushes/Charcoal/normal.png.meta +++ b/Assets/Resources/X/Brushes/Charcoal/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 9bdb8bc5360ddc148bfcb994ca09401f TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.02 normalMapFilter: 0 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/Drafting/Drafting.asset b/Assets/Resources/X/Brushes/Drafting/Drafting.asset index e14aef5451..576a87b258 100644 --- a/Assets/Resources/X/Brushes/Drafting/Drafting.asset +++ b/Assets/Resources/X/Brushes/Drafting/Drafting.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: edb56af8fe2a7754bbcd0a7af6ec144c, type: 3} - m_Description: BRUSH_DRAFTING m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -67,7 +66,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/DryBrush/normal.jpg b/Assets/Resources/X/Brushes/DryBrush/normal.jpg index b75401c357..d28ce49fc9 100644 Binary files a/Assets/Resources/X/Brushes/DryBrush/normal.jpg and b/Assets/Resources/X/Brushes/DryBrush/normal.jpg differ diff --git a/Assets/Resources/X/Brushes/DryBrush/normal.jpg.meta b/Assets/Resources/X/Brushes/DryBrush/normal.jpg.meta index be4a5b2e37..e6baa7e018 100644 --- a/Assets/Resources/X/Brushes/DryBrush/normal.jpg.meta +++ b/Assets/Resources/X/Brushes/DryBrush/normal.jpg.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 3d0bfa733a1992c4484952a4e71fc67f TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.015 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/Fairy/Fairy.asset b/Assets/Resources/X/Brushes/Fairy/Fairy.asset index 24062478df..558bee2b3c 100644 --- a/Assets/Resources/X/Brushes/Fairy/Fairy.asset +++ b/Assets/Resources/X/Brushes/Fairy/Fairy.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 908e6cb2410cac845b4401855e9e0e28, type: 3} - m_Description: BRUSH_FAIRY m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Fire 2/Fire2.asset b/Assets/Resources/X/Brushes/Fire 2/Fire2.asset index e1d4b0c55f..b54720295f 100644 --- a/Assets/Resources/X/Brushes/Fire 2/Fire2.asset +++ b/Assets/Resources/X/Brushes/Fire 2/Fire2.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 67e4ca18156c26a4099aa6a9da05058a, type: 3} - m_Description: BRUSH_FIRE2 m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -71,7 +70,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Gouache/Gouache.asset b/Assets/Resources/X/Brushes/Gouache/Gouache.asset index 2c9cd9c26c..0dc3173ed7 100644 --- a/Assets/Resources/X/Brushes/Gouache/Gouache.asset +++ b/Assets/Resources/X/Brushes/Gouache/Gouache.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 11400000, guid: 4465b5ef3605bec42b3e6b04508ddb6b, type: 2} m_LooksIdentical: 1 m_ButtonTexture: {fileID: 2800000, guid: d242d268c0d3f1b44846a4788383cbf6, type: 3} - m_Description: BRUSH_GOUACHE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -67,7 +66,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Gouache/GouacheSingleSided.asset b/Assets/Resources/X/Brushes/Gouache/GouacheSingleSided.asset index 5450ef1d80..1156ea5ee0 100644 --- a/Assets/Resources/X/Brushes/Gouache/GouacheSingleSided.asset +++ b/Assets/Resources/X/Brushes/Gouache/GouacheSingleSided.asset @@ -23,7 +23,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: d242d268c0d3f1b44846a4788383cbf6, type: 3} - m_Description: BRUSH_GOUACHE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -66,7 +65,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 1 + m_RenderBackfaces: 0 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Gouache/normal.png b/Assets/Resources/X/Brushes/Gouache/normal.png index c1bb86be24..f05b5e45a1 100644 Binary files a/Assets/Resources/X/Brushes/Gouache/normal.png and b/Assets/Resources/X/Brushes/Gouache/normal.png differ diff --git a/Assets/Resources/X/Brushes/Gouache/normal.png.meta b/Assets/Resources/X/Brushes/Gouache/normal.png.meta index a13e1ae2ac..f0fb9889b7 100644 --- a/Assets/Resources/X/Brushes/Gouache/normal.png.meta +++ b/Assets/Resources/X/Brushes/Gouache/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 3a1bfa901a032c94e9a3e4adb6952d0f TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.03 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/Guts/normal.png b/Assets/Resources/X/Brushes/Guts/normal.png index 51f9b8ad1e..1598d45356 100644 Binary files a/Assets/Resources/X/Brushes/Guts/normal.png and b/Assets/Resources/X/Brushes/Guts/normal.png differ diff --git a/Assets/Resources/X/Brushes/Guts/normal.png.meta b/Assets/Resources/X/Brushes/Guts/normal.png.meta index 42e72489b6..de22ecb199 100644 --- a/Assets/Resources/X/Brushes/Guts/normal.png.meta +++ b/Assets/Resources/X/Brushes/Guts/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: d03c44c5f6a1b194ea104833f9ba840d TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -20,9 +20,11 @@ TextureImporter: externalNormalMap: 0 heightScale: 0.25 normalMapFilter: 0 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,22 +56,28 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 - textureCompression: 1 + textureCompression: 0 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 - - serializedVersion: 2 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 buildTarget: Standalone maxTextureSize: 2048 resizeAlgorithm: 0 @@ -80,6 +88,43 @@ TextureImporter: allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -87,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/KeijiroTube/KeijiroTube.asset b/Assets/Resources/X/Brushes/KeijiroTube/KeijiroTube.asset index 8998ab5040..fc17c92e2e 100644 --- a/Assets/Resources/X/Brushes/KeijiroTube/KeijiroTube.asset +++ b/Assets/Resources/X/Brushes/KeijiroTube/KeijiroTube.asset @@ -24,7 +24,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: eae76e74cb666d3449b99d9b9d67c6ec, type: 3} - m_Description: BRUSH_KEIJIROTUBE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -67,7 +66,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Lacewing/normal.png b/Assets/Resources/X/Brushes/Lacewing/normal.png index e15807c4e5..479c3af112 100644 Binary files a/Assets/Resources/X/Brushes/Lacewing/normal.png and b/Assets/Resources/X/Brushes/Lacewing/normal.png differ diff --git a/Assets/Resources/X/Brushes/Lacewing/normal.png.meta b/Assets/Resources/X/Brushes/Lacewing/normal.png.meta index b73c0ea3b7..e82acf0f43 100644 --- a/Assets/Resources/X/Brushes/Lacewing/normal.png.meta +++ b/Assets/Resources/X/Brushes/Lacewing/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: dc24e2075b423f943aaa744cbccf20c9 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.015 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/LeakyPen/main.png b/Assets/Resources/X/Brushes/LeakyPen/main.png index fd90ba6ef4..7241f9b161 100644 Binary files a/Assets/Resources/X/Brushes/LeakyPen/main.png and b/Assets/Resources/X/Brushes/LeakyPen/main.png differ diff --git a/Assets/Resources/X/Brushes/MarbledRainbow/MarbledRainbow.asset b/Assets/Resources/X/Brushes/MarbledRainbow/MarbledRainbow.asset index 8f43735c36..93e3344eb0 100644 --- a/Assets/Resources/X/Brushes/MarbledRainbow/MarbledRainbow.asset +++ b/Assets/Resources/X/Brushes/MarbledRainbow/MarbledRainbow.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 23d54c8635d7fc44ab5ddf2c8308967a, type: 3} - m_Description: BRUSH_MARBLEDRAINBOW m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 diff --git a/Assets/Resources/X/Brushes/MarbledRainbow/normal.png b/Assets/Resources/X/Brushes/MarbledRainbow/normal.png index 5b6eff00c3..4db6996424 100644 Binary files a/Assets/Resources/X/Brushes/MarbledRainbow/normal.png and b/Assets/Resources/X/Brushes/MarbledRainbow/normal.png differ diff --git a/Assets/Resources/X/Brushes/MarbledRainbow/normal.png.meta b/Assets/Resources/X/Brushes/MarbledRainbow/normal.png.meta index f33a362f4e..174a031705 100644 --- a/Assets/Resources/X/Brushes/MarbledRainbow/normal.png.meta +++ b/Assets/Resources/X/Brushes/MarbledRainbow/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 70738dc9310ce1a4f88400c683a47494 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.015 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/Muscle/muscle_normal.png b/Assets/Resources/X/Brushes/Muscle/muscle_normal.png index 562f6d5093..f505dcccb2 100644 Binary files a/Assets/Resources/X/Brushes/Muscle/muscle_normal.png and b/Assets/Resources/X/Brushes/Muscle/muscle_normal.png differ diff --git a/Assets/Resources/X/Brushes/Muscle/muscle_normal.png.meta b/Assets/Resources/X/Brushes/Muscle/muscle_normal.png.meta index 5c50d9e96f..4568e72626 100644 --- a/Assets/Resources/X/Brushes/Muscle/muscle_normal.png.meta +++ b/Assets/Resources/X/Brushes/Muscle/muscle_normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: d72cc108e6b8e2b459e9399f8217b7e1 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -20,9 +20,11 @@ TextureImporter: externalNormalMap: 0 heightScale: 0.25 normalMapFilter: 0 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 1 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/Rain/Rain.asset b/Assets/Resources/X/Brushes/Rain/Rain.asset index a6971b1d9a..158693ed07 100644 --- a/Assets/Resources/X/Brushes/Rain/Rain.asset +++ b/Assets/Resources/X/Brushes/Rain/Rain.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 5d2f4e6465047e04e8d74a65b4f9f727, type: 3} - m_Description: BRUSH_RAIN m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/RisingBubbles/RisingBubbles.asset b/Assets/Resources/X/Brushes/RisingBubbles/RisingBubbles.asset index 124eee6ace..049d7b70e0 100644 --- a/Assets/Resources/X/Brushes/RisingBubbles/RisingBubbles.asset +++ b/Assets/Resources/X/Brushes/RisingBubbles/RisingBubbles.asset @@ -26,7 +26,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 115a7c360b3c57b47a96894ec2891899, type: 3} - m_Description: BRUSH_RISINGBUBBLES m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -69,7 +68,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Space/Space.asset b/Assets/Resources/X/Brushes/Space/Space.asset index e9371693fd..a71460ff4b 100644 --- a/Assets/Resources/X/Brushes/Space/Space.asset +++ b/Assets/Resources/X/Brushes/Space/Space.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: 4242ebaeed2cfe04e86dd996d79f52c0, type: 3} - m_Description: BRUSH_SPACE m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Sparks/Sparks.asset b/Assets/Resources/X/Brushes/Sparks/Sparks.asset index cf47d603b0..c17b72ce68 100644 --- a/Assets/Resources/X/Brushes/Sparks/Sparks.asset +++ b/Assets/Resources/X/Brushes/Sparks/Sparks.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: ca2dd7c3b5b9b1a47b573fd4af1a3ed3, type: 3} - m_Description: BRUSH_SPARKS m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 1 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/Square/normal.png b/Assets/Resources/X/Brushes/Square/normal.png index 4ad8a60b7d..2a1fa1ee40 100644 Binary files a/Assets/Resources/X/Brushes/Square/normal.png and b/Assets/Resources/X/Brushes/Square/normal.png differ diff --git a/Assets/Resources/X/Brushes/Square/normal.png.meta b/Assets/Resources/X/Brushes/Square/normal.png.meta index 33ef7c593e..d00d8b1a0c 100644 --- a/Assets/Resources/X/Brushes/Square/normal.png.meta +++ b/Assets/Resources/X/Brushes/Square/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 7f06e0457ba1c9140b95991692f69cef TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -20,9 +20,11 @@ TextureImporter: externalNormalMap: 1 heightScale: 0.011 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,9 +33,9 @@ TextureImporter: maxTextureSize: 1024 textureSettings: serializedVersion: 2 - filterMode: -1 + filterMode: 1 aniso: 2 - mipBias: -100 + mipBias: 0 wrapU: 0 wrapV: 0 wrapW: 0 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 1024 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 1024 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Resources/X/Brushes/TaperedHueShift/TaperedHueShift.asset b/Assets/Resources/X/Brushes/TaperedHueShift/TaperedHueShift.asset index 1f86373de3..df8fae7f3b 100644 --- a/Assets/Resources/X/Brushes/TaperedHueShift/TaperedHueShift.asset +++ b/Assets/Resources/X/Brushes/TaperedHueShift/TaperedHueShift.asset @@ -25,7 +25,6 @@ MonoBehaviour: m_Supersedes: {fileID: 0} m_LooksIdentical: 0 m_ButtonTexture: {fileID: 2800000, guid: d07e3cd96d6dccb4587edbd30ca846ac, type: 3} - m_Description: BRUSH_TAPEREDHUESHIFT m_LocalizedDescription: m_TableReference: m_TableCollectionName: GUID:c84355079ab3f3e4f8f3812258805f86 @@ -68,7 +67,7 @@ MonoBehaviour: m_M11Compatibility: 0 m_SolidMinLengthMeters_PS: 0.002 m_TubeStoreRadiusInTexcoord0Z: 0 - m_RenderBackfaces: 0 + m_RenderBackfaces: 1 m_BackIsInvisible: 0 m_BackfaceHueShift: 0 m_BoundsPadding: 0 diff --git a/Assets/Resources/X/Brushes/WatercolorPaper/normal.png b/Assets/Resources/X/Brushes/WatercolorPaper/normal.png index 1516dae70c..5a8ff26b15 100644 Binary files a/Assets/Resources/X/Brushes/WatercolorPaper/normal.png and b/Assets/Resources/X/Brushes/WatercolorPaper/normal.png differ diff --git a/Assets/Resources/X/Brushes/WatercolorPaper/normal.png.meta b/Assets/Resources/X/Brushes/WatercolorPaper/normal.png.meta index 82e33c82ea..e91f093f6b 100644 --- a/Assets/Resources/X/Brushes/WatercolorPaper/normal.png.meta +++ b/Assets/Resources/X/Brushes/WatercolorPaper/normal.png.meta @@ -1,9 +1,9 @@ fileFormatVersion: 2 guid: 05791ccbec1b0344c8cd3d29c0a18a03 TextureImporter: - fileIDToRecycleName: {} + internalIDToNameTable: [] externalObjects: {} - serializedVersion: 9 + serializedVersion: 12 mipmaps: mipMapMode: 0 enableMipMap: 1 @@ -16,13 +16,15 @@ TextureImporter: mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: - convertToNormalMap: 1 + convertToNormalMap: 0 externalNormalMap: 1 heightScale: 0.02 normalMapFilter: 1 - isReadable: 0 + isReadable: 1 streamingMipmaps: 0 streamingMipmapsPriority: 0 + vTOnly: 0 + ignoreMasterTextureLimit: 0 grayScaleToAlpha: 0 generateCubemap: 6 cubemapConvolution: 0 @@ -31,12 +33,12 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: -1 - aniso: -1 - mipBias: -100 - wrapU: -1 - wrapV: -1 - wrapW: -1 + filterMode: 2 + aniso: 1 + mipBias: 0 + wrapU: 0 + wrapV: 0 + wrapW: 0 nPOTScale: 1 lightmap: 0 compressionQuality: 50 @@ -54,21 +56,75 @@ TextureImporter: textureType: 1 textureShape: 1 singleChannelComponent: 0 + flipbookRows: 1 + flipbookColumns: 1 maxTextureSizeSet: 0 compressionQualitySet: 0 textureFormatSet: 0 + ignorePngGamma: 0 + applyGammaDecoding: 1 + cookieLightType: 1 platformSettings: - - serializedVersion: 2 + - serializedVersion: 3 buildTarget: DefaultTexturePlatform maxTextureSize: 2048 resizeAlgorithm: 0 textureFormat: -1 + textureCompression: 0 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Standalone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: iPhone + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Android + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 + textureCompression: 1 + compressionQuality: 50 + crunchedCompression: 0 + allowsAlphaSplitting: 0 + overridden: 0 + androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 + - serializedVersion: 3 + buildTarget: Server + maxTextureSize: 2048 + resizeAlgorithm: 0 + textureFormat: -1 textureCompression: 1 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 overridden: 0 androidETC2FallbackOverride: 0 + forceMaximumCompressionQuality_BC6H_BC7: 1 spriteSheet: serializedVersion: 2 sprites: [] @@ -76,10 +132,13 @@ TextureImporter: physicsShape: [] bones: [] spriteID: + internalID: 0 vertices: [] indices: edges: [] weights: [] + secondaryTextures: [] + nameFileIdTable: {} spritePackingTag: pSDRemoveMatte: 0 pSDShowRemoveMatteOption: 0 diff --git a/Assets/Scenes/Main.unity b/Assets/Scenes/Main.unity index 0b7636b5e7..ff1c3ae572 100644 --- a/Assets/Scenes/Main.unity +++ b/Assets/Scenes/Main.unity @@ -10125,6 +10125,7 @@ Transform: - {fileID: 383974627} - {fileID: 669339392} - {fileID: 1052269831} + - {fileID: 691032546} m_Father: {fileID: 0} m_RootOrder: 0 m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} @@ -11290,6 +11291,81 @@ Transform: type: 3} m_PrefabInstance: {fileID: 8373124985758590944} m_PrefabAsset: {fileID: 0} +--- !u!1001 &691032545 +PrefabInstance: + m_ObjectHideFlags: 0 + serializedVersion: 2 + m_Modification: + m_TransformParent: {fileID: 652605545} + m_Modifications: + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_RootOrder + value: 5 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalPosition.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalPosition.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalPosition.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalRotation.w + value: 1 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalRotation.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalRotation.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalRotation.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalEulerAnglesHint.x + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalEulerAnglesHint.y + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_LocalEulerAnglesHint.z + value: 0 + objectReference: {fileID: 0} + - target: {fileID: 2530997363061912793, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + propertyPath: m_Name + value: BrushBaker + objectReference: {fileID: 0} + m_RemovedComponents: [] + m_SourcePrefab: {fileID: 100100000, guid: cb0a1a7968495024690ad9a1c0d38548, type: 3} +--- !u!4 &691032546 stripped +Transform: + m_CorrespondingSourceObject: {fileID: 167830897998540590, guid: cb0a1a7968495024690ad9a1c0d38548, + type: 3} + m_PrefabInstance: {fileID: 691032545} + m_PrefabAsset: {fileID: 0} --- !u!1 &694338410 GameObject: m_ObjectHideFlags: 0 @@ -30053,6 +30129,10 @@ MonoBehaviour: type: 3} m_VideoWidgetPrefab: {fileID: 854942063617328480, guid: a1bf54eee52cec14e8207351740867f3, type: 3} + m_LightWidgetPrefab: {fileID: 11466202, guid: e061cff5394e32940bb00495b287bb38, + type: 3} + m_SceneLightGizmoPrefab: {fileID: 1712584378369130260, guid: f28bfd6efbf3cb046be485c6573ca207, + type: 3} m_CameraPathWidgetPrefab: {fileID: 114268259032398848, guid: a933b2a19614a6c4da08a0143f0ec912, type: 3} m_CameraPathPositionKnotPrefab: {fileID: 1334758335721002, guid: 38b506951b7a81e4e9a6c65a9a20efa9, diff --git a/Assets/Scripts/API/ApiMethods.EditableModels.cs b/Assets/Scripts/API/ApiMethods.EditableModels.cs index 2cdf48a176..06d1ef7411 100644 --- a/Assets/Scripts/API/ApiMethods.EditableModels.cs +++ b/Assets/Scripts/API/ApiMethods.EditableModels.cs @@ -13,49 +13,64 @@ // limitations under the License. using System; +using System.IO; +using System.Linq; using UnityEngine; -using System.Threading; using System.Threading.Tasks; namespace TiltBrush { public static partial class ApiMethods { - [ApiEndpoint("model.import", "Imports a model given a url or a filename in Media Library\\Models (Models loaded from a url are saved locally first)")] + [ApiEndpoint("model.webimport", "Imports a model given a url or a filename in Media Library\\Models (Models loaded from a url are saved locally first)")] + [ApiEndpoint("import.webmodel", "Same as model.webimport (backwards compatibility for poly.pizza)")] + public static void ImportWebModel(string url) + { + Uri uri; + try { uri = new Uri(url); } + catch (UriFormatException) + { return; } + var ext = uri.Segments.Last().Split('.').Last(); - public static async Task ImportModel(string location) + // Is it a valid 3d model extension? + if (ext != "off" && ext != "obj" && ext != "gltf" && ext != "glb" && ext != "fbx" && ext != "svg") + { + return; + } + var destinationPath = Path.Combine("Models", uri.Host); + string filename = _DownloadMediaFileFromUrl(uri, destinationPath); + ImportModel(Path.Combine(uri.Host, filename)); + } + + [ApiEndpoint("model.import", "Imports a model given a url or a filename in Media Library\\Models (Models loaded from a url are saved locally first)")] + public static void ImportModel(string location) { if (location.StartsWith("poly:")) { location = location.Substring(5); ApiManager.Instance.LoadPolyModel(location); - return null; // TODO + return; // TODO } - if (location.StartsWith("http://") || location.StartsWith("https://")) - { - // You can't rely on urls ending with a file extension - // But try and fall back to assuming web models will be gltf/glb - // TODO Try deriving from MIME types - if (location.EndsWith(".off") || location.EndsWith(".obj")) - { - location = _DownloadMediaFileFromUrl(location, App.ModelLibraryPath()); - } - else - { - Uri uri = new Uri(location); - ApiManager.Instance.LoadPolyModel(uri); - } - } + // Normalize path slashes + location = location.Replace(@"\\", "/"); + location = location.Replace(@"//", "/"); + location = location.Replace(@"\", "/"); + + var parts = location.Split("#"); // At this point we've got a relative path to a file in Models - string relativePath = location; + string relativePath = parts[0]; + string subtree = null; + if (parts.Length > 1) + { + subtree = location.Substring(relativePath.Length + 1); + } var tr = _CurrentTransform().TransformBy(Coords.CanvasPose); var model = new Model(Model.Location.File(relativePath)); - - Task t = model.LoadModelAsync(); - await t; + AsyncHelpers.RunSync(() => model.LoadModelAsync()); + model.EnsureCollectorExists(); CreateWidgetCommand createCommand = new CreateWidgetCommand( WidgetManager.m_Instance.ModelWidgetPrefab, tr, null, forceTransform: true ); @@ -64,19 +79,21 @@ public static async Task ImportModel(string location) if (widget != null) { widget.Model = model; + widget.Subtree = subtree; + widget.SyncHierarchyToSubtree(); widget.Show(true); + widget.AddSceneLightGizmos(); createCommand.SetWidgetCost(widget.GetTiltMeterCost()); } else { Debug.LogWarning("Failed to create EditableModelWidget"); - return null; + return; } WidgetManager.m_Instance.WidgetsDormant = false; SketchControlsScript.m_Instance.EatGazeObjectInput(); SelectionManager.m_Instance.RemoveFromSelection(false); - return widget; } } } diff --git a/Assets/Scripts/API/ApiMethods.GlobalCommands.cs b/Assets/Scripts/API/ApiMethods.GlobalCommands.cs index ec1b91b8bb..b415e7aec8 100644 --- a/Assets/Scripts/API/ApiMethods.GlobalCommands.cs +++ b/Assets/Scripts/API/ApiMethods.GlobalCommands.cs @@ -40,7 +40,7 @@ public static void SaveNew() SketchControlsScript.m_Instance.IssueGlobalCommand(rEnum, 1); } - // TODO + // TODO // [ApiEndpoint("upload", "Saves the current scene and uploads it to Poly/Icosa")] // public static void SaveAndUpload() // { @@ -113,6 +113,7 @@ public static void LoadNamedFile(string filename) -1, Path.Combine(App.UserSketchPath(), filename) ); + PanelManager.m_Instance.ToggleSketchbookPanels(true); } [ApiEndpoint("merge.named", "Loads the sketch with the given name from the user's sketch folder")] @@ -368,7 +369,7 @@ public static void DeleteSelection() } // TODO explicit group/ungroup - [ApiEndpoint("selection.group", "Groups the current selection")] + [ApiEndpoint("selection.group", "Groups (or ungroups) the current selection")] public static void ToggleGroupStrokesAndWidgets() { var rEnum = SketchControlsScript.GlobalCommands.ToggleGroupStrokesAndWidgets; diff --git a/Assets/Scripts/API/ApiMethods.Utils.cs b/Assets/Scripts/API/ApiMethods.Utils.cs index d0add1ae1d..99f0d1784b 100644 --- a/Assets/Scripts/API/ApiMethods.Utils.cs +++ b/Assets/Scripts/API/ApiMethods.Utils.cs @@ -90,27 +90,30 @@ private static Vector3 _PerlinNoiseToPosition(Vector3 pos, Vector3 scale, Axis a return new Vector3(pos.x * scale.x, pos.y * scale.y, pos.z * scale.z); } - private static void _PositionWidget(GrabWidget widget, Vector3 position) + private static void _SetWidgetPosition(GrabWidget widget, Vector3 position) { + var tr = widget.LocalTransform; + tr.translation = position; SketchMemoryScript.m_Instance.PerformAndRecordCommand( - new MoveWidgetCommand( - widget, - TrTransform.T(position), - widget.CustomDimension, - true - ) + new MoveWidgetCommand(widget, tr, widget.CustomDimension, true) ); } - private static void _ScaleWidget(GrabWidget widget, float scale) + private static void _SetWidgetRotation(GrabWidget widget, Vector3 rotation) { + var tr = widget.LocalTransform; + tr.rotation = Quaternion.Euler(rotation); SketchMemoryScript.m_Instance.PerformAndRecordCommand( - new MoveWidgetCommand( - widget, - TrTransform.S(scale), - widget.CustomDimension, - true - ) + new MoveWidgetCommand(widget, tr, widget.CustomDimension, true) + ); + } + + private static void _SetWidgetScale(GrabWidget widget, float scale) + { + var tr = widget.LocalTransform; + tr.scale = scale; + SketchMemoryScript.m_Instance.PerformAndRecordCommand( + new MoveWidgetCommand(widget, tr, widget.CustomDimension, true) ); } @@ -128,6 +131,12 @@ private static ImageWidget _GetActiveImage(int index) return WidgetManager.m_Instance.ActiveImageWidgets[index].WidgetScript; } + private static LightWidget _GetActiveLight(int index) + { + index = _NegativeIndexing(index, WidgetManager.m_Instance.ActiveLightWidgets); + return WidgetManager.m_Instance.ActiveLightWidgets[index].WidgetScript; + } + private static VideoWidget _GetActiveVideo(int index) { index = _NegativeIndexing(index, WidgetManager.m_Instance.ActiveVideoWidgets); @@ -146,12 +155,16 @@ private static CameraPathWidget _GetActiveCameraPath(int index) return WidgetManager.m_Instance.GetNthActiveCameraPath(index); } - private static string _DownloadMediaFileFromUrl(string url, string destinationFolder) + private static string _DownloadMediaFileFromUrl(string url, string relativeDestinationFolder) + { + return _DownloadMediaFileFromUrl(new Uri(url), relativeDestinationFolder); + } + + private static string _DownloadMediaFileFromUrl(Uri url, string relativeDestinationFolder) { var request = System.Net.WebRequest.Create(url); request.Method = "HEAD"; var response = request.GetResponse(); - Uri uri = new Uri(url); string filename; var contentDisposition = response.Headers["Content-Disposition"]; @@ -163,13 +176,31 @@ private static string _DownloadMediaFileFromUrl(string url, string destinationFo } else { - filename = uri.AbsolutePath.Split('/').Last(); + filename = url.AbsolutePath.Split('/').Last(); + } + + string AbsoluteDestinationPath = Path.Combine(App.MediaLibraryPath(), relativeDestinationFolder); + if (!Directory.Exists(AbsoluteDestinationPath)) + { + Directory.CreateDirectory(AbsoluteDestinationPath); + } + + // Check if file already exists + // If it does, append sequential numbers to the filename until we get a unique filename + string fullDestinationPath = Path.Combine(App.MediaLibraryPath(), relativeDestinationFolder, filename); + int fileVersion = 0; + string uniqueFilename = filename; + while (File.Exists(fullDestinationPath)) + { + fileVersion++; + string baseFilename = Path.GetFileNameWithoutExtension(filename); + uniqueFilename = $"{baseFilename} ({fileVersion}){Path.GetExtension(filename)}"; + fullDestinationPath = Path.Combine(App.MediaLibraryPath(), relativeDestinationFolder, uniqueFilename); } - var path = Path.Combine(App.MediaLibraryPath(), destinationFolder, filename); WebClient wc = new WebClient(); - wc.DownloadFile(uri, path); - return filename; + wc.DownloadFile(url, fullDestinationPath); + return uniqueFilename; } private static void _SpectatorShowHide(string thing, bool state) diff --git a/Assets/Scripts/API/ApiMethods.cs b/Assets/Scripts/API/ApiMethods.cs index 7d53f7dbac..bfde2c3f77 100644 --- a/Assets/Scripts/API/ApiMethods.cs +++ b/Assets/Scripts/API/ApiMethods.cs @@ -463,7 +463,19 @@ private static void SelectWidget(GrabWidget widget) [ApiEndpoint("model.position", "Move a model to the given coordinates")] public static void PositionModel(int index, Vector3 position) { - _PositionWidget(_GetActiveModel(index), position); + _SetWidgetPosition(_GetActiveModel(index), position); + } + + [ApiEndpoint("model.rotation", "Set a model's rotation to the given angles")] + public static void RotateModel(int index, Vector3 rotation) + { + _SetWidgetRotation(_GetActiveModel(index), rotation); + } + + [ApiEndpoint("model.scale", "Set a model's scale to the amount")] + public static void RotateModel(int index, float scale) + { + _SetWidgetScale(_GetActiveModel(index), scale); } [ApiEndpoint("brush.forcepainting", "When on, overrides the trigger so the brush is always painting")] @@ -475,7 +487,31 @@ public static void ForcePainting(bool active) [ApiEndpoint("image.position", "Move an image to the given coordinates")] public static void PositionImage(int index, Vector3 position) { - _PositionWidget(_GetActiveImage(index), position); + _SetWidgetPosition(_GetActiveImage(index), position); + } + + [ApiEndpoint("image.rotation", "Set a images rotation to the given angles")] + public static void RotateImage(int index, Vector3 rotation) + { + _SetWidgetRotation(_GetActiveImage(index), rotation); + } + + [ApiEndpoint("image.scale", "Set a images scale to the amount")] + public static void RotateImage(int index, float scale) + { + _SetWidgetScale(_GetActiveModel(index), scale); + } + + [ApiEndpoint("light.position", "Move a light to the given coordinates")] + public static void PositionLight(int index, Vector3 position) + { + _SetWidgetPosition(_GetActiveLight(index), position); + } + + [ApiEndpoint("light.rotation", "Set a light's rotation to the given angles")] + public static void RotateLight(int index, Vector3 rotation) + { + _SetWidgetRotation(_GetActiveLight(index), rotation); } // WIP diff --git a/Assets/Scripts/AsyncHelpers.cs b/Assets/Scripts/AsyncHelpers.cs new file mode 100644 index 0000000000..85563256a2 --- /dev/null +++ b/Assets/Scripts/AsyncHelpers.cs @@ -0,0 +1,138 @@ +// Source: https://social.msdn.microsoft.com/Forums/en-US/163ef755-ff7b-4ea5-b226-bbe8ef5f4796/is-there-a-pattern-for-calling-an-async-method-synchronously?forum=async + +using System; +using System.Threading; +using System.Threading.Tasks; +using System.Collections.Generic; + +namespace TiltBrush +{ + public static class AsyncHelpers + { + /// + /// Execute's an async Task method which has a void return value synchronously + /// + /// Task method to execute + public static void RunSync(Func task) + { + var oldContext = SynchronizationContext.Current; + var synch = new ExclusiveSynchronizationContext(); + SynchronizationContext.SetSynchronizationContext(synch); + synch.Post(async _ => + { + try + { + await task(); + } + catch (Exception e) + { + synch.InnerException = e; + throw; + } + finally + { + synch.EndMessageLoop(); + } + }, null); + synch.BeginMessageLoop(); + + SynchronizationContext.SetSynchronizationContext(oldContext); + } + + /// + /// Execute's an async Task method which has a T return type synchronously + /// + /// Return Type + /// Task method to execute + /// + public static T RunSync(Func> task) + { + var oldContext = SynchronizationContext.Current; + var synch = new ExclusiveSynchronizationContext(); + SynchronizationContext.SetSynchronizationContext(synch); + T ret = default(T); + synch.Post(async _ => + { + try + { + ret = await task(); + } + catch (Exception e) + { + synch.InnerException = e; + throw; + } + finally + { + synch.EndMessageLoop(); + } + }, null); + synch.BeginMessageLoop(); + SynchronizationContext.SetSynchronizationContext(oldContext); + return ret; + } + + private class ExclusiveSynchronizationContext : SynchronizationContext + { + private bool done; + public Exception InnerException { get; set; } + readonly AutoResetEvent workItemsWaiting = new AutoResetEvent(false); + + readonly Queue> items = + new Queue>(); + + public override void Send(SendOrPostCallback d, object state) + { + throw new NotSupportedException("We cannot send to our same thread"); + } + + public override void Post(SendOrPostCallback d, object state) + { + lock (items) + { + items.Enqueue(Tuple.Create(d, state)); + } + + workItemsWaiting.Set(); + } + + public void EndMessageLoop() + { + Post(_ => done = true, null); + } + + public void BeginMessageLoop() + { + while (!done) + { + Tuple task = null; + lock (items) + { + if (items.Count > 0) + { + task = items.Dequeue(); + } + } + + if (task != null) + { + task.Item1(task.Item2); + if (InnerException != null) // the method threw an exeption + { + throw new AggregateException("AsyncHelpers.Run method threw an exception.", InnerException); + } + } + else + { + workItemsWaiting.WaitOne(); + } + } + } + + public override SynchronizationContext CreateCopy() + { + return this; + } + } + } +} diff --git a/Assets/Scripts/AsyncHelpers.cs.meta b/Assets/Scripts/AsyncHelpers.cs.meta new file mode 100644 index 0000000000..b8c70d19ba --- /dev/null +++ b/Assets/Scripts/AsyncHelpers.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: c078396260e04a16bab28c6f8d34a827 +timeCreated: 1710174014 \ No newline at end of file diff --git a/Assets/Scripts/Commands/BreakModelApartCommand.cs b/Assets/Scripts/Commands/BreakModelApartCommand.cs new file mode 100644 index 0000000000..e0745abc45 --- /dev/null +++ b/Assets/Scripts/Commands/BreakModelApartCommand.cs @@ -0,0 +1,241 @@ +// Copyright 2024 The Open Brush Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System.Collections.Generic; +using System.Linq; +using UnityEngine; + +namespace TiltBrush +{ + + public class BreakModelApartCommand : BaseCommand + { + private ModelWidget m_InitialWidget; + private List m_NewModelWidgets; + private List m_NewLightWidgets; + private List m_NodePaths; + + override public bool NeedsSave + { + get => true; + } + + private static List ExtractPaths(Transform root) + { + List nodes = root.Cast().ToList(); + var resultPaths = new List(); + var nextNodes = new List(); + var validButNotAdded = new List(); + + // Prevent infinite loops + const int maxIterations = 1000; + int failsafe = 0; + + bool isValidSelf(Transform node) + { + // Skip UI elements (SceneLightGizmo presently) + if (node.gameObject.layer == LayerMask.NameToLayer("UI")) return false; + if (!node.gameObject.activeSelf) return false; + // Skip nodes with no valid children + if (node.GetComponent() == null && + node.GetComponent() == null) return false; + return true; + } + + bool isValid(Transform node) + { + // Skip UI elements (SceneLightGizmo presently) + if (node.gameObject.layer == LayerMask.NameToLayer("UI")) return false; + if (!node.gameObject.activeSelf) return false; + // Skip nodes with no valid children + if (node.GetComponentInChildren() == null && + node.GetComponentInChildren() == null) return false; + return true; + } + + bool hasValidDirectChildren(Transform node) + { + if (node.gameObject.activeInHierarchy == false) return false; + int count = 0; + foreach (Transform child in node) + { + if (!isValid(child)) continue; + count++; + } + return count > 0; + } + + bool isSubPath(string basePath, string potentialSubPath) + { + var baseParts = basePath.Split('/'); + var subParts = potentialSubPath.Split('/'); + + // If the potential subpath has more parts than the base path, it can't be a subpath + if (subParts.Length > baseParts.Length) + { + return false; + } + + for (int i = 0; i < subParts.Length; i++) + { + if (baseParts[i] != subParts[i]) + { + return false; + } + } + + return true; + } + + while (resultPaths.Count < 2 && failsafe < maxIterations) + { + + validButNotAdded.Clear(); + + foreach (var child in nodes) + { + if (isValidSelf(child) && hasValidDirectChildren(child)) // Both a leaf and a valid node + { + resultPaths.Add(GetHierarchyPath(root, child)); + // Add the children to the next level + nextNodes.AddRange(child.Cast().ToList()); + } + else if (isValidSelf(child)) // A leaf but not a valid node + { + resultPaths.Add(GetHierarchyPath(root, child)); + } + else if (hasValidDirectChildren(child)) // Not valid but children are + { + validButNotAdded.Add(child); + nextNodes.AddRange(child.Cast().ToList()); + } + } + + // Break if have no more levels + if (nextNodes.Count == 0) break; + + // If we found no meshes, continue to the next level + nodes = nextNodes.ToList(); // Clone the list + + nextNodes.Clear(); + failsafe++; + } + + // If the while loop has decided we're done. there might still be some valid nodes that we haven't added + foreach (var child in validButNotAdded) + { + resultPaths.Add(GetHierarchyPath(root, child)); + } + + // Add the mesh suffix to all nodes if their descendents are also in the list + for (var i = 0; i < resultPaths.Count; i++) + { + var path = resultPaths[i]; + for (var j = 0; j < resultPaths.Count; j++) + { + if (i == j) continue; + var pathToCompare = resultPaths[j]; + if (isSubPath(pathToCompare, path)) + { + resultPaths[i] = $"{path}.mesh"; + break; + } + } + } + + + return resultPaths; + } + + public BreakModelApartCommand(ModelWidget initialWidget, BaseCommand parent = null) : base(parent) + { + m_InitialWidget = initialWidget; + m_NewModelWidgets = new List(); + m_NewLightWidgets = new List(); + var root = initialWidget.GetComponentInChildren().transform; + m_NodePaths = ExtractPaths(root); + } + + private static string GetHierarchyPath(Transform root, Transform obj) + { + string path = "/" + obj.name; + while (obj.transform.parent != root) + { + obj = obj.transform.parent; + path = "/" + obj.name + path; + } + return path; + } + + protected override void OnRedo() + { + SelectionManager.m_Instance.DeselectWidgets(new List { m_InitialWidget }); + foreach (var path in m_NodePaths) + { + var newWidget = m_InitialWidget.Clone() as ModelWidget; + if (newWidget == null) continue; + var previousSubtree = newWidget.Subtree; + string newSubtree; + if (string.IsNullOrEmpty(previousSubtree)) + { + newSubtree = path; + } + else + { + // Join the previous subtree with the new path + // Remove the duplicate last part of the previous subtree + var parts = previousSubtree.Split('/'); + newSubtree = string.Join('/', parts.Take(parts.Length - 1)) + path; + } + newWidget.Subtree = newSubtree; + newWidget.name = $"{newWidget.name} Subtree:{path}"; + newWidget.SyncHierarchyToSubtree(previousSubtree); + newWidget.RegisterHighlight(); + newWidget.UpdateBatchInfo(); + + // If a ModelWidget contains no more meshes + // then try and convert it to multiple LightWidgets + var objModel = newWidget.GetComponentInChildren(); + if (objModel != null && objModel.NumMeshes == 0) + { + m_NewLightWidgets.AddRange(LightWidget.FromModelWidget(newWidget)); + } + else + { + SelectionManager.m_Instance.SelectWidget(newWidget); + m_NewModelWidgets.Add(newWidget); + } + } + m_InitialWidget.gameObject.SetActive(false); + } + + protected override void OnUndo() + { + SelectionManager.m_Instance.DeselectWidgets(m_NewModelWidgets); + foreach (var widget in m_NewModelWidgets) + { + WidgetManager.m_Instance.UnregisterGrabWidget(widget.gameObject); + Object.Destroy(widget.gameObject); + } + SelectionManager.m_Instance.DeselectWidgets(m_NewLightWidgets); + foreach (var widget in m_NewLightWidgets) + { + WidgetManager.m_Instance.UnregisterGrabWidget(widget.gameObject); + Object.Destroy(widget.gameObject); + } + m_InitialWidget.gameObject.SetActive(true); + SelectionManager.m_Instance.SelectWidget(m_InitialWidget); + } + } +} // namespace TiltBrush diff --git a/Assets/Scripts/Commands/BreakModelApartCommand.cs.meta b/Assets/Scripts/Commands/BreakModelApartCommand.cs.meta new file mode 100644 index 0000000000..2004045e01 --- /dev/null +++ b/Assets/Scripts/Commands/BreakModelApartCommand.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 2449ea75960c4454ad61d53a72bee16a +timeCreated: 1706797040 \ No newline at end of file diff --git a/Assets/Scripts/Commands/CreateWidgetCommand.cs b/Assets/Scripts/Commands/CreateWidgetCommand.cs index 22c82e0d82..aaefa81720 100644 --- a/Assets/Scripts/Commands/CreateWidgetCommand.cs +++ b/Assets/Scripts/Commands/CreateWidgetCommand.cs @@ -94,35 +94,28 @@ protected override void OnRedo() m_Widget = Object.Instantiate(m_Prefab); m_Widget.transform.position = m_SpawnXf.translation; - // Widget type specific initialization. - if (m_Widget is StencilWidget) + switch (m_Widget) { - m_Widget.transform.parent = m_Canvas.transform; - m_Widget.Show(true); - } - else if (m_Widget is ModelWidget) - { - // ModelWidget.Show(true) is not called here because the model must be assigned - // before it can be turned on. - } - else if (m_Widget is ImageWidget) - { - m_Widget.transform.parent = m_Canvas.transform; - m_Widget.Show(true); - } - else if (m_Widget is VideoWidget) - { - m_Widget.transform.parent = m_Canvas.transform; - m_Widget.Show(true); - } - else if (m_Widget is CameraPathWidget) - { - m_Widget.transform.parent = m_Canvas.transform; - m_Widget.transform.localPosition = Vector3.zero; - m_Widget.transform.localRotation = Quaternion.identity; - m_Widget.Show(true); - App.Switchboard.TriggerCameraPathCreated(); - WidgetManager.m_Instance.CameraPathsVisible = true; + // Widget type specific initialization. + case StencilWidget: + case LightWidget: + case ImageWidget: + case VideoWidget: + m_Widget.transform.parent = m_Canvas.transform; + m_Widget.Show(true); + break; + case ModelWidget: + // ModelWidget.Show(true) is not called here because the model must be assigned + // before it can be turned on. + break; + case CameraPathWidget: + m_Widget.transform.parent = m_Canvas.transform; + m_Widget.transform.localPosition = Vector3.zero; + m_Widget.transform.localRotation = Quaternion.identity; + m_Widget.Show(true); + App.Switchboard.TriggerCameraPathCreated(); + WidgetManager.m_Instance.CameraPathsVisible = true; + break; } m_Widget.InitIntroAnim(m_SpawnXf, m_EndXf, false, m_DesiredEndForward, m_ForceTransform, m_SnapGridSize, m_SnapAngle); diff --git a/Assets/Scripts/Export/BrushBaker.cs b/Assets/Scripts/Export/BrushBaker.cs new file mode 100644 index 0000000000..9e3a07112d --- /dev/null +++ b/Assets/Scripts/Export/BrushBaker.cs @@ -0,0 +1,99 @@ +using System; +using UnityEngine; +using System.Collections.Generic; +using System.Linq; +using Unity.Collections; + +public class BrushBaker : MonoBehaviour +{ + public List computeShaders; + public float squeezeAmount = 1.0f; // Set this to your desired squeeze amount + public static BrushBaker m_Instance; + + [Serializable] + public struct ComputeShaderMapping + { + public string name; + public Shader shader; + public string brushGuid; + public ComputeShader computeShader; + } + + void Start() + { + m_Instance = this; + } + + public Mesh ProcessMesh(Mesh mesh, string brushGuid) + { + ComputeShader computeShader; + try + { + computeShader = computeShaders.First(x => x.brushGuid == brushGuid).computeShader; + } + catch (InvalidOperationException e) + { + return mesh; + } + if (computeShader == null) return mesh; + + // Get the transformation matrix from the GameObject's transform + Matrix4x4 localToWorldtransformMatrix = transform.localToWorldMatrix; + Matrix4x4 worldToLocaltransformMatrix = transform.worldToLocalMatrix; + + // Set the matrix as a shader parameter + computeShader.SetMatrix("TransformObjectToWorld", localToWorldtransformMatrix); + computeShader.SetMatrix("TransformWorldToObject", worldToLocaltransformMatrix); + + NativeArray vertices = new NativeArray(mesh.vertices, Allocator.TempJob); + ComputeBuffer vertexBuffer = new ComputeBuffer(vertices.Length, sizeof(float) * 3); + vertexBuffer.SetData(vertices); + + NativeArray normals = new NativeArray(mesh.normals, Allocator.TempJob); + ComputeBuffer normalBuffer = new ComputeBuffer(normals.Length, sizeof(float) * 3); + normalBuffer.SetData(normals); + + // get color buffer as well + List colors = new List(); + mesh.GetColors(colors); + ComputeBuffer colorBuffer = new ComputeBuffer(colors.Count, sizeof(float) * 4); + colorBuffer.SetData(colors); + + List uvs = new List(); + mesh.GetUVs(0, uvs); + ComputeBuffer uvBuffer = new ComputeBuffer(uvs.Count, sizeof(float) * 3); + uvBuffer.SetData(uvs); + + // if we need texcoord1 + if (mesh.uv2.Length > 0) + { + List uv1s = new List(); + mesh.GetUVs(1, uv1s); + ComputeBuffer uv1Buffer = new ComputeBuffer(uv1s.Count, sizeof(float) * 4); + uv1Buffer.SetData(uv1s); + computeShader.SetBuffer(0, "uv1Buffer", uv1Buffer); + } + + computeShader.SetBuffer(0, "vertexBuffer", vertexBuffer); + computeShader.SetBuffer(0, "normalBuffer", normalBuffer); + computeShader.SetBuffer(0, "colorBuffer", colorBuffer); + computeShader.SetBuffer(0, "uvBuffer", uvBuffer); + computeShader.SetFloat("_SqueezeAmount", squeezeAmount); + + int threadGroups = Mathf.CeilToInt(mesh.vertices.Length / 8f); + computeShader.Dispatch(0, threadGroups, 1, 1); + + var newVerts = new Vector3[mesh.vertexCount]; + vertexBuffer.GetData(newVerts); + mesh.vertices = newVerts; + + vertexBuffer.Release(); + normalBuffer.Release(); + uvBuffer.Release(); + + vertices.Dispose(); + normals.Dispose(); + + return mesh; + } +} diff --git a/Assets/Scripts/Export/BrushBaker.cs.meta b/Assets/Scripts/Export/BrushBaker.cs.meta new file mode 100644 index 0000000000..2f33039d6b --- /dev/null +++ b/Assets/Scripts/Export/BrushBaker.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: d368cec5bd044465b36255fcc3090a66 +timeCreated: 1706098773 \ No newline at end of file diff --git a/Assets/Scripts/Export/EXT_blend_operations.cs b/Assets/Scripts/Export/EXT_blend_operations.cs new file mode 100644 index 0000000000..9962a19c02 --- /dev/null +++ b/Assets/Scripts/Export/EXT_blend_operations.cs @@ -0,0 +1,71 @@ +using System; +using GLTF.Schema; +using Newtonsoft.Json.Linq; +using UnityGLTF; + +namespace TiltBrush +{ + // See: + // https://github.com/icosa-mirror/UnityGLTF/issues/1 + + [Serializable] + public class EXT_blend_operations : IExtension + { + + public enum BlendOperation + { + Alpha, + Add, + Multiply, + } + + // Syntactic Sugar + public static EXT_blend_operations Alpha => new() { blendOperation = BlendOperation.Alpha }; + public static EXT_blend_operations Add => new() { blendOperation = BlendOperation.Add }; + public static EXT_blend_operations Multiply => new() { blendOperation = BlendOperation.Multiply }; + + public const string EXTENSION_NAME = nameof(EXT_blend_operations); + private GLTFSceneExporter exporter; + public BlendOperation blendOperation; + + public JProperty Serialize() + { + JProperty jProperty = new JProperty(EXTENSION_NAME, new JObject( + new JProperty("blendOperation", new JArray(blendOperation.ToString())) + )); + return jProperty; + } + + public IExtension Clone(GLTFRoot root) + { + return new EXT_blend_operations { blendOperation = blendOperation }; + } + + public class EXT_blend_operations_Factory : ExtensionFactory + { + public const string EXTENSION_NAME = nameof(EXT_blend_operations); + + public EXT_blend_operations_Factory() + { + ExtensionName = EXTENSION_NAME; + } + + public override IExtension Deserialize(GLTFRoot root, JProperty extensionToken) + { + if (extensionToken != null) + { + JToken blendOperation = extensionToken.Value[nameof(EXT_blend_operations.blendOperation)]; + var extension = new EXT_blend_operations(); + if (blendOperation != null) + { + var blendOpName = blendOperation.Value(); + extension.blendOperation = (BlendOperation)Enum.Parse(typeof(BlendOperation), blendOpName, true); + } + return extension; + } + return null; + } + } + } +} + diff --git a/Assets/Scripts/Export/EXT_blend_operations.cs.meta b/Assets/Scripts/Export/EXT_blend_operations.cs.meta new file mode 100644 index 0000000000..4752e1b3e3 --- /dev/null +++ b/Assets/Scripts/Export/EXT_blend_operations.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: e2be5ed6a49743bc8c0d638e50a11351 +timeCreated: 1706013136 \ No newline at end of file diff --git a/Assets/Scripts/Export/Export.cs b/Assets/Scripts/Export/Export.cs index 1dfa97d8e3..7f08b8acf3 100644 --- a/Assets/Scripts/Export/Export.cs +++ b/Assets/Scripts/Export/Export.cs @@ -15,9 +15,10 @@ using System; using System.Collections.Generic; using System.IO; +using System.Linq; using UnityEngine; -using UnityEngine.Localization; using UnityEngine.Localization.Settings; +using UnityGLTF; namespace TiltBrush { @@ -41,7 +42,7 @@ private static string MakeExportPath(string parent, string basename, string ext) { string child = FileUtils.GenerateNonexistentFilename(parent, basename: ext, extension: ""); if (!FileUtils.InitializeDirectoryWithUserError( - child, "Failed to create export directory for " + ext)) + child, "Failed to create export directory for " + ext)) { return null; } @@ -101,6 +102,29 @@ public void Dispose() } } + static bool IsExportEnabled(string format) + { + // I couldn't figure out how to get the default value from the config file for a dictionary with a getter/setter + // so I'm handling defaults here. + var formats = App.UserConfig.Export.Formats; + if (formats == null) + { + formats = new Dictionary + { + { "fbx", true }, + { "glb", true }, + { "newglb", false }, + { "json", false }, + { "latk", false }, + { "obj", true }, + { "stl", false }, + { "usd", false }, + { "wrl", false }, + }; + } + return formats.GetValueOrDefault(format); + } + public static void ExportScene() { var current = SaveLoadScript.m_Instance.SceneFile; @@ -110,37 +134,58 @@ public static void ExportScene() string parent = FileUtils.GenerateNonexistentFilename(App.UserExportPath(), basename, ""); if (!FileUtils.InitializeDirectoryWithUserError( - parent, "Failed to create export directory")) - { - return; - } + parent, "Failed to create export directory")) return; // Set up progress bar. var progress = new Progress(); - if (App.PlatformConfig.EnableExportJson) { progress.SetWork("json"); } + if (App.PlatformConfig.EnableExportJson && IsExportEnabled("json")) + { + progress.SetWork("json"); + } #if FBX_SUPPORTED - if (App.PlatformConfig.EnableExportFbx) { progress.SetWork("fbx"); } + if (App.PlatformConfig.EnableExportFbx && IsExportEnabled("fbx")) + { + progress.SetWork("fbx"); + } + if (IsExportEnabled("obj")) + { + progress.SetWork("obj"); + } #endif + #if USD_SUPPORTED - if (App.PlatformConfig.EnableExportUsd) { progress.SetWork("usd"); } -#endif -#if LATK_SUPPORTED - if (App.PlatformConfig.EnableExportLatk) { progress.SetWork("latk"); } + if (App.PlatformConfig.EnableExportUsd && IsExportEnabled("usd")) + { + progress.SetWork("usd"); + } #endif - if (Config.IsExperimental) + + if (IsExportEnabled("latk")) + { + progress.SetWork("latk"); + } + + if (IsExportEnabled("wrl")) { progress.SetWork("wrl"); + } + + if (IsExportEnabled("stl")) + { progress.SetWork("stl"); -#if FBX_SUPPORTED - progress.SetWork("obj"); -#endif } - if (App.PlatformConfig.EnableExportGlb) { progress.SetWork("glb"); } + + if (App.PlatformConfig.EnableExportGlb) + { + if (IsExportEnabled("glb")) { progress.SetWork("glb"); } + if (IsExportEnabled("newglb")) { progress.SetWork("newglb"); } + } string filename; - if (App.PlatformConfig.EnableExportJson && + if (App.PlatformConfig.EnableExportJson && IsExportEnabled("json") && (filename = MakeExportPath(parent, basename, "json")) != null) + { using (var unused = new AutoTimer("raw export")) { OverlayManager.m_Instance.UpdateProgress(0.1f); @@ -149,11 +194,13 @@ public static void ExportScene() // Also write the metadata that would normally go in the .tilt file SketchSnapshot.ExportMetadata(filename.Replace(".json", ".metadata.json")); } - progress.CompleteWork("json"); + progress.CompleteWork("json"); + } #if FBX_SUPPORTED - if (App.PlatformConfig.EnableExportFbx && + if (App.PlatformConfig.EnableExportFbx && IsExportEnabled("fbx") && (filename = MakeExportPath(parent, basename, "fbx")) != null) + { using (var unused = new AutoTimer("fbx export")) { OverlayManager.m_Instance.UpdateProgress(0.3f); @@ -162,37 +209,48 @@ public static void ExportScene() App.UserConfig.Export.ExportFbxVersion); OverlayManager.m_Instance.UpdateProgress(0.5f); } - progress.CompleteWork("fbx"); + progress.CompleteWork("fbx"); + } + + if (IsExportEnabled("obj") && App.PlatformConfig.EnableExportFbx && + (filename = MakeExportPath(parent, basename, "obj")) != null) + { + // This has never been tested with the new fbx export style and may not work + ExportFbx.Export(filename, ExportFbx.kObj); + progress.CompleteWork("obj"); + } #endif #if USD_SUPPORTED - if (App.PlatformConfig.EnableExportUsd && + if (App.PlatformConfig.EnableExportUsd && IsExportEnabled("usd") && (filename = MakeExportPath(parent, basename, "usd")) != null) + { using (var unused = new AutoTimer("usd export")) { ExportUsd.ExportPayload(filename); } - progress.CompleteWork("usd"); + progress.CompleteWork("usd"); + } #endif -#if LATK_SUPPORTED - if (App.PlatformConfig.EnableExportLatk && + if (IsExportEnabled("latk") && (filename = MakeExportPath(parent, basename, "latk")) != null) + { using (var unused = new AutoTimer("latk export")) { ExportLatk.Export(filename); } - progress.CompleteWork("latk"); -#endif + progress.CompleteWork("latk"); + } - if (Config.IsExperimental && + if (IsExportEnabled("wrl") && (filename = MakeExportPath(parent, basename, "wrl")) != null) { ExportVrml.Export(filename); progress.CompleteWork("wrl"); } - if (Config.IsExperimental && + if (IsExportEnabled("stl") && (filename = MakeExportPath(parent, basename, "stl")) != null) { try @@ -206,18 +264,7 @@ public static void ExportScene() progress.CompleteWork("stl"); } -#if FBX_SUPPORTED - if (Config.IsExperimental && - App.PlatformConfig.EnableExportFbx && - (filename = MakeExportPath(parent, basename, "obj")) != null) - { - // This has never been tested with the new fbx export style and may not work - ExportFbx.Export(filename, ExportFbx.kObj); - progress.CompleteWork("obj"); - } -#endif - - if (App.PlatformConfig.EnableExportGlb) + if (App.PlatformConfig.EnableExportGlb && IsExportEnabled("glb")) { string extension = App.Config.m_EnableGlbVersion2 ? "glb" : "glb1"; int gltfVersion = App.Config.m_EnableGlbVersion2 ? 2 : 1; @@ -226,24 +273,45 @@ public static void ExportScene() { using (var unused = new AutoTimer("glb export")) { - OverlayManager.m_Instance.UpdateProgress(0.7f); - var exporter = new ExportGlTF(); + OverlayManager.m_Instance.UpdateProgress(0.6f); + // TBT doesn't need (or want) brush textures in the output because it replaces all // the materials, so it's fine to keep those http:. However, Sketchfab doesn't support // http textures so if uploaded, this glb will have missing textures. + var exporter = new ExportGlTF(); exporter.ExportBrushStrokes( filename, AxisConvention.kGltf2, binary: true, doExtras: false, includeLocalMediaContent: true, gltfVersion: gltfVersion, selfContained: true ); - progress.CompleteWork("glb"); } } + progress.CompleteWork("glb"); + } + + if (App.PlatformConfig.EnableExportGlb && IsExportEnabled("newglb")) + { + string extension = "glb"; + using (var unused = new AutoTimer("glb export")) + { + OverlayManager.m_Instance.UpdateProgress(0.7f); + var settings = GLTFSettings.GetOrCreateSettings(); + settings.UseMainCameraVisibility = false; + var context = new ExportContext + { + ExportLayers = LayerMask.GetMask("MainCanvas") + }; + var layers = App.Scene.LayerCanvases.Select(x => x.transform).ToArray(); + var unityGltfexporter = new GLTFSceneExporter(layers, context); + unityGltfexporter.SaveGLB(Path.Combine(parent, $"newglb"), $"{basename}.{extension}"); + } + progress.CompleteWork("newglb"); } OutputWindowScript.m_Instance.CreateInfoCardAtController( - InputManager.ControllerName.Brush, basename + $" {LocalizationSettings.StringDatabase.GetLocalizedString(kExportSuccess)}"); + InputManager.ControllerName.Brush, basename + + $" {LocalizationSettings.StringDatabase.GetLocalizedString(kExportSuccess)}"); ControllerConsoleScript.m_Instance.AddNewLine("Located in " + App.UserExportPath()); string readmeFilename = Path.Combine(App.UserExportPath(), kExportReadmeName); @@ -253,5 +321,4 @@ public static void ExportScene() } } } - } // namespace TiltBrush diff --git a/Assets/Scripts/Export/ExportLatk.cs b/Assets/Scripts/Export/ExportLatk.cs index 0d835d783d..5b8316ece5 100644 --- a/Assets/Scripts/Export/ExportLatk.cs +++ b/Assets/Scripts/Export/ExportLatk.cs @@ -12,7 +12,6 @@ // See the License for the specific language governing permissions and // limitations under the License. -#if LATK_SUPPORTED using UnityEngine; using System.Collections; using System.Collections.Generic; @@ -245,4 +244,3 @@ private static void saveJsonAsZip(string fileName, string s) } } -#endif diff --git a/Assets/Scripts/Export/ImportMaterialCollector.cs b/Assets/Scripts/Export/ImportMaterialCollector.cs index c3eb7ae532..7bdd10a7a1 100644 --- a/Assets/Scripts/Export/ImportMaterialCollector.cs +++ b/Assets/Scripts/Export/ImportMaterialCollector.cs @@ -102,6 +102,21 @@ public void Add(Material unityMaterial) ? TbtSettings.Instance.m_PbrBlendDoubleSided : TbtSettings.Instance.m_PbrOpaqueDoubleSided; + Color color = Color.magenta; + bool hasColor = false; + if (unityMaterial.shader.name.StartsWith("UnityGLTF")) + { + if (unityMaterial.HasColor("baseColorFactor")) + { + color = unityMaterial.GetColor("baseColorFactor"); + hasColor = true; + } + } + if (!hasColor) + { + color = unityMaterial.color; + } + m_MaterialToIem.Add( unityMaterial, new DynamicExportableMaterial( @@ -110,7 +125,7 @@ public void Add(Material unityMaterial) uniqueName: MakeDeterministicUniqueName(m_numAdded++, unityMaterial.name), uriBase: m_AssetLocation) { - BaseColorFactor = unityMaterial.color + BaseColorFactor = color }); } diff --git a/Assets/Scripts/Export/OpenBrushExportPlugin.cs b/Assets/Scripts/Export/OpenBrushExportPlugin.cs new file mode 100644 index 0000000000..cc670471bd --- /dev/null +++ b/Assets/Scripts/Export/OpenBrushExportPlugin.cs @@ -0,0 +1,298 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using GLTF.Schema; +using Newtonsoft.Json.Linq; +using UnityEngine; +using UnityGLTF; +using UnityGLTF.Plugins; +using Object = UnityEngine.Object; + +namespace TiltBrush +{ + public class OpenBrushExportPlugin : GLTFExportPlugin + { + public override string DisplayName => "Open Brush Export"; + public override string Description => "Handles Open Brush specific export logic."; + public override bool EnabledByDefault => true; + + public override GLTFExportPluginContext CreateInstance(ExportContext context) + { + return new OpenBrushExportPluginConfig(); + } + } + + public class OpenBrushExportPluginConfig : GLTFExportPluginContext + { + private Dictionary _meshesToBatches; + + private List _ignoreList = new() + { + "SnapGrid3D", + "Preview Light" + }; + + public override void BeforeSceneExport(GLTFSceneExporter exporter, GLTFRoot gltfRoot) + { + SelectionManager.m_Instance.ClearActiveSelection(); + _meshesToBatches = new Dictionary(); + } + + private Transform GetOrCreateGroupTransform(CanvasScript layer, int group) + { + if (layer.transform.childCount == 0) + { + var groupTransform = new GameObject($"_StrokeGroup_{group}").transform; + groupTransform.parent = layer.transform; + groupTransform.localPosition = Vector3.zero; + groupTransform.localRotation = Quaternion.identity; + groupTransform.localScale = Vector3.one; + return groupTransform; + } + else + { + foreach (Transform child in layer.transform) + { + if (child.name == $"_StrokeGroup_{group}") + { + return child; + } + } + var groupTransform = new GameObject($"_StrokeGroup_{group}").transform; + groupTransform.parent = layer.transform; + groupTransform.localPosition = Vector3.zero; + groupTransform.localRotation = Quaternion.identity; + groupTransform.localScale = Vector3.one; + return groupTransform; + } + } + + public void BeforeLayerExport(Transform transform) + { + var canvas = transform.GetComponent(); + foreach (Transform child in transform) + { + if (_ignoreList.Contains(child.name)) + { + child.tag = "EditorOnly"; + } + + if (child.GetComponent() != null) + { + child.tag = "EditorOnly"; + } + } + + if (App.UserConfig.Export.KeepStrokes) + { + App.Config.m_UseBatchedBrushes = false; + foreach (var batch in canvas.BatchManager.AllBatches()) + { + var subsets = batch.m_Groups.ToArray(); + for (var i = 0; i < subsets.Length; i++) + { + var subset = subsets[i]; + var stroke = subset.m_Stroke; + stroke.m_IntendedCanvas = stroke.Canvas; + if (stroke.m_Type != Stroke.Type.BatchedBrushStroke) continue; + stroke.Uncreate(); + stroke.Recreate(null, canvas); + var mesh = stroke.m_Object.GetComponent().sharedMesh; + mesh = BrushBaker.m_Instance.ProcessMesh(mesh, stroke.m_BrushGuid.ToString()); + stroke.m_Object.GetComponent().sharedMesh = mesh; + stroke.m_Object.GetComponent().mesh = mesh; + stroke.m_Object.name = $"{stroke.m_Object.name}_{i}"; + if (App.UserConfig.Export.KeepGroups) + { + var group = stroke.Group.GetHashCode(); + var groupTransform = GetOrCreateGroupTransform(canvas, group); + stroke.m_Object.transform.SetParent(groupTransform, true); + } + } + batch.tag = "EditorOnly"; + } + canvas.BatchManager.FlushMeshUpdates(); + } + } + + public override void BeforeNodeExport(GLTFSceneExporter exporter, GLTFRoot gltfRoot, Transform transform, Node node) + { + if (transform.GetComponent() != null) + { + BeforeLayerExport(transform); + } + + if (!App.UserConfig.Export.KeepStrokes && App.UserConfig.Export.ExportStrokeMetadata) + { + // We'll need a way to find the batch for each mesh later + var batch = transform.GetComponent(); + var mf = transform.GetComponent(); + if (batch != null && mf != null) + { + var mesh = mf.sharedMesh; + _meshesToBatches[mesh.GetHashCode()] = batch; + } + } + } + + public void AfterLayerExport(Transform transform) + { + var canvas = transform.GetComponent(); + App.Config.m_UseBatchedBrushes = true; + if (App.UserConfig.Export.KeepStrokes) + { + foreach (var brushScript in canvas.transform.GetComponentsInChildren()) + { + var stroke = brushScript.Stroke; + if (stroke == null || stroke.m_Type != Stroke.Type.BrushStroke) continue; + var strokeGo = stroke.m_Object; + stroke.InvalidateCopy(); + stroke.Uncreate(); + stroke.Recreate(null, canvas); + if (stroke.m_BatchSubset != null) + { + stroke.m_BatchSubset.m_ParentBatch.transform.tag = "Untagged"; + } + SafeDestroy(strokeGo); + } + canvas.BatchManager.FlushMeshUpdates(); + + if (App.UserConfig.Export.KeepStrokes) + { + foreach (Transform child in canvas.transform) + { + if (child.name.StartsWith($"_StrokeGroup_")) + { + SafeDestroy(child.gameObject); + } + } + } + } + } + + public override void AfterNodeExport(GLTFSceneExporter exporter, GLTFRoot gltfRoot, Transform transform, Node node) + { + if (transform.GetComponent() != null) + { + AfterLayerExport(transform); + } + + if (App.UserConfig.Export.KeepStrokes && App.UserConfig.Export.ExportStrokeMetadata) + { + var brush = transform.GetComponent(); + if (brush != null) + { + Stroke stroke = brush.Stroke; + if (stroke != null && node.Mesh != null) + { + if (App.UserConfig.Export.ExportStrokeTimestamp) + { + var strokeInfo = new Dictionary(); + strokeInfo["HeadTimestampMs"] = stroke.HeadTimestampMs.ToString(); + strokeInfo["TailTimestampMs"] = stroke.TailTimestampMs.ToString(); + strokeInfo["Group"] = stroke.Group.GetHashCode().ToString(); + strokeInfo["Seed"] = stroke.m_Seed.ToString(); + strokeInfo["Color"] = stroke.m_Color.ToString(); + var primitiveExtras = new Dictionary> + { + ["ICOSA_strokeInfo"] = strokeInfo + }; + + node.Mesh.Value.Extras = JToken.FromObject(primitiveExtras); + } + } + } + } + else + { + try + { + if (node.Name.StartsWith("Batch_")) + { + var parts = node.Name.Split("_"); + Guid brushGuid = new Guid(parts.Last()); + string brushName = BrushCatalog.m_Instance.GetBrush(brushGuid).DurableName; + brushName = brushName.Replace(" ", "_").ToLower(); + node.Name = $"brush_{brushName}_{parts[1]}"; + node.Mesh.Value.Name = $"brush_{brushName}_{parts[1]}"; + } + } + catch (Exception e) + { + Debug.LogError($"Failed to rename node {node.Name} based on brush guid: {e.Message}"); + } + } + } + + public override void AfterPrimitiveExport(GLTFSceneExporter exporter, Mesh mesh, MeshPrimitive primitive, int index) + { + if (App.UserConfig.Export.ExportStrokeMetadata) + { + if (App.UserConfig.Export.KeepStrokes) + { + Batch batch; + var result = _meshesToBatches.TryGetValue(mesh.GetHashCode(), out batch); + if (result) + { + var batchInfo = new List>(); + foreach (var subset in batch.m_Groups) + { + var subsetInfo = new Dictionary(); + subsetInfo["StartVertIndex"] = subset.m_StartVertIndex.ToString(); + subsetInfo["VertLength"] = subset.m_VertLength.ToString(); + subsetInfo["HeadTimestampMs"] = subset.m_Stroke.HeadTimestampMs.ToString(); + subsetInfo["TailTimestampMs"] = subset.m_Stroke.TailTimestampMs.ToString(); + subsetInfo["Group"] = subset.m_Stroke.Group.GetHashCode().ToString(); + subsetInfo["Seed"] = subset.m_Stroke.m_Seed.ToString(); + subsetInfo["Color"] = subset.m_Stroke.m_Color.ToString(); + batchInfo.Add(subsetInfo); + } + var primitiveExtras = new Dictionary>> + { + ["ICOSA_batchInfo"] = batchInfo + }; + primitive.Extras = JToken.FromObject(primitiveExtras); + } + } + } + } + + void AddExtension(GLTFMaterial materialNode, IExtension blend) + { + if (materialNode.Extensions == null) + materialNode.Extensions = new Dictionary(); + materialNode.Extensions.Add(EXT_blend_operations.EXTENSION_NAME, blend); + } + + public override void AfterMaterialExport(GLTFSceneExporter exporter, GLTFRoot gltfRoot, Material material, GLTFMaterial materialNode) + { + // Only handle brush materials + if (!material.shader.name.StartsWith("Brush/")) return; + + // Strip the (Instance) suffix from the material node name + materialNode.Name = materialNode.Name.Replace("(Instance)", "").Trim(); + materialNode.Name = $"ob-{materialNode.Name}"; + + var brush = BrushCatalog.m_Instance.AllBrushes.FirstOrDefault(b => b.DurableName == materialNode.Name); + + if (brush != null && brush.BlendMode == ExportableMaterialBlendMode.AdditiveBlend) + { + AddExtension(materialNode, EXT_blend_operations.Add); + } + } + + public override void AfterSceneExport(GLTFSceneExporter exporter, GLTFRoot gltfRoot) + { + gltfRoot.Asset.Generator = $"Open Brush UnityGLTF Exporter {App.Config.m_VersionNumber}.{App.Config.m_BuildStamp})"; + } + + private static void SafeDestroy(Object o) + { + if (!o) return; + if (Application.isPlaying) + Object.Destroy(o); + else + Object.DestroyImmediate(o); + } + } +} diff --git a/Assets/Scripts/Export/OpenBrushExportPlugin.cs.meta b/Assets/Scripts/Export/OpenBrushExportPlugin.cs.meta new file mode 100644 index 0000000000..06c8bbe15f --- /dev/null +++ b/Assets/Scripts/Export/OpenBrushExportPlugin.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c261146868c45eb4eb6b9987bd8c9084 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/GUI/ModelButton.cs b/Assets/Scripts/GUI/ModelButton.cs index 1955571299..f92a448ac0 100644 --- a/Assets/Scripts/GUI/ModelButton.cs +++ b/Assets/Scripts/GUI/ModelButton.cs @@ -57,6 +57,11 @@ public void CreatePreviewModel() // Build the actual preview. m_ModelPreview = Instantiate(m_Model.m_ModelParent); + // Disable model lights when it's a panel preview + foreach (var light in m_ModelPreview.GetComponentsInChildren()) + { + light.enabled = false; + } HierarchyUtils.RecursivelySetLayer(m_ModelPreview, LayerMask.NameToLayer("Panels")); m_ModelPreview.gameObject.SetActive(true); var animationComponent = m_ModelPreview.GetComponentInChildren(); @@ -165,8 +170,8 @@ protected void SpawnValidModel(Model model) ModelWidget modelWidget = createCommand.Widget as ModelWidget; modelWidget.Model = model; modelWidget.Show(true); + modelWidget.AddSceneLightGizmos(); createCommand.SetWidgetCost(modelWidget.GetTiltMeterCost()); - WidgetManager.m_Instance.WidgetsDormant = false; SketchControlsScript.m_Instance.EatGazeObjectInput(); SelectionManager.m_Instance.RemoveFromSelection(false); diff --git a/Assets/Scripts/ImportGltfast.cs b/Assets/Scripts/ImportGltfast.cs index 42a647748b..a557a83ff2 100644 --- a/Assets/Scripts/ImportGltfast.cs +++ b/Assets/Scripts/ImportGltfast.cs @@ -1,14 +1,28 @@ -using System; +// Copyright 2024 The Open Brush Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System; using System.Collections.Generic; -using System.IO; -using System.Linq; using System.Threading.Tasks; using GLTFast; using TiltBrushToolkit; using UnityEngine; +using UnityGLTF; + namespace TiltBrush { - internal class ImportGltfast + internal class NewGltfImporter { public static ImportState BeginImport(string localPath) { @@ -18,6 +32,7 @@ public static ImportState BeginImport(string localPath) var state = new ImportState(AxisConvention.kGltf2); return state; } + public sealed class ImportState : IDisposable { // Change-of-basis matrix @@ -39,58 +54,88 @@ public void Dispose() } } - internal class GltfImportResult + public static Task StartSyncImport(string localPath, string assetLocation, Model model, List warnings) { - public GameObject root; - public ImportMaterialCollector materialCollector; + return App.UserConfig.Import.UseUnityGltf ? + _ImportUsingUnityGltf(localPath, assetLocation, model, warnings) : + _ImportUsingGltfast(localPath, assetLocation, model, warnings); } - public static GltfImportResult EndAsyncImport(ImportState state) + private static GameObject _ImportUsingLegacyGltf(string localPath, string assetLocation) { - var result = new GltfImportResult(); - result.root = state.root; - return result; + var loader = new TiltBrushUriLoader(localPath, assetLocation, loadImages: false); + var materialCollector = new ImportMaterialCollector(assetLocation, uniqueSeed: localPath); + var importOptions = new GltfImportOptions + { + rescalingMode = GltfImportOptions.RescalingMode.CONVERT, + scaleFactor = App.METERS_TO_UNITS, + recenter = false + }; + ImportGltf.GltfImportResult result = ImportGltf.Import(localPath, loader, materialCollector, importOptions); + return result.root; } - public static async Task StartSyncImport( + private static async Task _ImportUsingGltfast( string localPath, string assetLocation, Model model, List warnings) { var gltf = new GltfImport(); - var importMaterialCollector = new ImportMaterialCollector(assetLocation, uniqueSeed: localPath); bool success = await gltf.Load(localPath); var go = new GameObject(); if (success) { - success = await gltf.InstantiateMainSceneAsync(go.transform); + var settings = new InstantiationSettings + { + LightIntensityFactor = 0.0001f, + Mask = ~ComponentType.Camera + }; + success = await gltf.InstantiateMainSceneAsync( + new GameObjectInstantiator(gltf, go.transform, null, settings) + ); } if (success) { - var result = new GltfImportResult(); - result.root = go; - result.materialCollector = importMaterialCollector; + model.CalcBoundsGltf(go); + model.EndCreatePrefab(go, warnings); } else { + Debug.LogError("Failed to import using GLTFast. Falling back to legacy import"); // Fall back to the older import code - var loader = new TiltBrushUriLoader(localPath, assetLocation, loadImages: false); + go = _ImportUsingLegacyGltf(localPath, assetLocation); + model.CalcBoundsGltf(go); + model.EndCreatePrefab(go, warnings); + } + } - var materialCollector = new ImportMaterialCollector(assetLocation, uniqueSeed: localPath); - var importOptions = new GltfImportOptions - { - rescalingMode = GltfImportOptions.RescalingMode.CONVERT, - scaleFactor = App.METERS_TO_UNITS, - recenter = false - }; - ImportGltf.GltfImportResult result = ImportGltf.Import(localPath, loader, materialCollector, importOptions); - go = result.root; + private static async Task _ImportUsingUnityGltf( + string localPath, + string assetLocation, + Model model, + List warnings) + { + try + { + ImportOptions options = new ImportOptions(); + GLTFSceneImporter gltf = new GLTFSceneImporter(localPath, options); + + gltf.IsMultithreaded = false; + AsyncHelpers.RunSync(() => gltf.LoadSceneAsync()); + GameObject go = gltf.CreatedObject; + model.CalcBoundsGltf(go); + model.EndCreatePrefab(go, warnings); + } + catch (Exception e) + { + Debug.LogError("Failed to import using UnityGltf. Falling back to legacy import"); + // Fall back to the older import code + GameObject go = _ImportUsingLegacyGltf(localPath, assetLocation); + model.CalcBoundsGltf(go); + model.EndCreatePrefab(go, warnings); } - model.CalcBoundsGltf(go); - model.EndCreatePrefab(go, warnings); - if (success) model.AssignMaterialsToCollector(importMaterialCollector); } } } diff --git a/Assets/Scripts/Model.cs b/Assets/Scripts/Model.cs index 760ab1ef7e..f913957b05 100644 --- a/Assets/Scripts/Model.cs +++ b/Assets/Scripts/Model.cs @@ -21,6 +21,7 @@ using System.Linq; using System.Threading.Tasks; using TiltBrushToolkit; +using Unity.VectorGraphics; using Debug = UnityEngine.Debug; using UObject = UnityEngine.Object; @@ -45,10 +46,23 @@ public enum Type public static Location File(string relativePath) { + int lastIndex = relativePath.LastIndexOf('#'); + string path, fragment; + + if (lastIndex == -1) + { + path = relativePath; + fragment = null; + } + else + { + path = relativePath.Substring(0, lastIndex); + fragment = relativePath.Substring(lastIndex + 1); + } return new Location { type = Type.LocalFile, - path = relativePath + path = path, }; } @@ -92,6 +106,8 @@ public string RelativePath } } + public string Extension => Path.GetExtension(AbsolutePath).ToLower(); + public string AssetId { get @@ -110,14 +126,16 @@ public override int GetHashCode() public override string ToString() { + string str; if (type == Type.PolyAssetId) { - return $"{type}:{id}"; + str = $"{type}:{id}"; } else { - return $"{type}:{path}"; + str = $"{type}:{path}"; } + return str; } public override bool Equals(object obj) @@ -226,8 +244,7 @@ public bool AllowExport /// Only allowed if AllowExport = true public IExportableMaterial GetExportableMaterial(Material material) { - // TODO: Maybe throw InvalidOperation if AllowExport==false rather than blowing - // up with NullReference? + EnsureCollectorExists(); return m_ImportMaterialCollector.GetExportableMaterial(material); } @@ -339,6 +356,10 @@ public bool TryEndAsyncLoad(out GameObject root, { return false; } + m_ImportMaterialCollector = new ImportMaterialCollector( + Path.GetDirectoryName(m_localPath), + uniqueSeed: m_localPath + ); m_meshEnumerator = enumerable.GetEnumerator(); m_root.SetActive(false); } @@ -409,7 +430,7 @@ protected override IDisposable DoBackgroundThreadWork() var loader = new TiltBrushUriLoader( m_localPath, Path.GetDirectoryName(m_localPath), m_useThreadedImageLoad); var options = m_fromPoly ? kPolyGltfImportOptions : kGltfImportOptions; - return ImportGltfast.BeginImport(m_localPath); + return NewGltfImporter.BeginImport(m_localPath); } protected override GameObject DoUnityThreadWork(IDisposable state__, @@ -422,19 +443,14 @@ out ImportMaterialCollector GameObject rootObject = null; using (IDisposable state_ = state__) { - var state = state_ as ImportGltfast.ImportState; + var state = state_ as NewGltfImporter.ImportState; if (state != null) { string assetLocation = Path.GetDirectoryName(m_localPath); // EndImport doesn't try to use the loadImages functionality of UriLoader anyway. // It knows it's on the main thread, so chooses to use Unity's fast loading. - ImportGltfast.GltfImportResult result = ImportGltfast.EndAsyncImport(state); - - if (result != null) - { - rootObject = result.root; - importMaterialCollector = result.materialCollector; - } + rootObject = state.root; + importMaterialCollector = new ImportMaterialCollector(assetLocation, uniqueSeed: m_localPath); } } IsValid = rootObject != null; @@ -473,6 +489,28 @@ GameObject LoadPly(List warningsOut) } + GameObject LoadSvg(List warningsOut, out SVGParser.SceneInfo sceneInfo) + { + try + { + var reader = new SvgMeshReader(m_Location.AbsolutePath); + var (gameObject, warnings, collector, si) = reader.Import(); + sceneInfo = si; + warningsOut.AddRange(warnings); + m_ImportMaterialCollector = collector; + m_AllowExport = (m_ImportMaterialCollector != null); + return gameObject; + } + catch (Exception ex) + { + m_LoadError = new LoadError("Invalid data", ex.Message); + m_AllowExport = false; + Debug.LogException(ex); + sceneInfo = new SVGParser.SceneInfo(); + return null; + } + } + /// Load model using FBX SDK. GameObject LoadFbx(List warningsOut) { @@ -505,8 +543,7 @@ async Task LoadGltf(List warnings) string assetLocation = Path.GetDirectoryName(localPath); try { - - Task t = ImportGltfast.StartSyncImport( + Task t = NewGltfImporter.StartSyncImport( localPath, assetLocation, this, @@ -514,7 +551,6 @@ async Task LoadGltf(List warnings) ); m_AllowExport = true; await t; - } catch (Exception ex) { @@ -552,7 +588,7 @@ public void LoadModelAsync(bool useThreadedImageLoad) // Experimental usd loading. if (allowUsd && m_Location.GetLocationType() == Location.Type.LocalFile && - Path.GetExtension(m_Location.AbsolutePath).ToLower().StartsWith(".usd")) + m_Location.Extension == ".usd") { throw new NotImplementedException(); } @@ -622,6 +658,8 @@ public bool TryLoadModel() StartCreatePrefab(go); } + AssignMaterialsToCollector(m_ImportMaterialCollector); + // Even if an exception occurs above, return true because the return value indicates async load // is complete. return true; @@ -666,9 +704,9 @@ private async Task StartCreatePrefab(GameObject go) // and bail at a higher level, and require as a precondition that error == null m_LoadError = null; - string ext = Path.GetExtension(m_Location.AbsolutePath).ToLower(); + string ext = m_Location.Extension; if (m_Location.GetLocationType() == Location.Type.LocalFile && - ext.StartsWith(".usd")) + ext == ".usd") { // Experimental usd loading. go = LoadUsd(warnings); @@ -678,13 +716,9 @@ private async Task StartCreatePrefab(GameObject go) else if (m_Location.GetLocationType() == Location.Type.PolyAssetId || ext == ".gltf2" || ext == ".gltf" || ext == ".glb") { - - // If we pulled this from Poly, it's going to be a gltf file. Task t = LoadGltf(warnings); await t; - - } else if (ext == ".fbx" || ext == ".obj") { @@ -698,6 +732,13 @@ private async Task StartCreatePrefab(GameObject go) CalcBoundsNonGltf(go); EndCreatePrefab(go, warnings); } + else if (ext == ".svg") + { + go = LoadSvg(warnings, out SVGParser.SceneInfo sceneInfo); + CalcBoundsNonGltf(go); + EndCreatePrefab(go, warnings); + go.GetComponent().SvgSceneInfo = sceneInfo; + } else { m_LoadError = new LoadError("Unknown format", ext); @@ -903,5 +944,18 @@ public void AssignMaterialsToCollector(ImportMaterialCollector collector) } } } + + public void EnsureCollectorExists() + { + if (m_ImportMaterialCollector == null) + { + var localPath = GetLocation().AbsolutePath; + m_ImportMaterialCollector = new ImportMaterialCollector( + Path.GetDirectoryName(localPath), + uniqueSeed: localPath + ); + AssignMaterialsToCollector(m_ImportMaterialCollector); + } + } } } // namespace TiltBrush; diff --git a/Assets/Scripts/ModelCatalog.cs b/Assets/Scripts/ModelCatalog.cs index 37b66c4ffc..4a8b7aea07 100644 --- a/Assets/Scripts/ModelCatalog.cs +++ b/Assets/Scripts/ModelCatalog.cs @@ -216,13 +216,13 @@ public void LoadModels() if (m_MissingModelsByRelativePath.ContainsKey(relativePath)) { ModelWidget.CreateModelsFromRelativePath( - relativePath, null, m_MissingModelsByRelativePath[relativePath], null, null, null); + relativePath, null, null, m_MissingModelsByRelativePath[relativePath], null, null, null); m_MissingModelsByRelativePath.Remove(relativePath); } if (m_MissingNormalizedModelsByRelativePath.ContainsKey(relativePath)) { ModelWidget.CreateModelsFromRelativePath( - relativePath, m_MissingNormalizedModelsByRelativePath[relativePath], null, null, null, null); + relativePath, null, m_MissingNormalizedModelsByRelativePath[relativePath], null, null, null, null); m_MissingModelsByRelativePath.Remove(relativePath); } } @@ -253,13 +253,13 @@ public void LoadModelsForNewDirectory(string path) if (m_MissingModelsByRelativePath.ContainsKey(relativePath)) { ModelWidget.CreateModelsFromRelativePath( - relativePath, null, m_MissingModelsByRelativePath[relativePath], null, null, null); + relativePath, null, m_MissingModelsByRelativePath[relativePath], null, null, null, null); m_MissingModelsByRelativePath.Remove(relativePath); } if (m_MissingNormalizedModelsByRelativePath.ContainsKey(relativePath)) { ModelWidget.CreateModelsFromRelativePath( - relativePath, m_MissingNormalizedModelsByRelativePath[relativePath], null, null, null, null); + relativePath, null, m_MissingNormalizedModelsByRelativePath[relativePath], null, null, null, null); m_MissingModelsByRelativePath.Remove(relativePath); } } @@ -292,7 +292,7 @@ void ProcessDirectory(string sPath, Dictionary oldModels) { string[] aFiles = Directory.GetFiles(sPath); // Models we download from Poly are called ".gltf2", but ".gltf" is more standard - List extensions = new() { ".gltf2", ".gltf", ".glb", ".ply" }; + List extensions = new() { ".gltf2", ".gltf", ".glb", ".ply", ".svg" }; #if USD_SUPPORTED extensions.AddRange(new [] { ".usda", ".usdc", ".usd" }); diff --git a/Assets/Scripts/ObjModelScript.cs b/Assets/Scripts/ObjModelScript.cs index 06057c9a9e..b398fa17b4 100644 --- a/Assets/Scripts/ObjModelScript.cs +++ b/Assets/Scripts/ObjModelScript.cs @@ -15,6 +15,7 @@ using UnityEngine; using System.Collections.Generic; using GLTFast.Schema; +using Unity.VectorGraphics; namespace TiltBrush { @@ -38,6 +39,7 @@ public int NumMeshes { get { return m_MeshChildren.Length + m_SkinnedMeshChildren.Length; } } + public SVGParser.SceneInfo SvgSceneInfo { get; set; } public int GetNumVertsInMeshes() { @@ -74,7 +76,10 @@ private static void GetAllMeshes(List filters, List(); var meshRenderer = t.GetComponent(); - if (meshFilter != null && meshRenderer != null && meshFilter.sharedMesh != null) + if (meshFilter != null && + meshRenderer != null && + meshFilter.sharedMesh != null && + meshFilter.gameObject.layer != LayerMask.NameToLayer("UI")) { filters.Add(meshFilter); } diff --git a/Assets/Scripts/OpenBrushLightsImport.cs b/Assets/Scripts/OpenBrushLightsImport.cs new file mode 100644 index 0000000000..7fa0f66813 --- /dev/null +++ b/Assets/Scripts/OpenBrushLightsImport.cs @@ -0,0 +1,55 @@ +using GLTF.Schema; +using GLTF.Schema.KHR_lights_punctual; +using UnityEngine; +using LightType = UnityEngine.LightType; +namespace UnityGLTF.Plugins +{ + public class OpenBrushLightsImport : GLTFImportPlugin + { + public override string DisplayName => "Open Brush Lights"; + public override string Description => "Customized import behaviour for lights."; + public override GLTFImportPluginContext CreateInstance(GLTFImportContext context) + { + return new OpenBrushLightsImportContext(); + } + } + + public class OpenBrushLightsImportContext : GLTFImportPluginContext + { + public override void OnAfterImportNode(Node node, int nodeIndex, GameObject nodeObject) + { + base.OnAfterImportNode(node, nodeIndex, nodeObject); + var light = nodeObject.GetComponent(); + if (light == null || + node.Extensions == null || + !node.Extensions.ContainsKey("KHR_lights_punctual")) + { + return; + } + + if (node.Extensions["KHR_lights_punctual"] is KHR_LightsPunctualNodeExtension lightExtension) + { + var intensity = (float)lightExtension.LightId.Value.Intensity; + var range = (float)lightExtension.LightId.Value.Range; + // Should be infinite but Unity doesn't support that. + // float.MaxValue is too big and Unity interprets it as 0. + if (range <= 0) range = 2e+5f; + + switch (light.type) + { + case LightType.Directional: + light.intensity = intensity * 0.001f; + break; + case LightType.Point: + light.range = range; + light.intensity = intensity * 0.00001f; + break; + case LightType.Spot: + light.range = range; + light.intensity = intensity * 0.00001f; + break; + } + } + } + } +} \ No newline at end of file diff --git a/Assets/Scripts/OpenBrushLightsImport.cs.meta b/Assets/Scripts/OpenBrushLightsImport.cs.meta new file mode 100644 index 0000000000..2656e30411 --- /dev/null +++ b/Assets/Scripts/OpenBrushLightsImport.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 6843a59b1a844430b7b7c08e8711a6d7 +timeCreated: 1710234295 \ No newline at end of file diff --git a/Assets/Scripts/PlatformConfig.cs b/Assets/Scripts/PlatformConfig.cs index e1ec1c2b3d..37a0b583cc 100644 --- a/Assets/Scripts/PlatformConfig.cs +++ b/Assets/Scripts/PlatformConfig.cs @@ -73,8 +73,6 @@ public class PlatformConfig : ScriptableObject public bool EnableExportJson; // Usd export will crash if the usd libraries aren't available public bool EnableExportUsd; - // Latk export - public bool EnableExportLatk = true; // Trade off increased disk-space and export time for reduced memory public bool EnableExportMemoryOptimization; diff --git a/Assets/Scripts/ReferenceImage.cs b/Assets/Scripts/ReferenceImage.cs index c6ba74007a..420b4fa2d8 100644 --- a/Assets/Scripts/ReferenceImage.cs +++ b/Assets/Scripts/ReferenceImage.cs @@ -47,6 +47,9 @@ private enum ImageState private int m_FullSizeReferences = 0; private float m_ImageAspect; // only valid if ImageState == Ready private string m_Path; + private SVGParser.SceneInfo _SvgSceneInfo; + + // public bool IsComposite => _SvgSceneInfo.Scene.Root.getsh public string FileName { get { return Path.GetFileName(m_Path); } } public string FileFullPath { get { return m_Path; } } @@ -130,6 +133,7 @@ public void AcquireImageFullsize(bool runForeground = false) { // TODO Move into the async code path? var importer = new RuntimeSVGImporter(); + _SvgSceneInfo = importer.ParseToSceneInfo(File.ReadAllText(FilePath)); m_FullSize = importer.ImportAsTexture(FilePath); ImageCache.SaveImageCache(m_FullSize, FilePath); } diff --git a/Assets/Scripts/Save/MetadataUtils.cs b/Assets/Scripts/Save/MetadataUtils.cs index c80f2a213b..cbd034561d 100644 --- a/Assets/Scripts/Save/MetadataUtils.cs +++ b/Assets/Scripts/Save/MetadataUtils.cs @@ -24,6 +24,7 @@ public static class MetadataUtils public struct WidgetMetadata { public TrTransform xf; + public string subtree; public bool pinned; public bool tinted; public uint groupId; @@ -107,6 +108,7 @@ public static TiltModels75[] GetTiltModels(GroupIdMapping groupIdMapping) { WidgetMetadata newEntry = new WidgetMetadata(); newEntry.xf = widget.GetSaveTransform(); + newEntry.subtree = widget.Subtree; newEntry.pinned = widget.Pinned; newEntry.groupId = groupIdMapping.GetId(widget.Group); newEntry.layerId = App.Scene.GetIndexOfCanvas(widget.Canvas); @@ -124,11 +126,13 @@ public static TiltModels75[] GetTiltModels(GroupIdMapping groupIdMapping) // Order and align the metadata. WidgetMetadata[] ordered = elem.Value.OrderBy(ByTranslation).ToArray(); val.PinStates = new bool[ordered.Length]; + val.Subtrees = new string[ordered.Length]; val.RawTransforms = new TrTransform[ordered.Length]; val.GroupIds = new uint[ordered.Length]; val.LayerIds = new int[ordered.Length]; for (int i = 0; i < ordered.Length; ++i) { + val.Subtrees[i] = ordered[i].subtree; val.PinStates[i] = ordered[i].pinned; val.RawTransforms[i] = ordered[i].xf; val.GroupIds[i] = ordered[i].groupId; @@ -201,6 +205,45 @@ public static Guides[] GetGuideIndex(GroupIdMapping groupIdMapping) return guideIndex.OrderBy(g => g.Type).ToArray(); } + public static TiltLights[] GetTiltLights(GroupIdMapping groupIdMapping) + { + var imports = WidgetManager.m_Instance.LightWidgets + .Where(w => w.gameObject.activeSelf).ToArray(); + if (imports.Length == 0) + { + return null; + } + + var lightIndex = new List(); + foreach (var lightWidget in imports) + { + var light = lightWidget.GetComponentInChildren(); + var newEntry = new TiltLights(); + newEntry.Transform = lightWidget.GetSaveTransform(); + newEntry.Pinned = lightWidget.Pinned; + newEntry.GroupId = groupIdMapping.GetId(lightWidget.Group); + newEntry.LayerId = App.Scene.GetIndexOfCanvas(lightWidget.Canvas); + + newEntry.PunctualLightType = light.type; + newEntry.Intensity = light.intensity; + newEntry.LightColor = light.color; + + if (light.type == LightType.Spot) + { + newEntry.InnerConeAngle = light.innerSpotAngle; + newEntry.OuterConeAngle = light.spotAngle; + } + + if (light.type == LightType.Point || light.type == LightType.Spot) + { + newEntry.Range = light.range; + } + + lightIndex.Add(newEntry); + } + return lightIndex.ToArray(); + } + public static TiltImages75[] GetTiltImages(GroupIdMapping groupIdMapping) { var imports = WidgetManager.m_Instance.ImageWidgets diff --git a/Assets/Scripts/Save/SaveLoadScript.cs b/Assets/Scripts/Save/SaveLoadScript.cs index 3aab4c4728..3b4525b418 100644 --- a/Assets/Scripts/Save/SaveLoadScript.cs +++ b/Assets/Scripts/Save/SaveLoadScript.cs @@ -738,6 +738,16 @@ public bool Load(SceneFileInfo fileInfo, bool bAdditive = false) WidgetManager.m_Instance.SetDataFromTilt(jsonData.ModelIndex); } + if (jsonData.ModelIndex != null) + { + WidgetManager.m_Instance.SetDataFromTilt(jsonData.ModelIndex); + } + + if (jsonData.LightIndex != null) + { + WidgetManager.m_Instance.SetDataFromTilt(jsonData.LightIndex); + } + if (jsonData.GuideIndex != null) { foreach (Guides guides in jsonData.GuideIndex) @@ -752,6 +762,7 @@ public bool Load(SceneFileInfo fileInfo, bool bAdditive = false) // Pass even if null; null is treated as empty CustomColorPaletteStorage.m_Instance.SetColorsFromPalette(jsonData.Palette); // Images are not stored on Poly either. + // TODO - will this assumption still hold with Icosa? if (!(fileInfo is PolySceneFileInfo)) { if (ReferenceImageCatalog.m_Instance != null && jsonData.ImageIndex != null) @@ -794,7 +805,10 @@ public SketchMetadata DeserializeMetadata(JsonTextReader jsonReader) { m_LastJsonMetadatError = null; var metadata = m_JsonSerializer.Deserialize(jsonReader); - MetadataUtils.VerifyMetadataVersion(metadata); + if (metadata != null) + { + MetadataUtils.VerifyMetadataVersion(metadata); + } return metadata; } diff --git a/Assets/Scripts/Save/SketchMetadata.cs b/Assets/Scripts/Save/SketchMetadata.cs index 2fbe31acad..b20cfe80c3 100644 --- a/Assets/Scripts/Save/SketchMetadata.cs +++ b/Assets/Scripts/Save/SketchMetadata.cs @@ -372,6 +372,9 @@ public class TiltModels75 [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public TrTransform[] Transforms { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public string[] Subtrees { get; set; } + /// Prior to M13, always null. /// Post M13, never null or empty; but an empty array is allowed on read. [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] @@ -629,6 +632,23 @@ public TiltImages75 Upgrade() } } + [Serializable] + public class TiltLights + { + public Color? LightColor; + public float? Intensity; + public LightType PunctualLightType; + public float? Range; + public float? InnerConeAngle; + public float? OuterConeAngle; + + public bool Pinned; + public TrTransform Transform; + // Group ID for widget. 0 for ungrouped items. + public uint GroupId { get; set; } + public int LayerId { get; set; } + } + [Serializable] public class TiltImages75 { @@ -744,6 +764,9 @@ public TiltModels70[] Models [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] public TiltModels75[] ModelIndex { get; set; } + [JsonProperty(NullValueHandling = NullValueHandling.Ignore)] + public TiltLights[] LightIndex { get; set; } + // Added in 7.5b; never released to public. // Write-only so it gets serialized in but not serialized out. // Images and ImageIndex will never coexist in the same .tilt, so we can upgrade in place. diff --git a/Assets/Scripts/Save/SketchSnapshot.cs b/Assets/Scripts/Save/SketchSnapshot.cs index 3276b8284e..3ac268354e 100644 --- a/Assets/Scripts/Save/SketchSnapshot.cs +++ b/Assets/Scripts/Save/SketchSnapshot.cs @@ -126,6 +126,7 @@ public SketchMetadata GetSketchMetadata() ThumbnailCameraTransformInRoomSpace = xfThumbnail_RS, Authors = hasAuthor ? new[] { App.UserConfig.User.Author } : null, ModelIndex = MetadataUtils.GetTiltModels(m_GroupIdMapping), + LightIndex = MetadataUtils.GetTiltLights(m_GroupIdMapping), ImageIndex = MetadataUtils.GetTiltImages(m_GroupIdMapping), Videos = MetadataUtils.GetTiltVideos(m_GroupIdMapping), Mirror = PointerManager.m_Instance.SymmetryWidgetToMirror(), diff --git a/Assets/Scripts/SceneLightGizmo.cs b/Assets/Scripts/SceneLightGizmo.cs new file mode 100644 index 0000000000..70963be885 --- /dev/null +++ b/Assets/Scripts/SceneLightGizmo.cs @@ -0,0 +1,136 @@ +// Copyright 2024 The Open Brush Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System; +using UnityEngine; + +namespace TiltBrush +{ + public class SceneLightGizmo : MonoBehaviour + { + [SerializeField] private Transform m_ConeMesh; + [SerializeField] private Transform m_SphereMesh; + [SerializeField] private Transform m_CylinderMesh; + [SerializeField] private Transform m_Icon; + + private Vector3 initialLocalScale; + + public Transform ActiveMeshTransform + { + get + { + if (m_ConeMesh.gameObject.activeSelf) return m_ConeMesh; + if (m_SphereMesh.gameObject.activeSelf) return m_SphereMesh; + if (m_CylinderMesh.gameObject.activeSelf) return m_CylinderMesh; + return null; + } + } + + private void Awake() + { + initialLocalScale = transform.localScale; + Coords.CanvasPoseChanged += OnCanvasPoseChanged; + var modelWidget = GetComponentInParent(); + if (modelWidget != null) modelWidget.ScaleChanged += OnScaleChanged; + } + + private void OnDestroy() + { + Coords.CanvasPoseChanged -= OnCanvasPoseChanged; + var modelWidget = GetComponentInParent(); + if (modelWidget != null) modelWidget.ScaleChanged -= OnScaleChanged; + } + + private void OnCanvasPoseChanged(TrTransform prev, TrTransform current) + { + transform.localScale = initialLocalScale; + } + + private void OnScaleChanged() + { + transform.localScale = initialLocalScale; + } + + public void SetupLightGizmos(Light light) + { + SetColor(light.color, light.intensity); + switch (light.type) + { + case LightType.Directional: + m_ConeMesh.gameObject.SetActive(false); + m_SphereMesh.gameObject.SetActive(false); + m_CylinderMesh.gameObject.SetActive(true); + break; + case LightType.Point: + m_ConeMesh.gameObject.SetActive(false); + m_SphereMesh.gameObject.SetActive(true); + m_CylinderMesh.gameObject.SetActive(false); + break; + case LightType.Spot: + m_ConeMesh.gameObject.SetActive(true); + m_SphereMesh.gameObject.SetActive(false); + m_CylinderMesh.gameObject.SetActive(false); + SetCone(light.spotAngle); + break; + } + } + + public void SetCone(float angle) + { + // TODO visualize range? + var scale = CalculateScale(2, 2, angle); + m_ConeMesh.localScale = new Vector3(scale, scale, 1f); + } + + public void SetColor(Color color, float intensity) + { + foreach (var mr in m_Icon.GetComponentsInChildren()) + { + mr.material.color = color * intensity; + } + } + + float CalculateScale(float baseWidth, float height, float targetAngle) + { + float targetAngleRadians = targetAngle * Mathf.PI / 180f; + + // Calculate the length of one of the equal sides of the original isosceles triangle + float originalSideLength = Mathf.Sqrt(Mathf.Pow(height, 2) + Mathf.Pow(baseWidth / 2, 2)); + + // Calculate the new base length required for the target base angles in the isosceles triangle + float newBaseLength = 2f * (originalSideLength * Mathf.Sin(targetAngleRadians / 2f)); + return newBaseLength / baseWidth; + } + + public Bounds GetBoundsForLight(Light light) + { + // This is called on the prefab reference - not on an instantiated object + // Therefore we need to calculate any scaling that would be applied to the mesh + switch (light.type) + { + case LightType.Directional: + return m_CylinderMesh.GetComponent().sharedMesh.bounds; + case LightType.Point: + return m_SphereMesh.GetComponent().sharedMesh.bounds; + case LightType.Spot: + var scale = CalculateScale(2, 2, light.spotAngle); + var bounds = m_ConeMesh.GetComponent().sharedMesh.bounds; + var size = new Vector3(bounds.size.x * scale, bounds.size.y * scale, bounds.size.z); + return new Bounds(bounds.center, size); + default: + return new Bounds(); + } + } + } +} diff --git a/Assets/Scripts/SceneLightGizmo.cs.meta b/Assets/Scripts/SceneLightGizmo.cs.meta new file mode 100644 index 0000000000..3dc167a1c4 --- /dev/null +++ b/Assets/Scripts/SceneLightGizmo.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 21fca40525754f4582e7c9846669adb2 +timeCreated: 1710271035 \ No newline at end of file diff --git a/Assets/Scripts/SelectionManager.cs b/Assets/Scripts/SelectionManager.cs index b24a26ae03..9eba2b858b 100644 --- a/Assets/Scripts/SelectionManager.cs +++ b/Assets/Scripts/SelectionManager.cs @@ -14,6 +14,7 @@ using System; using System.Collections.Generic; +using System.IO; using System.Linq; using UnityEngine; @@ -120,6 +121,39 @@ public bool SelectionCanBeGrouped } } + public bool UngroupingAllowed + { + get + { + return SelectionIsInOneGroup || SelectionIsCompositeImport; + } + } + + public bool SelectionIsCompositeImport + { + get + { + if (m_SelectedWidgets.Count != 1) return false; + GrabWidget widget = m_SelectedWidgets.First(); + if (widget is ModelWidget modelWidget) + { + return modelWidget.HasSubModels(); + } + + if (widget is ImageWidget imageWidget) + { + string ext = Path.GetExtension(imageWidget.ReferenceImage.FileName).ToLower(); + if (ext == ".svg") + { + return imageWidget.HasSubShapes(); + } + return false; + } + + return false; + } + } + /// Returns true when the current selection is all in a single group. public bool SelectionIsInOneGroup { @@ -894,16 +928,24 @@ public void ToggleGroupSelectedStrokesAndWidgets() return; } - // If all the selected strokes are in one group, ungroup by setting the new group to None. - // Otherwise, create a new group by setting the target group parameter to null. - bool selectionIsInOneGroup = SelectionIsInOneGroup; - SketchGroupTag? targetGroup = - selectionIsInOneGroup ? SketchGroupTag.None : (SketchGroupTag?)null; - SketchMemoryScript.m_Instance.PerformAndRecordCommand( - new GroupStrokesAndWidgetsCommand(m_SelectedStrokes, m_SelectedWidgets, targetGroup: targetGroup)); + if (SelectionIsCompositeImport) + { + SketchMemoryScript.m_Instance.PerformAndRecordCommand( + new BreakModelApartCommand(m_SelectedWidgets.First() as ModelWidget)); + } + else + { + // If all the selected strokes are in one group, ungroup by setting the new group to None. + // Otherwise, create a new group by setting the target group parameter to null. + bool selectionIsInOneGroup = SelectionIsInOneGroup; + SketchGroupTag? targetGroup = + selectionIsInOneGroup ? SketchGroupTag.None : (SketchGroupTag?)null; + SketchMemoryScript.m_Instance.PerformAndRecordCommand( + new GroupStrokesAndWidgetsCommand(m_SelectedStrokes, m_SelectedWidgets, targetGroup: targetGroup)); - OutputWindowScript.m_Instance.CreateInfoCardAtController( - InputManager.ControllerName.Brush, selectionIsInOneGroup ? "Ungrouped!" : "Grouped!"); + OutputWindowScript.m_Instance.CreateInfoCardAtController( + InputManager.ControllerName.Brush, selectionIsInOneGroup ? "Ungrouped!" : "Grouped!"); + } var pos = InputManager.m_Instance.GetControllerPosition(InputManager.ControllerName.Brush); AudioManager.m_Instance.PlayGroupedSound(pos); } diff --git a/Assets/Scripts/SketchControlsScript.cs b/Assets/Scripts/SketchControlsScript.cs index 6b4a15f702..294099a135 100644 --- a/Assets/Scripts/SketchControlsScript.cs +++ b/Assets/Scripts/SketchControlsScript.cs @@ -4900,7 +4900,7 @@ public bool IsCommandActive(GlobalCommands rEnum, int iParam = -1) (PointerManager.m_Instance.StraightEdgeGuide.TempShape == StraightEdgeGuideScript.Shape.None && PointerManager.m_Instance.StraightEdgeGuide.CurrentShape == (StraightEdgeGuideScript.Shape)iParam); case GlobalCommands.Disco: return LightsControlScript.m_Instance.DiscoMode; - case GlobalCommands.ToggleGroupStrokesAndWidgets: return SelectionManager.m_Instance.SelectionIsInOneGroup; + case GlobalCommands.ToggleGroupStrokesAndWidgets: return SelectionManager.m_Instance.UngroupingAllowed; case GlobalCommands.ToggleProfiling: return UnityEngine.Profiling.Profiler.enabled; case GlobalCommands.ToggleCameraPostEffects: return CameraConfig.PostEffects; case GlobalCommands.ToggleWatermark: return CameraConfig.Watermark; @@ -5054,6 +5054,7 @@ public bool SketchHasChanges() SceneSettings.m_Instance.EnvironmentChanged || LightsControlScript.m_Instance.LightsChanged || m_WidgetManager.ModelWidgets.Any(w => w.gameObject.activeSelf) || + m_WidgetManager.LightWidgets.Any(w => w.gameObject.activeSelf) || m_WidgetManager.StencilWidgets.Any(w => w.gameObject.activeSelf) || m_WidgetManager.ImageWidgets.Any(w => w.gameObject.activeSelf) || m_WidgetManager.VideoWidgets.Any(w => w.gameObject.activeSelf) || diff --git a/Assets/Scripts/SvgMeshReader.cs b/Assets/Scripts/SvgMeshReader.cs new file mode 100644 index 0000000000..5db4422b4f --- /dev/null +++ b/Assets/Scripts/SvgMeshReader.cs @@ -0,0 +1,68 @@ +// Copyright 2022 The Open Brush Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using Unity.VectorGraphics; +using UnityEngine; +using UObject = UnityEngine.Object; + +namespace TiltBrush +{ + public class SvgMeshReader + { + private readonly Material m_vertexColorMaterial; + private readonly string m_path; // Full path to file + private readonly List m_warnings = new(); + private readonly ImportMaterialCollector m_collector; + + private List warnings => m_warnings; + + public SvgMeshReader(string path) + { + m_path = path; + var mDir = Path.GetDirectoryName(path); + m_collector = new ImportMaterialCollector(mDir, m_path); + } + + public (GameObject, List warnings, ImportMaterialCollector, SVGParser.SceneInfo) Import() + { + GameObject go = new GameObject(); + var mf = go.AddComponent(); + var mr = go.AddComponent(); + var mat = RuntimeSVGImporter.MaterialForSVG(false); + mr.materials = new[] { mat }; + m_collector.AddSvgIem(mr.materials[0]); + mf.mesh = null; + SVGParser.SceneInfo sceneInfo; + try + { + var importer = new RuntimeSVGImporter(); + sceneInfo = importer.ImportAsSceneInfo(m_path); + mf.mesh = importer.SceneInfoToMesh(sceneInfo); + } + catch (Exception e) + { + Debug.LogError("Failed importing " + m_path + ". " + e.Message); + return (go, m_warnings, m_collector, new SVGParser.SceneInfo()); + } + var collider = go.AddComponent(); + collider.size = mf.mesh.bounds.size; + return (go, warnings.Distinct().ToList(), m_collector, sceneInfo); + } + } +} // namespace TiltBrush diff --git a/Assets/Scripts/SvgMeshReader.cs.meta b/Assets/Scripts/SvgMeshReader.cs.meta new file mode 100644 index 0000000000..20e7b039d1 --- /dev/null +++ b/Assets/Scripts/SvgMeshReader.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2dc51030c6b8e654db52c273b08af356 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Scripts/UserConfig.cs b/Assets/Scripts/UserConfig.cs index 5ee6fc9a11..2dc44a1eee 100644 --- a/Assets/Scripts/UserConfig.cs +++ b/Assets/Scripts/UserConfig.cs @@ -254,6 +254,17 @@ public string[] ExcludeTags } public BrushConfig Brushes; + [Serializable] + public struct ImportConfig + { + bool? m_UseUnityGltf; + public bool UseUnityGltf + { + get { return m_UseUnityGltf ?? true; } + set { m_UseUnityGltf = value; } + } + } + [Serializable] public struct ExportConfig { @@ -277,7 +288,38 @@ public bool ExportStrokeTimestamp get { return m_ExportStrokeTimestamp ?? true; } set { m_ExportStrokeTimestamp = value; } } + + bool? m_ExportStrokeMetadata; + public bool ExportStrokeMetadata + { + get { return m_ExportStrokeMetadata ?? false; } + set { m_ExportStrokeMetadata = value; } + } + + bool? m_KeepStrokes; + public bool KeepStrokes + { + get { return m_KeepStrokes ?? false; } + set { m_KeepStrokes = value; } + } + + bool? m_KeepGroups; + public bool KeepGroups + { + get { return m_KeepGroups ?? true; } + set { m_KeepGroups = value; } + } + + private Dictionary m_Formats; + [JsonProperty] + public Dictionary Formats + { + get { return m_Formats ?? null; } + set => m_Formats = value; + } } + + public ImportConfig Import; public ExportConfig Export; [Serializable] diff --git a/Assets/Scripts/Util/HierarchyUtils.cs b/Assets/Scripts/Util/HierarchyUtils.cs index 07b4d32479..6bdee50e10 100644 --- a/Assets/Scripts/Util/HierarchyUtils.cs +++ b/Assets/Scripts/Util/HierarchyUtils.cs @@ -20,13 +20,17 @@ namespace TiltBrush public static class HierarchyUtils { /// Sets object and all children to a layer. - public static void RecursivelySetLayer(Transform obj, int layer) + public static void RecursivelySetLayer(Transform obj, int layer, bool skipUI = true) { - if (obj == null) { return; } + // Hardcoded exceptions + if ( + obj == null || + (skipUI && obj.gameObject.layer == LayerMask.NameToLayer("UI")) + ) { return; } obj.gameObject.layer = layer; for (int i = 0; i < obj.childCount; ++i) { - RecursivelySetLayer(obj.GetChild(i), layer); + RecursivelySetLayer(obj.GetChild(i), layer, skipUI); } } diff --git a/Assets/Scripts/WidgetManager.cs b/Assets/Scripts/WidgetManager.cs index 67ce9cbb0d..e9b5e445fe 100644 --- a/Assets/Scripts/WidgetManager.cs +++ b/Assets/Scripts/WidgetManager.cs @@ -104,6 +104,8 @@ public class WidgetManager : MonoBehaviour [SerializeField] GameObject m_WidgetPinPrefab; [SerializeField] ImageWidget m_ImageWidgetPrefab; [SerializeField] VideoWidget m_VideoWidgetPrefab; + [SerializeField] LightWidget m_LightWidgetPrefab; + [SerializeField] SceneLightGizmo m_SceneLightGizmoPrefab; [SerializeField] CameraPathWidget m_CameraPathWidgetPrefab; [SerializeField] private GameObject m_CameraPathPositionKnotPrefab; [SerializeField] private GameObject m_CameraPathRotationKnotPrefab; @@ -140,6 +142,7 @@ public class WidgetManager : MonoBehaviour // Widgets will be in the most specific list. private List m_GrabWidgets; private List> m_ModelWidgets; + private List> m_LightWidgets; private List> m_StencilWidgets; private List> m_ImageWidgets; private List> m_VideoWidgets; @@ -152,6 +155,7 @@ public class WidgetManager : MonoBehaviour public event Action RefreshPinAndUnpinAction; private TiltModels75[] m_loadingTiltModels75; + private TiltLights[] m_loadingTiltLights; private TiltImages75[] m_loadingTiltImages75; private TiltVideo[] m_loadingTiltVideos; @@ -296,6 +300,7 @@ public void Init() m_GrabWidgets = new List(); m_ModelWidgets = new List>(); + m_LightWidgets = new List>(); m_StencilWidgets = new List>(); m_ImageWidgets = new List>(); m_VideoWidgets = new List>(); @@ -325,6 +330,8 @@ public void Init() public ModelWidget ModelWidgetPrefab { get { return m_ModelWidgetPrefab; } } public ImageWidget ImageWidgetPrefab { get { return m_ImageWidgetPrefab; } } public VideoWidget VideoWidgetPrefab { get { return m_VideoWidgetPrefab; } } + public LightWidget LightWidgetPrefab { get { return m_LightWidgetPrefab; } } + public SceneLightGizmo SceneLightGizmoPrefab { get { return m_SceneLightGizmoPrefab; } } public CameraPathWidget CameraPathWidgetPrefab { get { return m_CameraPathWidgetPrefab; } } public GameObject CameraPathPositionKnotPrefab { get { return m_CameraPathPositionKnotPrefab; } } public GameObject CameraPathRotationKnotPrefab { get { return m_CameraPathRotationKnotPrefab; } } @@ -361,6 +368,13 @@ private IEnumerable GetAllActiveGrabWidgets() yield return m_ModelWidgets[i]; } } + for (int i = 0; i < m_LightWidgets.Count; ++i) + { + if (m_LightWidgets[i].m_WidgetObject.activeSelf) + { + yield return m_LightWidgets[i]; + } + } for (int i = 0; i < m_StencilWidgets.Count; ++i) { if (m_StencilWidgets[i].m_WidgetObject.activeSelf) @@ -396,7 +410,10 @@ public IEnumerable MediaWidgets get { IEnumerable ret = m_ModelWidgets; - return ret.Concat(m_ImageWidgets).Concat(m_VideoWidgets); + return ret + .Concat(m_ImageWidgets) + .Concat(m_VideoWidgets) + .Concat(m_LightWidgets); } } @@ -596,7 +613,11 @@ public bool CameraPathsVisible public bool HasSelectableWidgets() { - return (m_ModelWidgets.Count > 0) || (m_ImageWidgets.Count > 0) || (m_VideoWidgets.Count > 0) || + return + (m_ModelWidgets.Count > 0) || + (m_LightWidgets.Count > 0) || + (m_ImageWidgets.Count > 0) || + (m_VideoWidgets.Count > 0) || (!m_StencilsDisabled && m_StencilWidgets.Count > 0); } @@ -703,6 +724,12 @@ public void SetDataFromTilt(TiltImages75[] value) m_loadingTiltImages75 = value; } + // Used only at .tilt-loading time + public void SetDataFromTilt(TiltLights[] value) + { + m_loadingTiltLights = value; + } + public void SetDataFromTilt(CameraPathMetadata[] cameraPaths) { for (int i = 0; i < cameraPaths.Length; ++i) @@ -959,6 +986,16 @@ public IEnumerable ModelWidgets } } + public IEnumerable LightWidgets + { + get + { + return m_LightWidgets + .Select(w => w == null ? null : w.WidgetScript) + .Where(w => w != null); + } + } + public IEnumerable VideoWidgets { get @@ -1025,6 +1062,7 @@ public List GetAllUnselectedActiveWidgets() { List widgets = new List(); GetUnselectedActiveWidgetsInList(m_ModelWidgets); + GetUnselectedActiveWidgetsInList(m_LightWidgets); GetUnselectedActiveWidgetsInList(m_ImageWidgets); GetUnselectedActiveWidgetsInList(m_VideoWidgets); if (!m_StencilsDisabled) @@ -1055,6 +1093,7 @@ public void RefreshPinAndUnpinLists() m_CanBeUnpinnedWidgets.Clear(); RefreshPinUnpinWidgetList(m_ModelWidgets); + RefreshPinUnpinWidgetList(m_LightWidgets); RefreshPinUnpinWidgetList(m_ImageWidgets); RefreshPinUnpinWidgetList(m_VideoWidgets); RefreshPinUnpinWidgetList(m_StencilWidgets); @@ -1122,6 +1161,10 @@ public void RegisterGrabWidget(GameObject rWidget) { m_ModelWidgets.Add(new TypedWidgetData(mw)); } + else if (generic is LightWidget light) + { + m_LightWidgets.Add(new TypedWidgetData(light)); + } else if (generic is StencilWidget stencil) { m_StencilWidgets.Add(new TypedWidgetData(stencil)); @@ -1181,6 +1224,7 @@ public void UnregisterGrabWidget(GameObject rWidget) } if (RemoveFrom(m_ModelWidgets, rWidget)) { return; } + if (RemoveFrom(m_LightWidgets, rWidget)) { return; } if (RemoveFrom(m_StencilWidgets, rWidget)) { return; } if (RemoveFrom(m_ImageWidgets, rWidget)) { return; } if (RemoveFrom(m_VideoWidgets, rWidget)) { return; } @@ -1328,6 +1372,7 @@ public float DistanceToNearestWidget(Ray ray) public void DestroyAllWidgets() { DestroyWidgetList(m_ModelWidgets); + DestroyWidgetList(m_LightWidgets); DestroyWidgetList(m_ImageWidgets); DestroyWidgetList(m_VideoWidgets); DestroyWidgetList(m_StencilWidgets); @@ -1398,6 +1443,14 @@ bool IsLoading(string assetId) m_loadingTiltModels75 = null; } ModelCatalog.m_Instance.PrintMissingModelWarnings(); + if (m_loadingTiltLights != null) + { + foreach (var light in m_loadingTiltLights) + { + LightWidget.FromTiltLight(light); + } + m_loadingTiltLights = null; + } if (m_loadingTiltImages75 != null) { foreach (TiltImages75 import in m_loadingTiltImages75) @@ -1493,6 +1546,8 @@ public void TossNearestWidget() public List> ActiveImageWidgets => m_ImageWidgets.Where(w => w.WidgetScript.gameObject.activeSelf).ToList(); + public List> ActiveLightWidgets => + m_LightWidgets.Where(w => w.WidgetScript.gameObject.activeSelf).ToList(); public List> ActiveModelWidgets => m_ModelWidgets.Where(w => w.WidgetScript.gameObject.activeSelf).ToList(); public List> ActiveVideoWidgets => diff --git a/Assets/Scripts/Widgets/GrabWidget.cs b/Assets/Scripts/Widgets/GrabWidget.cs index 3839aba266..d545381987 100644 --- a/Assets/Scripts/Widgets/GrabWidget.cs +++ b/Assets/Scripts/Widgets/GrabWidget.cs @@ -88,7 +88,16 @@ public enum Axis [SerializeField] protected BoxCollider m_BoxCollider; [SerializeField] protected Transform m_Mesh; - [SerializeField] protected Transform[] m_HighlightMeshXfs; + [SerializeField] private Transform[] m_HighlightMeshXfs; + protected Transform[] HighlightMeshXfs + { + get => m_HighlightMeshXfs; + set + { + m_HighlightMeshXfs = value; + UpdateHighlightMeshFilters(); + } + } [SerializeField] protected float m_ValidSnapRotationStickyAngle; @@ -691,13 +700,7 @@ public void ClearVelocities() virtual protected void Awake() { - // TODO : Why do we serialize transforms when we pull the mesh filter out - // and never use the transform? We should just serialize the filters. - if (m_HighlightMeshXfs != null) - { - m_HighlightMeshFilters = m_HighlightMeshXfs.Select(x => x.GetComponent()).ToArray(); - } - + UpdateHighlightMeshFilters(); m_CurrentState = State.Invisible; Activate(false); m_NonScaleChild = gameObject.GetComponent(); @@ -729,6 +732,16 @@ virtual protected void Awake() RegisterWithWidgetManager(); } + public void UpdateHighlightMeshFilters() + { + // TODO : Why do we serialize transforms when we pull the mesh filter out + // and never use the transform? We should just serialize the filters. + if (HighlightMeshXfs != null) + { + m_HighlightMeshFilters = HighlightMeshXfs.Select(x => x.GetComponent()).ToArray(); + } + } + virtual protected void Start() { RegisterWithWidgetManager(); @@ -945,6 +958,7 @@ private void EnableKeyword(string keyword) foreach (var renderer in m_WidgetRenderers) { + if (renderer == null) continue; var materials = m_NewMaterials[renderer]; foreach (var material in materials) { @@ -963,6 +977,7 @@ private void DisableKeyword(string keyword) } foreach (var renderer in m_WidgetRenderers) { + if (renderer == null) continue; var materials = m_NewMaterials[renderer]; foreach (var material in materials) { diff --git a/Assets/Scripts/Widgets/ImageWidget.cs b/Assets/Scripts/Widgets/ImageWidget.cs index 2228afd26f..d61947e6b5 100644 --- a/Assets/Scripts/Widgets/ImageWidget.cs +++ b/Assets/Scripts/Widgets/ImageWidget.cs @@ -253,5 +253,9 @@ public static void FromTiltImage(TiltImages75 tiltImage) } } + public bool HasSubShapes() + { + throw new System.NotImplementedException(); + } } } // namespace TiltBrush diff --git a/Assets/Scripts/Widgets/LightWidget.cs b/Assets/Scripts/Widgets/LightWidget.cs new file mode 100644 index 0000000000..f896052ff4 --- /dev/null +++ b/Assets/Scripts/Widgets/LightWidget.cs @@ -0,0 +1,185 @@ +// Copyright 2024 The Open Brush Authors +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +using System.Collections.Generic; +using System.Linq; +using UnityEngine; + +namespace TiltBrush +{ + public class LightWidget : MediaWidget + { + protected override void Awake() + { + base.Awake(); + transform.localScale = Vector3.one * Coords.CanvasPose.scale; + m_ContainerBloat /= App.ActiveCanvas.Pose.scale; + + // Set a new batchId on this light so it can be picked up in GPU intersections. + m_BatchId = GpuIntersector.GetNextBatchId(); + WidgetManager.m_Instance.AddWidgetToBatchMap(this, m_BatchId); + Debug.Log($"Widget {name} assigned batchId {m_BatchId}"); + } + + public static List FromModelWidget(ModelWidget modelWidget) + { + var go = modelWidget.gameObject; + string baseName = go.name.Replace("ModelWidget", "LightWidget"); + go.SetActive(false); + go.name = go.name.Replace("ModelWidget", "OldModelWidget"); + var lightWidgets = new List(); + var layer = go.layer; + foreach (var gizmo in go.GetComponentsInChildren()) + { + var tr = TrTransform.FromTransform(gizmo.transform); + CreateWidgetCommand createCommand = new CreateWidgetCommand( + WidgetManager.m_Instance.LightWidgetPrefab, tr, null, forceTransform: true + ); + SketchMemoryScript.m_Instance.PerformAndRecordCommand(createCommand); + LightWidget lightWidget = createCommand.Widget as LightWidget; + var light = gizmo.transform.parent.GetComponentInChildren(); + gizmo.SetupLightGizmos(light); + lightWidget.m_BoxCollider = gizmo.GetComponentInChildren(includeInactive: false); + lightWidget.m_Mesh = gizmo.ActiveMeshTransform; + lightWidget.HighlightMeshXfs = new[] { gizmo.ActiveMeshTransform }; + light.transform.SetParent(lightWidget.transform, true); + lightWidget.name = baseName; + HierarchyUtils.RecursivelySetLayer(lightWidget.transform, layer, skipUI: false); + WidgetManager.m_Instance.RegisterGrabWidget(lightWidget.gameObject); + lightWidgets.Add(lightWidget); + } + modelWidget.Hide(); + WidgetManager.m_Instance.UnregisterGrabWidget(modelWidget.gameObject); + Destroy(modelWidget.gameObject); + return lightWidgets; + } + + protected override void UpdateScale() + { + transform.localScale = Vector3.one * m_Size; + m_BoxCollider.size = Vector3.one * m_Size; + } + + public override string GetExportName() + { + return this.name; + } + + public override GrabWidget Clone() + { + return Clone(transform.position, transform.rotation, m_Size); + } + + public override GrabWidget Clone(Vector3 position, Quaternion rotation, float size) + { + LightWidget clone = Instantiate(WidgetManager.m_Instance.LightWidgetPrefab); + clone.m_PreviousCanvas = m_PreviousCanvas; + clone.transform.position = position; + clone.transform.rotation = rotation; + // We want to lie about our intro transition amount. + clone.m_ShowTimer = clone.m_ShowDuration; + clone.transform.parent = transform.parent; + clone.Show(true, false); + clone.SetSignedWidgetSize(size); + clone.CloneInitialMaterials(this); + HierarchyUtils.RecursivelySetLayer(clone.transform, gameObject.layer); + + clone.transform.parent = App.Instance.m_CanvasTransform; + clone.transform.localScale = Vector3.one; + + var light = clone.SetLightType(GetComponentInChildren().type); + + clone.Show(bShow: true, bPlayAudio: false); + light.color = light.color; + light.intensity = light.intensity; + light.range = light.range; + light.spotAngle = light.spotAngle; + light.innerSpotAngle = light.innerSpotAngle; + clone.SetPinned(Pinned); + clone.Group = Group; + var gizmo = Instantiate(WidgetManager.m_Instance.SceneLightGizmoPrefab, transform); + gizmo.SetupLightGizmos(light); + + CanvasScript canvas = transform.parent.GetComponent(); + if (canvas != null) + { + var materials = clone.GetComponentsInChildren().SelectMany(x => x.materials); + foreach (var material in materials) + { + foreach (string keyword in canvas.BatchManager.MaterialKeywords) + { + material.EnableKeyword(keyword); + } + } + } + + return clone; + } + + public static void FromTiltLight(TiltLights tiltLight) + { + LightWidget lightWidget = Instantiate(WidgetManager.m_Instance.LightWidgetPrefab); + lightWidget.m_LoadingFromSketch = true; + lightWidget.transform.parent = App.Instance.m_CanvasTransform; + lightWidget.transform.localScale = Vector3.one; + + lightWidget.SetSignedWidgetSize(tiltLight.Transform.scale); + lightWidget.Show(bShow: true, bPlayAudio: false); + lightWidget.transform.localPosition = tiltLight.Transform.translation; + lightWidget.transform.localRotation = tiltLight.Transform.rotation; + var light = lightWidget.SetLightType(tiltLight.PunctualLightType); + light.color = tiltLight.LightColor.Value; + light.intensity = tiltLight.Intensity.Value; + light.range = tiltLight.Range.Value; + light.spotAngle = tiltLight.OuterConeAngle.Value; + light.innerSpotAngle = tiltLight.InnerConeAngle.Value; + if (tiltLight.Pinned) + { + lightWidget.PinFromSave(); + } + lightWidget.Group = App.GroupManager.GetGroupFromId(tiltLight.GroupId); + lightWidget.SetCanvas(App.Scene.GetOrCreateLayer(tiltLight.LayerId)); + var gizmo = Instantiate(WidgetManager.m_Instance.SceneLightGizmoPrefab, lightWidget.transform); + gizmo.SetupLightGizmos(light); + + TiltMeterScript.m_Instance.AdjustMeterWithWidget(lightWidget.GetTiltMeterCost(), up: true); + lightWidget.UpdateScale(); + } + + private Light SetLightType(LightType lightType) + { + var lights = gameObject.GetComponentsInChildren(); + Light activeLight = null; + foreach (var l in lights) + { + l.gameObject.SetActive(false); + if (l.type == lightType) + { + l.gameObject.SetActive(true); + activeLight = l; + } + + } + return activeLight; + } + + public TrTransform GetSaveTransform() + { + var xf = TrTransform.FromLocalTransform(transform); + xf.scale = GetSignedWidgetSize(); + return xf; + } + } + +} // namespace TiltBrush diff --git a/Assets/Scripts/Widgets/LightWidget.cs.meta b/Assets/Scripts/Widgets/LightWidget.cs.meta new file mode 100644 index 0000000000..20a55cf27a --- /dev/null +++ b/Assets/Scripts/Widgets/LightWidget.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 9e25501290d544bfb149945101d12d6e +timeCreated: 1711898754 \ No newline at end of file diff --git a/Assets/Scripts/Widgets/ModelWidget.cs b/Assets/Scripts/Widgets/ModelWidget.cs index d91606259d..d26af7f43c 100644 --- a/Assets/Scripts/Widgets/ModelWidget.cs +++ b/Assets/Scripts/Widgets/ModelWidget.cs @@ -12,9 +12,9 @@ // See the License for the specific language governing permissions and // limitations under the License. +using System; using UnityEngine; using System.Linq; -using System.Threading; using System.Threading.Tasks; namespace TiltBrush @@ -29,6 +29,15 @@ public class ModelWidget : MediaWidget [SerializeField] private float m_MaxBloat; private Model m_Model; + private string m_Subtree; + public string Subtree + { + get => m_Subtree; + set => m_Subtree = value; + } + + public event Action ScaleChanged; + private Transform m_ModelInstance; private ObjModelScript m_ObjModelScript; private float m_InitSize_CS; @@ -144,17 +153,20 @@ public override GrabWidget Clone() public override GrabWidget Clone(Vector3 position, Quaternion rotation, float size) { - ModelWidget clone = Instantiate(WidgetManager.m_Instance.ModelWidgetPrefab) as ModelWidget; + ModelWidget clone = Instantiate(WidgetManager.m_Instance.ModelWidgetPrefab); clone.m_PreviousCanvas = m_PreviousCanvas; clone.transform.position = position; clone.transform.rotation = rotation; - clone.Model = this.Model; + clone.Model = Model; // We're obviously not loading from a sketch. This is to prevent the intro animation. // TODO: Change variable name to something more explicit of what this flag does. clone.m_LoadingFromSketch = true; clone.Show(true, false); + clone.AddSceneLightGizmos(); clone.transform.parent = transform.parent; clone.SetSignedWidgetSize(size); + clone.m_Subtree = m_Subtree; + clone.SyncHierarchyToSubtree(); HierarchyUtils.RecursivelySetLayer(clone.transform, gameObject.layer); TiltMeterScript.m_Instance.AdjustMeterWithWidget(clone.GetTiltMeterCost(), up: true); @@ -201,6 +213,15 @@ public void OnPacCatalogChanged() } } + override protected void SetWidgetSizeInternal(float fScale) + { + base.SetWidgetSizeInternal(fScale); + if (Mathf.Abs(fScale - m_Size) > float.Epsilon) + { + ScaleChanged?.Invoke(); + } + } + public override string GetExportName() { return Model.GetExportName(); @@ -285,6 +306,151 @@ void LoadModel() } } + public bool HasSubModels() + { + string ext = Model.GetLocation().Extension; + if (ext == ".gltf" || ext == ".glb") + { + int lightCount = m_ObjModelScript.GetComponentsInChildren().Length; + int meshCount = GetMeshes().Length; + return lightCount + meshCount > 1; + } + else if (m_Model.GetLocation().Extension == ".svg") + { + return m_ObjModelScript.SvgSceneInfo.HasSubShapes(); + } + return false; + } + + public void SyncHierarchyToSubtree(string previousSubtree = null) + { + if (string.IsNullOrEmpty(Subtree)) return; + // Walk the hierarchy and find the matching node + Transform oldRoot = m_ObjModelScript.transform; + Transform node = oldRoot; + + // We only want to walk the new part of the hierarchy + string subpathToTraverse; + if (!string.IsNullOrEmpty(previousSubtree)) + { + subpathToTraverse = m_Subtree.Substring(previousSubtree.Length); + } + else + { + subpathToTraverse = m_Subtree; + } + subpathToTraverse = subpathToTraverse.Trim('/'); + + bool excludeChildren = false; + if (subpathToTraverse.EndsWith(".mesh")) + { + subpathToTraverse = subpathToTraverse.Substring(0, subpathToTraverse.Length - 5); + excludeChildren = true; + } + if (node.name == subpathToTraverse) + { + // We're already at the right node + // No need to do anything + Debug.LogWarning($"Didn't expect to get here..."); + } + else + { + // node will be null if not found + node = node.Find(subpathToTraverse); + } + + if (node != null) + { + if (excludeChildren) + { + foreach (Transform child in node) + { + Destroy(child.gameObject); + } + } + var newRoot = new GameObject(); + newRoot.transform.SetParent(transform); + newRoot.name = $"LocalFile:{m_Model.RelativePath}#{m_Subtree}"; + m_ObjModelScript = newRoot.AddComponent(); + node.SetParent(newRoot.transform, worldPositionStays: true); + + oldRoot.gameObject.SetActive(false); // TODO destroy might fail on first load so also hide + Destroy(oldRoot.gameObject); + + m_ObjModelScript.Init(); + if (excludeChildren) + { + // Destroyed children aren't destroyed immediately, so we need to assign them manually + var mf = node.GetComponent(); + var smr = node.GetComponent(); + m_ObjModelScript.m_MeshChildren = mf != null ? new[] { mf } : Array.Empty(); + m_ObjModelScript.m_SkinnedMeshChildren = smr != null ? new[] { smr } : Array.Empty(); + } + + CloneInitialMaterials(null); + RecalculateColliderBounds(); + } + } + + public void RecalculateColliderBounds() + { + var widgetTransform = m_ObjModelScript.transform.parent; + + // Save the widget's original transform + var oldParent = widgetTransform.parent; + var oldPosition = widgetTransform.localPosition; + var oldRotation = widgetTransform.localRotation; + var oldScale = widgetTransform.localScale; + + // Move it to the origin + widgetTransform.SetParent(null); + widgetTransform.localPosition = Vector3.zero; + widgetTransform.localRotation = Quaternion.identity; + widgetTransform.localScale = Vector3.one; + + // Reset the collider gameobject transform + m_BoxCollider.transform.localPosition = Vector3.zero; + m_BoxCollider.transform.localRotation = Quaternion.identity; + m_BoxCollider.transform.localScale = Vector3.one; + + // Collect the renderers + var meshRenderers = m_ObjModelScript + .m_MeshChildren + .Select(x => x.GetComponent()); + var skinnedMeshRenderers = m_ObjModelScript.m_SkinnedMeshChildren; + + // Calculate the bounds + Bounds b = new Bounds(); + bool first = true; + var boundsList = meshRenderers.Select(x => x.bounds).ToList(); + boundsList.AddRange(skinnedMeshRenderers.Select(x => x.bounds)); + + for (var i = 0; i < boundsList.Count; i++) + { + var bounds = boundsList[i]; + + if (first) + { + b = bounds; + first = false; + } + else + { + b.Encapsulate(bounds); + } + } + + m_MeshBounds = b; + m_BoxCollider.transform.localPosition = m_MeshBounds.center; + m_BoxCollider.size = m_MeshBounds.size; + + // Restore the widget's original transform + widgetTransform.SetParent(oldParent); + widgetTransform.localPosition = oldPosition; + widgetTransform.localRotation = oldRotation; + widgetTransform.localScale = oldScale; + } + public override float GetActivationScore(Vector3 vControllerPos, InputManager.ControllerName name) { Vector3 vInvTransformedPos = m_BoxCollider.transform.InverseTransformPoint(vControllerPos); @@ -357,10 +523,24 @@ protected override void UpdateIntroAnim() protected override void UpdateScale() { + if (this == null) return; // BreakModelApartCommand can destroy us transform.localScale = Vector3.one * m_Size; if (m_Model != null && m_Model.m_Valid) { - m_BoxCollider.size = m_Model.m_MeshBounds.size + m_ContainerBloat; + m_BoxCollider.size = MeshBounds.size + m_ContainerBloat; + } + } + + private Bounds m_MeshBounds; + public Bounds MeshBounds + { + get + { + if (string.IsNullOrEmpty(m_Subtree)) + { + return m_Model.m_MeshBounds; + } + return m_MeshBounds; } } @@ -479,7 +659,7 @@ public static async void CreateFromSaveData(TiltModels75 modelDatas) { Task okTask = CreateModelsFromRelativePath( - modelDatas.FilePath, + modelDatas.FilePath, modelDatas.Subtrees, modelDatas.Transforms, modelDatas.RawTransforms, modelDatas.PinStates, modelDatas.GroupIds, modelDatas.LayerIds); ok = await okTask; @@ -488,7 +668,7 @@ public static async void CreateFromSaveData(TiltModels75 modelDatas) else if (modelDatas.AssetId != null) { CreateModelsFromAssetId( - modelDatas.AssetId, + modelDatas.AssetId, modelDatas.Subtrees, modelDatas.RawTransforms, modelDatas.PinStates, modelDatas.GroupIds, modelDatas.LayerIds); ok = true; } @@ -509,15 +689,15 @@ public static async void CreateFromSaveData(TiltModels75 modelDatas) /// Returns false if the model can't be loaded -- in this case, caller is responsible /// for creating the missing-model placeholder. public static async Task CreateModelsFromRelativePath( - string relativePath, TrTransform[] xfs, TrTransform[] rawXfs, bool[] pinStates, uint[] groupIds, int[] layerIds) + string relativePath, string[] subtrees, TrTransform[] xfs, TrTransform[] rawXfs, bool[] pinStates, uint[] groupIds, int[] layerIds) { // Verify model is loaded. Or, at least, has been tried to be loaded. Model model = ModelCatalog.m_Instance.GetModel(relativePath); - if (model == null) { return false; } if (!model.m_Valid) { + // Reload the model if it's not valid or if we're loading a subtree. Task t = model.LoadModelAsync(); await t; } @@ -533,7 +713,7 @@ public static async Task CreateModelsFromRelativePath( { bool pin = (pinStates != null && i < pinStates.Length) ? pinStates[i] : true; uint groupId = (groupIds != null && i < groupIds.Length) ? groupIds[i] : 0; - CreateModel(model, xfs[i], pin, isNonRawTransform: true, groupId, 0); + CreateModel(model, subtrees[i], xfs[i], pin, isNonRawTransform: true, groupId, 0); } } if (rawXfs != null) @@ -544,14 +724,14 @@ public static async Task CreateModelsFromRelativePath( bool pin = (pinStates != null && i < pinStates.Length) ? pinStates[i] : true; uint groupId = (groupIds != null && i < groupIds.Length) ? groupIds[i] : 0; int layerId = (layerIds != null && i < layerIds.Length) ? layerIds[i] : 0; - CreateModel(model, rawXfs[i], pin, isNonRawTransform: false, groupId, layerId); + CreateModel(model, subtrees[i], rawXfs[i], pin, isNonRawTransform: false, groupId, layerId); } } return true; } /// isNonRawTransform - true if the transform uses the pre-M13 meaning of transform.scale. - static void CreateModel(Model model, TrTransform xf, bool pin, + static void CreateModel(Model model, string subtree, TrTransform xf, bool pin, bool isNonRawTransform, uint groupId, int layerId, string assetId = null) { @@ -559,6 +739,8 @@ static void CreateModel(Model model, TrTransform xf, bool pin, modelWidget.transform.localPosition = xf.translation; modelWidget.transform.localRotation = xf.rotation; modelWidget.Model = model; + modelWidget.m_Subtree = subtree; + modelWidget.SyncHierarchyToSubtree(); modelWidget.m_LoadingFromSketch = true; modelWidget.Show(true, false); if (isNonRawTransform) @@ -587,7 +769,7 @@ static void CreateModel(Model model, TrTransform xf, bool pin, } // Used when loading model assetIds from a serialized format (e.g. Tilt file). - static void CreateModelsFromAssetId(string assetId, TrTransform[] rawXfs, + static void CreateModelsFromAssetId(string assetId, string[] subtrees, TrTransform[] rawXfs, bool[] pinStates, uint[] groupIds, int[] layerIds) { // Request model from Poly and if it doesn't exist, ask to load it. @@ -609,7 +791,7 @@ static void CreateModelsFromAssetId(string assetId, TrTransform[] rawXfs, bool pin = (i < pinStates.Length) ? pinStates[i] : true; uint groupId = (groupIds != null && i < groupIds.Length) ? groupIds[i] : 0; int layerId = (layerIds != null && i < layerIds.Length) ? layerIds[i] : 0; - CreateModel(model, rawXfs[i], pin, isNonRawTransform: false, groupId, layerId, assetId); + CreateModel(model, subtrees[i], rawXfs[i], pin, isNonRawTransform: false, groupId, layerId, assetId); } } @@ -632,5 +814,29 @@ override public bool CanSnapToHome() { return m_Model.m_MeshBounds.center == Vector3.zero; } + + public void AddSceneLightGizmos() + { + var lights = m_ObjModelScript.transform.GetComponentsInChildren(); + foreach (var light in lights) + { + // Probably not the right place to do it but we have to it somewhere + light.renderMode = LightRenderMode.ForceVertex; + Transform tr = Instantiate( + WidgetManager.m_Instance.SceneLightGizmoPrefab.transform, + light.transform + ); + var gizmo = tr.GetComponent(); + gizmo.SetupLightGizmos(light); + } + } + + public void UpdateBatchInfo() + { + // Set a new batchId on this model so it can be picked up in GPU intersections. + m_BatchId = GpuIntersector.GetNextBatchId(); + HierarchyUtils.RecursivelySetMaterialBatchID(m_ModelInstance, m_BatchId); + WidgetManager.m_Instance.AddWidgetToBatchMap(this, m_BatchId); + } } } // namespace TiltBrush diff --git a/Assets/Shaders/BrushBaker Compute.meta b/Assets/Shaders/BrushBaker Compute.meta new file mode 100644 index 0000000000..dc8439e77e --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 24ad3eace6c7408db3866f9a0d993819 +timeCreated: 1706099152 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/X.meta b/Assets/Shaders/BrushBaker Compute/X.meta new file mode 100644 index 0000000000..7b80a197a9 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 7ba3f148c8f2d2c4ba713e6ef8614555 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeBubbleWand.compute b/Assets/Shaders/BrushBaker Compute/X/bakeBubbleWand.compute new file mode 100644 index 0000000000..223e587800 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeBubbleWand.compute @@ -0,0 +1,64 @@ +#pragma kernel CSMain + +#include "../../../ThirdParty/Shaders/Noise.cginc" + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + float radius = uv0.z; + + // Bulge displacement + float wave = sin(uv0.x*3.14159); + float3 wave_displacement = radius * normal.xyz * wave; + vertex += wave_displacement; + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) + // we will take the t = 0 in this compute shader + // float timedoty = 0; + // float timedotx = timedoty / 20;; + + + // // // leaving this parameters here for generating animated mesh in the future + // float scrollRate = -0.54f; + // float scrollJitterIntensity = 3.0f; + // float scrollJitterFrequency = 1.0f; + // float timeOffset = 0; + // float t = timedoty * scrollRate + timeOffset; + // float3 pos = vertex.xyz; + // pos.x += sin(t + timedoty + pos.z * scrollJitterFrequency) * scrollJitterIntensity; + // pos.z += cos(t + timedoty + pos.x * scrollJitterFrequency) * scrollJitterIntensity; + // pos.y += cos(t * 1.2 + timedoty + pos.x * scrollJitterFrequency) * scrollJitterIntensity; + + // float time = timedotx; + // float d = 30; + // float freq = .1; + + // float3 disp = float3(1,0,0) * curlX(pos.xyz * freq + time, d); + // disp += float3(0,1,0) * curlY(pos.xyz * freq +time, d); + // disp += float3(0,0,1) * curlZ(pos.xyz * freq + time, d); + // pos.xyz = scrollJitterIntensity * disp; + + // // Noise displacement + // // TO DO: Need to make this scale invariant + // float4 displacement = float4(pos, 0); + // vertex += displacement.xyz; + + // // Perturb normal + // normal = normalize(normal + displacement.xyz * 2.5, wave_displacement * 2.5); + + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeBubbleWand.compute.meta b/Assets/Shaders/BrushBaker Compute/X/bakeBubbleWand.compute.meta new file mode 100644 index 0000000000..8b1b521df7 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeBubbleWand.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 81ca801fea8092f41be21fb73d2f30d4 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeDanceFloor.compute b/Assets/Shaders/BrushBaker Compute/X/bakeDanceFloor.compute new file mode 100644 index 0000000000..dee2f75420 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeDanceFloor.compute @@ -0,0 +1,44 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; +uniform float4x4 TransformWorldToObject; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + posWS = mul(half4x4(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1), posWS); + + float waveform = 0; + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) + // we will take the t = 0 in this compute shader + float timedoty = 0; + + float lifetime = timedoty - uv1.w; + float release = saturate(lifetime); + + + float q = 5; + float3 quantPos = ceil(posWS.xyz * q) / q; + posWS.xyz = quantPos; + posWS.xyz += normal * pow(fmod(lifetime,1),3) * .1; + + float4 posOS = mul(TransformWorldToObject, posWS); + vertex = posOS.xyz; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeDanceFloor.compute.meta b/Assets/Shaders/BrushBaker Compute/X/bakeDanceFloor.compute.meta new file mode 100644 index 0000000000..e74864941a --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeDanceFloor.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: db29274d68efa2048a8c96cb6cac4f90 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeKeijiroTube.compute b/Assets/Shaders/BrushBaker Compute/X/bakeKeijiroTube.compute new file mode 100644 index 0000000000..8030724ca8 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeKeijiroTube.compute @@ -0,0 +1,38 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + float radius = uv0.z; + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) and _Time.z (t * 2) + // we will take the t = 1 in this compute shader + + // this is a little bit different + // _Time.z is used to create a building effect on the mesh + // so I have set the time to be 1.0 so the mesh is build finished + // in the future, this brush have to interpolate from 0 to 1 + // in order to rebuild the building effect + + float timedoty = 1; + float timedotz = timedoty * 2; + + float wave = sin(uv0.x - timedotz); + float pulse = smoothstep(.45, .5, saturate(wave)); + vertex -= pulse * radius * normal.xyz; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeKeijiroTube.compute.meta b/Assets/Shaders/BrushBaker Compute/X/bakeKeijiroTube.compute.meta new file mode 100644 index 0000000000..3b31337c18 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeKeijiroTube.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 7aaef9828dec8e745a7078f169541071 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeRain.compute b/Assets/Shaders/BrushBaker Compute/X/bakeRain.compute new file mode 100644 index 0000000000..19be2a15a0 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeRain.compute @@ -0,0 +1,25 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + // Inflate the tube outward to explode it into + // strips - giving us negative space w/o as much overdraw. + float bulge = 2.25; + float radius = uv0.z; + vertex.xyz += normal.xyz * bulge * radius; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeRain.compute.meta b/Assets/Shaders/BrushBaker Compute/X/bakeRain.compute.meta new file mode 100644 index 0000000000..291e5f3a60 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeRain.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 177e3315ef9abb4419da277431781388 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeSparks.compute b/Assets/Shaders/BrushBaker Compute/X/bakeSparks.compute new file mode 100644 index 0000000000..b41a5e6750 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeSparks.compute @@ -0,0 +1,23 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + float displacementExponent = 2.84; + float displacementAmount = 1.45; + vertex += normal * pow(uv0.x, displacementExponent) * displacementAmount; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeSparks.compute.meta b/Assets/Shaders/BrushBaker Compute/X/bakeSparks.compute.meta new file mode 100644 index 0000000000..31e9dc4511 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeSparks.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 95faa217ff7d8694fafbe2851266042a +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeWaveformParticles.compute b/Assets/Shaders/BrushBaker Compute/X/bakeWaveformParticles.compute new file mode 100644 index 0000000000..b008287108 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeWaveformParticles.compute @@ -0,0 +1,50 @@ +#pragma kernel CSMain + +#include "../../../ThirdParty/Shaders/Noise.cginc" + +uniform float4x4 TransformObjectToWorld; +uniform float4x4 TransformWorldToObject; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float4 color = colorBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) + // we will take the t = 0 in this compute shader + float timedoty = 0; + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float3 perVertOffset = uv1.xyz; + float lifetime = timedoty - uv1.w; + float release = saturate(lifetime * .1); + float3 localMidpointPos = vertex.xyz - perVertOffset; + float4 worldMidpointPos = mul(TransformObjectToWorld, localMidpointPos); + + float time = lifetime; + float d = 10 + color.g * 3; + float freq = 1.5 + color.r; + float3 disp = float3(1,0,0) * curlX(worldMidpointPos.xyz * freq + time, d); + disp += float3(0,1,0) * curlY(worldMidpointPos.xyz * freq +time, d); + disp += float3(0,0,1) * curlZ(worldMidpointPos.xyz * freq + time, d); + + worldMidpointPos.xyz += release * disp * 10; + posWS.xyz = worldMidpointPos.xyz + perVertOffset; + + float4 posOS = mul(TransformWorldToObject, posWS); + vertex = posOS.xyz; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/X/bakeWaveformParticles.compute.meta b/Assets/Shaders/BrushBaker Compute/X/bakeWaveformParticles.compute.meta new file mode 100644 index 0000000000..8d25de8ac7 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/X/bakeWaveformParticles.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: a79673b84c7f0ce4cac3f2d9d312b765 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeBubbles.compute b/Assets/Shaders/BrushBaker Compute/bakeBubbles.compute new file mode 100644 index 0000000000..b5fe33bb7b --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeBubbles.compute @@ -0,0 +1,82 @@ +#pragma kernel CSMain + +#include "../../ThirdParty/Shaders/Noise.cginc" + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + // according to paricles.cginc, the originWS for ParticleVertexWithSpread_t + // is the normal.xyz instead of uv1 + float4 originWS = mul(TransformObjectToWorld, float4(normal.xyz, 1.0)); + // float4 originWS = mul(TransformObjectToWorld, float4(uv1, 1.0)); + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (uv0.x + uv0.y == 0) then (-length, -length, 0) + // if (uv0.x + uv0.y == 2) then (length, length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == -1) then (length, -length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == 1) then (-length, length, 0) + + float uv0Sum = uv0.x + uv0.y; + float uv0Dif = uv0.x - uv0.y; + + float3 preBillboard = float3(-length, length, 0); + + if (uv0Sum == 0) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 2) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Dif == -1) + { + preBillboard = float3(length, -length, 0); + } + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) and _Time.x (t/20) + // we will take the t = 0 in this compute shader + float timedoty = 0; + float timedotx = timedoty / 20; + + + // // leaving this parameters here for generating animated mesh in the future + + // float t = timedoty * 0.5 + 1; + // float3 jitter = float3(0, 0, 0); + + // jitter.x = sin(t + timedoty + originWS.z * 0.2); + // jitter.y = cos(t + timedoty + originWS.x * 0.2); + // jitter.z = cos(t * 1.2 + timedoty + originWS.x * 0.2); + // jitter *= 0.02; + + // float3 v = (originWS.xyz + jitter) * 0.1 + timedotx * 5; + // float d = 30; + + // // Using noise.cginc + // float3 curl = float3(curlX(v, d), curlY(v, d), curlZ(v, d)) * 10; + // originWS.xyz += (jitter + curl) * 0.1; + + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeBubbles.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeBubbles.compute.meta new file mode 100644 index 0000000000..0598c2a8f8 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeBubbles.compute.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: bbd51e4e329047f439104cbc04383597 +ComputeShaderImporter: + externalObjects: {} + preprocessorOverride: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Shaders/BrushBaker Compute/bakeDisco.compute b/Assets/Shaders/BrushBaker Compute/bakeDisco.compute new file mode 100644 index 0000000000..84353d66c1 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeDisco.compute @@ -0,0 +1,37 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) and _Time.z (t * 2) + // we will take the t = 0 in this compute shader + float timedoty = 0; + float timedotz = timedoty * 2; + + // default values without Audio Reactivity + float t = timedotz; + float uTileRate = 10; + float waveIntensity = 0.6f; + float radius = uv0.z; + + // Ensure the t parameter wraps (1.0 becomes 0.0) to avoid cracks at the seam. + float theta = fmod(uv0.y, 1); + vertex += pow(1 -(sin(t + uv0.x * uTileRate + theta * 10) + 1),2) + * normal.xyz * waveIntensity + * radius; + + vertexBuffer[id.x] = vertex; +} \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeDisco.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeDisco.compute.meta new file mode 100644 index 0000000000..5ec5a5e5b2 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeDisco.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 612bca9f4c2f46e4da8c23150c4fcac5 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeDots.compute b/Assets/Shaders/BrushBaker Compute/bakeDots.compute new file mode 100644 index 0000000000..755309d5c4 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeDots.compute @@ -0,0 +1,51 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + float4 originWS = mul(TransformObjectToWorld, float4(uv1.xyz, 1.0)); + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (uv0.x + uv0.y == 0) then (-length, -length, 0) + // if (uv0.x + uv0.y == 2) then (length, length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == -1) then (length, -length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == 1) then (-length, length, 0) + + float uv0Sum = uv0.x + uv0.y; + float uv0Dif = uv0.x - uv0.y; + + float3 preBillboard = float3(-length, length, 0); + + if (uv0Sum == 0) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 2) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Dif == -1) + { + preBillboard = float3(length, -length, 0); + } + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeDots.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeDots.compute.meta new file mode 100644 index 0000000000..c69936e70e --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeDots.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 2daa4d77d81adc84a88e67f8a7b22ac8 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeDoubleTaperedX.compute b/Assets/Shaders/BrushBaker Compute/bakeDoubleTaperedX.compute new file mode 100644 index 0000000000..73a445abf7 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeDoubleTaperedX.compute @@ -0,0 +1,24 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + float envelope = sin(uv0.x * 3.14159); + float widthMultiplier = 1 - envelope; + vertex += -uv1.xyz * widthMultiplier; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeDoubleTaperedX.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeDoubleTaperedX.compute.meta new file mode 100644 index 0000000000..61e312eb4f --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeDoubleTaperedX.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 67c631d4aac299f4bbaad06dd830312e +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeElectricity.compute b/Assets/Shaders/BrushBaker Compute/bakeElectricity.compute new file mode 100644 index 0000000000..2820def72f --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeElectricity.compute @@ -0,0 +1,66 @@ +#pragma kernel CSMain + +#include "../../ThirdParty/Shaders/Noise.cginc" + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + half envelope = sin(uv0.x * 3.14159); + half envelopePow = (1-pow(1 - envelope, 10)); + + half3 offsetFromMiddleToEdge_CS = uv1.xyz; + half widthiness_CS = length(offsetFromMiddleToEdge_CS) / .02; + half3 midpointPos_CS = vertex.xyz - offsetFromMiddleToEdge_CS; + vertex = midpointPos_CS + offsetFromMiddleToEdge_CS * envelopePow; + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) and _Time.x (t/20) + // we will take the t = 0 in this compute shader + + // // leaving this parameters here for generating animated mesh in the future + + // float timedoty = 0; + // float timedotw = timedoty * 3; + + // // Note: Electricity is a multiple render passes shader + // // each pass will have a different offset + + // // mod is the offset of the wave. Values from the source Project: 1, 1.333, 1.77 + // float mod = 1; + + // float time = timedotw; + // float d = 30; + // float freq = .1 + mod; + // float3 pos = midpointPos_CS / widthiness_CS; + // float3 disp = float3(1,0,0) * curlX(pos * freq + time, d); + // disp += float3(0,1,0) * curlY(pos * freq + time, d); + // disp += float3(0,0,1) * curlZ(pos * freq + time, d); + + // time = timedotw*1.777; + // d = 100; + // freq = .2 + mod; + // float3 disp2 = float3(1,0,0) * curlX(pos * freq + time, d); + // disp2 += float3(0,1,0) * curlY(pos * freq + time, d); + // disp2 += float3(0,0,1) * curlZ(pos * freq + time, d); + // disp = disp * 3 + disp2 * 7; + + // disp *= widthiness_CS; + + // float displacementIntensity = 2; + // vertex += disp * displacementIntensity * envelopePow; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeElectricity.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeElectricity.compute.meta new file mode 100644 index 0000000000..d4dfd746ab --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeElectricity.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 94bcafbff8d69c044a155b7a7254904b +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeEmbers.compute b/Assets/Shaders/BrushBaker Compute/bakeEmbers.compute new file mode 100644 index 0000000000..d8647d0c89 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeEmbers.compute @@ -0,0 +1,78 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float4 color = colorBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + // according to paricles.cginc, the originWS for ParticleVertexWithSpread_t + // is the normal.xyz instead of uv1 + float4 originWS = mul(TransformObjectToWorld, float4(normal.xyz, 1.0)); + // float4 originWS = mul(TransformObjectToWorld, float4(uv1, 1.0)); + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (uv0.x + uv0.y == 0) then (-length, -length, 0) + // if (uv0.x + uv0.y == 2) then (length, length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == -1) then (length, -length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == 1) then (-length, length, 0) + + float uv0Sum = uv0.x + uv0.y; + float uv0Dif = uv0.x - uv0.y; + + float3 preBillboard = float3(-length, length, 0); + + if (uv0Sum == 0) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 2) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Dif == -1) + { + preBillboard = float3(length, -length, 0); + } + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) + // we will take the t = 0 in this compute shader + float timedoty = 0; + + + // // leaving this parameters here for generating animated mesh in the future + + // float seed = color.a; + // float t01 = fmod(timedoty * 0.6 + seed * 10, 1); + // float4 dispVec = float4(2.0, 6.0, 0.0, 0.0) * t01; + + // dispVec.x += sin(t01 * 5 + seed * 100 + timedoty + originWS.z) * 0.3; + // dispVec.y += (fmod(seed * 100, 1) - 0.5) * 6.0 * t01; + // dispVec.z += cos(t01 * 5 + seed * 100 + timedoty + originWS.x) * 0.3; + + // dispVec *= 0.1; + // dispVec *= length(TransformObjectToWorld[0].xyz); + + // vertex += dispVec; + + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeEmbers.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeEmbers.compute.meta new file mode 100644 index 0000000000..93a1d8394c --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeEmbers.compute.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: df2047dd556be4d47ba22aba4f71c0f5 +ComputeShaderImporter: + externalObjects: {} + preprocessorOverride: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Shaders/BrushBaker Compute/bakeHyperGrid.compute b/Assets/Shaders/BrushBaker Compute/bakeHyperGrid.compute new file mode 100644 index 0000000000..9576f469db --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeHyperGrid.compute @@ -0,0 +1,36 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; +uniform float4x4 TransformWorldToObject; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + // Subtract out the Canvas space pose to keep the verts from popping around while + // transforming (e.g. apply quantization in an immutable space). + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + posWS = mul(half4x4(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1), posWS); + + // for AltspaceVR(or any other apps) to scale the hypergrid but maintain snapping on the grid + half size = length(half3(TransformObjectToWorld[0].x, TransformObjectToWorld[1].x, TransformObjectToWorld[2].x)) * length(uv1.xyz); + + half q = (1.0f / size) * .5; + half3 quantPos = ceil(posWS.xyz * q) / q; + posWS.xyz = quantPos; + posWS = mul(half4x4(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1), posWS); + float4 posOS = mul(TransformWorldToObject, posWS); + vertex = posOS.xyz; + + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeHyperGrid.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeHyperGrid.compute.meta new file mode 100644 index 0000000000..f485483475 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeHyperGrid.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: cfa508c5ac021eb4484efcd508d86f28 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeLightWire.compute b/Assets/Shaders/BrushBaker Compute/bakeLightWire.compute new file mode 100644 index 0000000000..0257bfe800 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeLightWire.compute @@ -0,0 +1,25 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + + float t; + float envelope = sin ( fmod ( uv0.x * 2, 1.0f) * 3.14159); + float lights = envelope < .15 ? 1 : 0; + float radius = uv0.z * 0.9; + vertex.xyz += normal * lights * radius; + + vertexBuffer[id.x] = vertex; +} \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeLightWire.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeLightWire.compute.meta new file mode 100644 index 0000000000..185fe6862e --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeLightWire.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: f1766ed0ee9b8634d9ad77ef8ec34e0d +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeMylar.compute b/Assets/Shaders/BrushBaker Compute/bakeMylar.compute new file mode 100644 index 0000000000..5b8859bbbc --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeMylar.compute @@ -0,0 +1,21 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; + +float _SqueezeAmount; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 uv = uvBuffer[id.x]; + const float radius = uv.z; + const float squeeze = sin(uv.x * 3.14159); + const float3 squeeze_displacement = radius * normalBuffer[id.x] * squeeze; + vertex -= squeeze_displacement * _SqueezeAmount; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeMylar.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeMylar.compute.meta new file mode 100644 index 0000000000..2baa50f45a --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeMylar.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: a8cd83718b2e48db9570f9195dfde315 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeRisingBubbles.compute b/Assets/Shaders/BrushBaker Compute/bakeRisingBubbles.compute new file mode 100644 index 0000000000..f665a46e87 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeRisingBubbles.compute @@ -0,0 +1,82 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + // according to paricles.cginc, the originWS for ParticleVertexWithSpread_t + // is the normal.xyz instead of uv1 + float4 originWS = mul(TransformObjectToWorld, float4(normal.xyz, 1.0)); + // float4 originWS = mul(TransformObjectToWorld, float4(uv1, 1.0)); + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (uv0.x + uv0.y == 0) then (-length, -length, 0) + // if (uv0.x + uv0.y == 2) then (length, length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == -1) then (length, -length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == 1) then (-length, length, 0) + + float uv0Sum = uv0.x + uv0.y; + float uv0Dif = uv0.x - uv0.y; + + float3 preBillboard = float3(-length, length, 0); + + if (uv0Sum == 0) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 2) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Dif == -1) + { + preBillboard = float3(length, -length, 0); + } + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) and _Time.x (t/20) + // we will take the t = 0 in this compute shader + float timedoty = 0; + float timedotx = timedoty / 20; + + + // // leaving this parameters here for generating animated mesh in the future + + // // ----------- Nicholas: this part haven't tested yet ---------------- + // float seed = color.a; + // float t01 = fmod(timedoty * 0.1 + seed * 10, 1); + // float t2 = timedoty / 3; + // float scrollJitterFrequency = 5; + // float scrollJitterIntensity = 0.2; + // float3 scrollDistance = new float3(0.5, 5, 0); + // float4 dispVec = new float4(scrollDistance, 0,0) * t01; + // dispVec.x += sin(t01 * scrollJitterFrequency + seed * 10 + t2 + originWS.z) * scrollJitterIntensity; + // dispVec.y += (fmod(seed * 100, 1) - 0.5) * scrollDistance.y * t01; + // dispVec.z += cos(t01 * scrollJitterFrequency + seed * 7 + t2 + originWS.x) * scrollJitterIntensity; + + // vertex += dispVec; + + // // --------------------------------------------------------------------- + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeRisingBubbles.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeRisingBubbles.compute.meta new file mode 100644 index 0000000000..04d6005c4c --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeRisingBubbles.compute.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d5d5ade2144b877458cb85b63f87db45 +ComputeShaderImporter: + externalObjects: {} + preprocessorOverride: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Assets/Shaders/BrushBaker Compute/bakeSmoke.compute b/Assets/Shaders/BrushBaker Compute/bakeSmoke.compute new file mode 100644 index 0000000000..bc668170fa --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeSmoke.compute @@ -0,0 +1,72 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + float4 originWS = mul(TransformObjectToWorld, float4(uv1.xyz, 1.0)); + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (6 * uv0.x + 10 * uv0.y == 0 or 6 or 10 or 16) then (length, length, 0) + // if (uv0.x + uv0.y == 8) then (-length, -length, 0) + // if (uv0.x + uv0.y == 3 or 13) then (length, -length, 0) + // if (uv0.x + uv0.y == 5 or 11) then (-length, length, 0) + + float uv0Sum = 6 * uv0.x + 10 * uv0.y; + + float3 preBillboard = float3(length, -length, 0); + + if (uv0Sum == 5 || uv0Sum == 11) + { + preBillboard = float3(-length, length, 0); + } + else if (uv0Sum == 8) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 0 || uv0Sum == 6 || uv0Sum == 10 || uv0Sum == 16) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Sum == 3 || uv0Sum == 13) + { + preBillboard = float3(length, -length, 0); + } + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) and _Time.x (t/20) + // we will take the t = 0 in this compute shader + float timedoty = 0; + float timedotx = timedoty / 20; + + + // // leaving this parameters here for generating animated mesh in the future + + // float time = timedotx * 5; + // float d = 30; + // float freq = 0.1; + // float3 disp = float3(1, 0, 0) * curlX(originWS.xyz * freq + time, d); + // disp += float3(0,1,0) * curlY(originWS.xyz * freq + time, d); + // disp += float3(0,0,1) * curlZ(originWS.xyz * freq + time, d); + // disp = disp * 5 * 0.1; + // vertex += disp; + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeSmoke.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeSmoke.compute.meta new file mode 100644 index 0000000000..7f25aecdc8 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeSmoke.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: ed79d827aabdf284f96a5bac36a050ba +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeSnow.compute b/Assets/Shaders/BrushBaker Compute/bakeSnow.compute new file mode 100644 index 0000000000..c51872bf05 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeSnow.compute @@ -0,0 +1,75 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float4 color = colorBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + // according to paricles.cginc, the originWS for ParticleVertexWithSpread_t + // is the normal.xyz instead of uv1 + float4 originWS = mul(TransformObjectToWorld, float4(normal.xyz, 1.0)); + // float4 originWS = mul(TransformObjectToWorld, float4(uv1, 1.0)); + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (uv0.x + uv0.y == 0) then (-length, -length, 0) + // if (uv0.x + uv0.y == 2) then (length, length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == -1) then (length, -length, 0) + // if (uv0.x + uv0.y == 1 && uv0.x - uv0.y == 1) then (-length, length, 0) + + float uv0Sum = uv0.x + uv0.y; + float uv0Dif = uv0.x - uv0.y; + + float3 preBillboard = float3(-length, length, 0); + + if (uv0Sum == 0) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 2) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Dif == -1) + { + preBillboard = float3(length, -length, 0); + } + + // the movement is based on Unity Built-in shader variables + // _Time.y (t) + // we will take the t = 0 in this compute shader + float timedoty = 0; + + + // // leaving this parameters here for generating animated mesh in the future + + // float scrollAmount = timedoty; + // float t = fmod(scrollAmount * 0.2 + color.a, 1.0); + // float4 dispVec = (t - 0.5f) * float4(0, -3, 0, 0); + // dispVec.x += sin(t * 12 + timedoty) * 0.1; + // dispVec.z += cos(t * 12 * 0.5 + timedoty) * 0.1; + // dispVec *= 0.1; + // vertex += dispVec.xyz; + + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeSnow.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeSnow.compute.meta new file mode 100644 index 0000000000..1a3398fa62 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeSnow.compute.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: c7771aa61c3be544eae35185c59c39c4 +timeCreated: 1706099175 \ No newline at end of file diff --git a/Assets/Shaders/BrushBaker Compute/bakeStars.compute b/Assets/Shaders/BrushBaker Compute/bakeStars.compute new file mode 100644 index 0000000000..58e702a3e4 --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeStars.compute @@ -0,0 +1,60 @@ +#pragma kernel CSMain + +uniform float4x4 TransformObjectToWorld; + +RWStructuredBuffer vertexBuffer; +StructuredBuffer normalBuffer; +StructuredBuffer colorBuffer; +StructuredBuffer uvBuffer; +StructuredBuffer uv1Buffer; + +float _SqueezeAmount; + +static const float kRecipSquareRootOfTwo = 0.70710678; + + +[numthreads(8, 1, 1)] +void CSMain(uint3 id : SV_DispatchThreadID) { + float3 vertex = vertexBuffer[id.x]; + float3 normal = normalBuffer[id.x]; + float3 uv0 = uvBuffer[id.x]; + float4 uv1 = uv1Buffer[id.x]; + + // according to paricles.cginc, the originWS for ParticleVertexWithSpread_t + // is the normal.xyz instead of uv1 + float4 originWS = mul(TransformObjectToWorld, float4(normal.xyz, 1.0)); + // float4 originWS = mul(TransformObjectToWorld, float4(uv1, 1.0)); + + float4 posWS = mul(TransformObjectToWorld, float4(vertex, 1.0)); + float length = distance(originWS.xyz, posWS.xyz); + length *= kRecipSquareRootOfTwo; + + // if (6 * uv0.x + 10 * uv0.y == 0 or 6 or 10 or 16) then (length, length, 0) + // if (uv0.x + uv0.y == 8) then (-length, -length, 0) + // if (uv0.x + uv0.y == 3 or 13) then (length, -length, 0) + // if (uv0.x + uv0.y == 5 or 11) then (-length, length, 0) + + float uv0Sum = 6 * uv0.x + 10 * uv0.y; + + float3 preBillboard = float3(length, -length, 0); + + if (uv0Sum == 5 || uv0Sum == 11) + { + preBillboard = float3(-length, length, 0); + } + else if (uv0Sum == 8) + { + preBillboard = float3(-length, -length, 0); + } + else if (uv0Sum == 0 || uv0Sum == 6 || uv0Sum == 10 || uv0Sum == 16) + { + preBillboard = float3(length, length, 0); + } + else if (uv0Sum == 3 || uv0Sum == 13) + { + preBillboard = float3(length, -length, 0); + } + + vertex = originWS.xyz + preBillboard; + vertexBuffer[id.x] = vertex; +} diff --git a/Assets/Shaders/BrushBaker Compute/bakeStars.compute.meta b/Assets/Shaders/BrushBaker Compute/bakeStars.compute.meta new file mode 100644 index 0000000000..0f61ba2aaf --- /dev/null +++ b/Assets/Shaders/BrushBaker Compute/bakeStars.compute.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 88c0f5ccf81e44249b28909e1a12e099 +ComputeShaderImporter: + externalObjects: {} + preprocessorOverride: 0 + userData: + assetBundleName: + assetBundleVariant: diff --git a/Packages/manifest.json b/Packages/manifest.json index 3c0bd090ae..a9581a0223 100644 --- a/Packages/manifest.json +++ b/Packages/manifest.json @@ -5,13 +5,16 @@ "com.meta.xr.sdk.utilities": "https://github.com/icosa-mirror/com.meta.xr.sdk.core.git#56.0.0-openbrush", "com.unity.2d.sprite": "1.0.0", "com.unity.2d.tilemap": "1.0.0", - "com.unity.cloud.gltfast": "6.0.1", + "com.unity.cloud.draco": "5.1.3", + "com.unity.cloud.gltfast": "6.4.0", + "com.unity.cloud.ktx": "3.4.0", "com.unity.editorcoroutines": "1.0.0", "com.unity.formats.usd": "1.0.3-preview.2", "com.unity.ide.rider": "3.0.28", "com.unity.ide.visualstudio": "2.0.20", "com.unity.inputsystem": "https://github.com/icosa-mirror/com.unity.inputsystem.git#open-brush", "com.unity.localization": "1.4.2", + "com.unity.meshopt.decompress": "0.1.0-preview.6", "com.unity.mobile.android-logcat": "1.3.2", "com.unity.nuget.mono-cecil": "1.10.2", "com.unity.performance.profile-analyzer": "1.2.2", @@ -25,6 +28,7 @@ "com.unity.xr.oculus": "3.3.0", "com.unity.xr.openxr": "1.8.2", "com.zappar.xr.zapbox": "https://github.com/zappar-xr/zapbox-xr-sdk.git#3296cbf5046369801027a821fe9ff6082431a605", + "org.khronos.unitygltf": "https://github.com/icosa-mirror/UnityGLTF.git", "org.nuget.google.apis": "1.64.0", "org.nuget.google.apis.auth": "1.64.0", "org.nuget.google.apis.core": "https://github.com/icosa-mirror/org.nuget.google.apis.core.git#1.64.0-openbrush", diff --git a/Packages/packages-lock.json b/Packages/packages-lock.json index 2ea2729747..11d7a818cf 100644 --- a/Packages/packages-lock.json +++ b/Packages/packages-lock.json @@ -57,7 +57,7 @@ "url": "https://packages.unity.com" }, "com.unity.burst": { - "version": "1.8.4", + "version": "1.8.11", "depth": 1, "source": "registry", "dependencies": { @@ -65,8 +65,18 @@ }, "url": "https://packages.unity.com" }, + "com.unity.cloud.draco": { + "version": "5.1.3", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.burst": "1.8.11", + "com.unity.mathematics": "1.3.1" + }, + "url": "https://packages.unity.com" + }, "com.unity.cloud.gltfast": { - "version": "6.0.1", + "version": "6.4.0", "depth": 0, "source": "registry", "dependencies": { @@ -77,6 +87,15 @@ }, "url": "https://packages.unity.com" }, + "com.unity.cloud.ktx": { + "version": "3.4.0", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.modules.unitywebrequest": "1.0.0" + }, + "url": "https://packages.unity.com" + }, "com.unity.editorcoroutines": { "version": "1.0.0", "depth": 0, @@ -144,6 +163,16 @@ "dependencies": {}, "url": "https://packages.unity.com" }, + "com.unity.meshopt.decompress": { + "version": "0.1.0-preview.6", + "depth": 0, + "source": "registry", + "dependencies": { + "com.unity.mathematics": "1.2.1", + "com.unity.burst": "1.4.11" + }, + "url": "https://packages.unity.com" + }, "com.unity.mobile.android-logcat": { "version": "1.3.2", "depth": 0, @@ -172,6 +201,16 @@ "dependencies": {}, "url": "https://packages.unity.com" }, + "com.unity.render-pipelines.core": { + "version": "12.1.12", + "depth": 2, + "source": "builtin", + "dependencies": { + "com.unity.ugui": "1.0.0", + "com.unity.modules.physics": "1.0.0", + "com.unity.modules.jsonserialize": "1.0.0" + } + }, "com.unity.scriptablebuildpipeline": { "version": "1.20.2", "depth": 2, @@ -179,6 +218,22 @@ "dependencies": {}, "url": "https://packages.unity.com" }, + "com.unity.searcher": { + "version": "4.9.1", + "depth": 2, + "source": "registry", + "dependencies": {}, + "url": "https://packages.unity.com" + }, + "com.unity.shadergraph": { + "version": "12.1.12", + "depth": 1, + "source": "builtin", + "dependencies": { + "com.unity.render-pipelines.core": "12.1.12", + "com.unity.searcher": "4.9.1" + } + }, "com.unity.test-framework": { "version": "1.1.33", "depth": 0, @@ -237,7 +292,7 @@ "com.unity.modules.unitywebrequesttexture": "1.0.0", "com.unity.modules.unitywebrequestwww": "1.0.0" }, - "hash": "e46c04cb7ed068ee7f31289530f10fbb478906cc" + "hash": "214037a894f7e292687b8ba331f5c959c2bcdd8b" }, "com.unity.xr.core-utils": { "version": "2.2.3", @@ -301,6 +356,18 @@ }, "hash": "3296cbf5046369801027a821fe9ff6082431a605" }, + "org.khronos.unitygltf": { + "version": "https://github.com/icosa-mirror/UnityGLTF.git", + "depth": 0, + "source": "git", + "dependencies": { + "com.unity.nuget.newtonsoft-json": "2.0.0", + "com.unity.modules.imageconversion": "1.0.0", + "com.unity.shadergraph": "10.0.0", + "com.unity.mathematics": "1.0.0" + }, + "hash": "99c96d9029d4ce02e5f729a5e069a44aef6faa99" + }, "org.nuget.google.apis": { "version": "1.64.0", "depth": 0, diff --git a/ProjectSettings/ProjectSettings.asset b/ProjectSettings/ProjectSettings.asset index dad5dd7d2a..1c4b9ab0ad 100644 --- a/ProjectSettings/ProjectSettings.asset +++ b/ProjectSettings/ProjectSettings.asset @@ -180,7 +180,7 @@ PlayerSettings: AndroidMinSdkVersion: 29 AndroidTargetSdkVersion: 32 AndroidPreferredInstallLocation: 0 - aotOptions: + aotOptions: stripEngineCode: 1 iPhoneStrippingLevel: 0 iPhoneScriptCallOptimization: 0 @@ -220,7 +220,7 @@ PlayerSettings: rgba: 0 iOSLaunchScreenFillPct: 1 iOSLaunchScreenSize: 100 - iOSLaunchScreenCustomXibPath: + iOSLaunchScreenCustomXibPath: iOSLaunchScreeniPadType: 0 iOSLaunchScreeniPadImage: {fileID: 0} iOSLaunchScreeniPadBackgroundColor: @@ -228,9 +228,9 @@ PlayerSettings: rgba: 0 iOSLaunchScreeniPadFillPct: 100 iOSLaunchScreeniPadSize: 100 - iOSLaunchScreeniPadCustomXibPath: - iOSLaunchScreenCustomStoryboardPath: - iOSLaunchScreeniPadCustomStoryboardPath: + iOSLaunchScreeniPadCustomXibPath: + iOSLaunchScreenCustomStoryboardPath: + iOSLaunchScreeniPadCustomStoryboardPath: iOSDeviceRequirements: [] iOSURLSchemes: [] macOSURLSchemes: [] @@ -240,9 +240,9 @@ PlayerSettings: metalAPIValidation: 1 iOSRenderExtraFrameOnPause: 1 iosCopyPluginsCodeInsteadOfSymlink: 0 - appleDeveloperTeamID: - iOSManualSigningProvisioningProfileID: - tvOSManualSigningProvisioningProfileID: + appleDeveloperTeamID: + iOSManualSigningProvisioningProfileID: + tvOSManualSigningProvisioningProfileID: iOSManualSigningProvisioningProfileType: 0 tvOSManualSigningProvisioningProfileType: 0 appleEnableAutomaticSigning: 0 @@ -251,8 +251,8 @@ PlayerSettings: appleEnableProMotion: 0 shaderPrecisionModel: 0 clonedFromGUID: 00000000000000000000000000000000 - templatePackageId: - templateDefaultScene: + templatePackageId: + templateDefaultScene: useCustomMainManifest: 0 useCustomLauncherManifest: 0 useCustomMainGradleTemplate: 0 @@ -264,8 +264,8 @@ PlayerSettings: AndroidTargetDevices: 0 AndroidSplashScreenScale: 0 androidSplashScreen: {fileID: 0} - AndroidKeystoreName: - AndroidKeyaliasName: + AndroidKeystoreName: + AndroidKeyaliasName: AndroidBuildApkPerCpuArchitecture: 0 AndroidTVCompatibility: 0 AndroidIsGame: 1 @@ -285,7 +285,7 @@ PlayerSettings: AndroidValidateAppBundleSize: 1 AndroidAppBundleSizeToValidate: 150 m_BuildTargetIcons: - - m_BuildTarget: + - m_BuildTarget: m_Icons: - serializedVersion: 2 m_Icon: {fileID: 2800000, guid: 819e7471e6f639f4da51f3b379351b19, type: 3} @@ -299,92 +299,92 @@ PlayerSettings: m_Width: 432 m_Height: 432 m_Kind: 2 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 324 m_Height: 324 m_Kind: 2 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 216 m_Height: 216 m_Kind: 2 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 162 m_Height: 162 m_Kind: 2 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 108 m_Height: 108 m_Kind: 2 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 81 m_Height: 81 m_Kind: 2 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 192 m_Height: 192 m_Kind: 0 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 144 m_Height: 144 m_Kind: 0 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 96 m_Height: 96 m_Kind: 0 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 72 m_Height: 72 m_Kind: 0 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 48 m_Height: 48 m_Kind: 0 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 36 m_Height: 36 m_Kind: 0 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 192 m_Height: 192 m_Kind: 1 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 144 m_Height: 144 m_Kind: 1 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 96 m_Height: 96 m_Kind: 1 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 72 m_Height: 72 m_Kind: 1 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 48 m_Height: 48 m_Kind: 1 - m_SubKind: + m_SubKind: - m_Textures: [] m_Width: 36 m_Height: 36 m_Kind: 1 - m_SubKind: + m_SubKind: - m_BuildTarget: iPhone m_Icons: - m_Textures: [] @@ -620,11 +620,11 @@ PlayerSettings: logObjCUncaughtExceptions: 1 enableCrashReportAPI: 0 cameraUsageDescription: Not Used - locationUsageDescription: + locationUsageDescription: microphoneUsageDescription: Not Used - bluetoothUsageDescription: - switchNMETAOverride: - switchNetLibKey: + bluetoothUsageDescription: + switchNMETAOverride: + switchNetLibKey: switchSocketMemoryPoolSize: 6144 switchSocketAllocatorPoolSize: 128 switchSocketConcurrencyLimit: 14 @@ -633,39 +633,39 @@ PlayerSettings: switchUseGOLDLinker: 0 switchLTOSetting: 0 switchApplicationID: 0x0005000C10000001 - switchNSODependencies: - switchTitleNames_0: - switchTitleNames_1: - switchTitleNames_2: - switchTitleNames_3: - switchTitleNames_4: - switchTitleNames_5: - switchTitleNames_6: - switchTitleNames_7: - switchTitleNames_8: - switchTitleNames_9: - switchTitleNames_10: - switchTitleNames_11: - switchTitleNames_12: - switchTitleNames_13: - switchTitleNames_14: - switchTitleNames_15: - switchPublisherNames_0: - switchPublisherNames_1: - switchPublisherNames_2: - switchPublisherNames_3: - switchPublisherNames_4: - switchPublisherNames_5: - switchPublisherNames_6: - switchPublisherNames_7: - switchPublisherNames_8: - switchPublisherNames_9: - switchPublisherNames_10: - switchPublisherNames_11: - switchPublisherNames_12: - switchPublisherNames_13: - switchPublisherNames_14: - switchPublisherNames_15: + switchNSODependencies: + switchTitleNames_0: + switchTitleNames_1: + switchTitleNames_2: + switchTitleNames_3: + switchTitleNames_4: + switchTitleNames_5: + switchTitleNames_6: + switchTitleNames_7: + switchTitleNames_8: + switchTitleNames_9: + switchTitleNames_10: + switchTitleNames_11: + switchTitleNames_12: + switchTitleNames_13: + switchTitleNames_14: + switchTitleNames_15: + switchPublisherNames_0: + switchPublisherNames_1: + switchPublisherNames_2: + switchPublisherNames_3: + switchPublisherNames_4: + switchPublisherNames_5: + switchPublisherNames_6: + switchPublisherNames_7: + switchPublisherNames_8: + switchPublisherNames_9: + switchPublisherNames_10: + switchPublisherNames_11: + switchPublisherNames_12: + switchPublisherNames_13: + switchPublisherNames_14: + switchPublisherNames_15: switchIcons_0: {fileID: 0} switchIcons_1: {fileID: 0} switchIcons_2: {fileID: 0} @@ -698,9 +698,9 @@ PlayerSettings: switchSmallIcons_13: {fileID: 0} switchSmallIcons_14: {fileID: 0} switchSmallIcons_15: {fileID: 0} - switchManualHTML: - switchAccessibleURLs: - switchLegalInformation: + switchManualHTML: + switchAccessibleURLs: + switchLegalInformation: switchMainThreadStackSize: 1048576 switchPresenceGroupId: 0x0005000C10000001 switchLogoHandling: 0 @@ -709,7 +709,7 @@ PlayerSettings: switchStartupUserAccount: 0 switchSupportedLanguagesMask: 0 switchLogoType: 0 - switchApplicationErrorCodeCategory: + switchApplicationErrorCodeCategory: switchUserAccountSaveDataSize: 0 switchUserAccountSaveDataJournalSize: 0 switchApplicationAttribute: 0 @@ -730,13 +730,13 @@ PlayerSettings: switchRatingsInt_11: 0 switchRatingsInt_12: 0 switchLocalCommunicationIds_0: 0x0005000C10000001 - switchLocalCommunicationIds_1: - switchLocalCommunicationIds_2: - switchLocalCommunicationIds_3: - switchLocalCommunicationIds_4: - switchLocalCommunicationIds_5: - switchLocalCommunicationIds_6: - switchLocalCommunicationIds_7: + switchLocalCommunicationIds_1: + switchLocalCommunicationIds_2: + switchLocalCommunicationIds_3: + switchLocalCommunicationIds_4: + switchLocalCommunicationIds_5: + switchLocalCommunicationIds_6: + switchLocalCommunicationIds_7: switchParentalControl: 0 switchAllowsScreenshot: 1 switchAllowsVideoCapturing: 1 @@ -767,35 +767,35 @@ PlayerSettings: switchMicroSleepForYieldTime: 25 switchRamDiskSpaceSize: 12 ps4NPAgeRating: 12 - ps4NPTitleSecret: - ps4NPTrophyPackPath: + ps4NPTitleSecret: + ps4NPTrophyPackPath: ps4ParentalLevel: 1 ps4ContentID: ED1633-NPXX51362_00-0000000000000000 ps4Category: 0 ps4MasterVersion: 01.00 ps4AppVersion: 01.00 ps4AppType: 0 - ps4ParamSfxPath: + ps4ParamSfxPath: ps4VideoOutPixelFormat: 0 ps4VideoOutInitialWidth: 1920 ps4VideoOutBaseModeInitialWidth: 1920 ps4VideoOutReprojectionRate: 120 - ps4PronunciationXMLPath: - ps4PronunciationSIGPath: - ps4BackgroundImagePath: - ps4StartupImagePath: - ps4StartupImagesFolder: - ps4IconImagesFolder: - ps4SaveDataImagePath: - ps4SdkOverride: - ps4BGMPath: - ps4ShareFilePath: - ps4ShareOverlayImagePath: - ps4PrivacyGuardImagePath: - ps4ExtraSceSysFile: - ps4NPtitleDatPath: + ps4PronunciationXMLPath: + ps4PronunciationSIGPath: + ps4BackgroundImagePath: + ps4StartupImagePath: + ps4StartupImagesFolder: + ps4IconImagesFolder: + ps4SaveDataImagePath: + ps4SdkOverride: + ps4BGMPath: + ps4ShareFilePath: + ps4ShareOverlayImagePath: + ps4PrivacyGuardImagePath: + ps4ExtraSceSysFile: + ps4NPtitleDatPath: ps4RemotePlayKeyAssignment: -1 - ps4RemotePlayKeyMappingDir: + ps4RemotePlayKeyMappingDir: ps4PlayTogetherPlayerCount: 0 ps4EnterButtonAssignment: 1 ps4ApplicationParam1: 0 @@ -823,9 +823,9 @@ PlayerSettings: ps4ScriptOptimizationLevel: 3 ps4Audio3dVirtualSpeakerCount: 14 ps4attribCpuUsage: 0 - ps4PatchPkgPath: - ps4PatchLatestPkgPath: - ps4PatchChangeinfoPath: + ps4PatchPkgPath: + ps4PatchLatestPkgPath: + ps4PatchChangeinfoPath: ps4PatchDayOne: 0 ps4attribUserManagement: 0 ps4attribMoveSupport: 0 @@ -841,18 +841,18 @@ PlayerSettings: ps4attribEyeToEyeDistanceSettingVR: 0 ps4IncludedModules: [] ps4attribVROutputEnabled: 0 - monoEnv: + monoEnv: splashScreenBackgroundSourceLandscape: {fileID: 0} splashScreenBackgroundSourcePortrait: {fileID: 0} blurSplashScreenBackground: 1 - spritePackerPolicy: + spritePackerPolicy: webGLMemorySize: 256 webGLExceptionSupport: 0 webGLNameFilesAsHashes: 0 webGLDataCaching: 0 webGLDebugSymbols: 0 - webGLEmscriptenArgs: - webGLModulesDirectory: + webGLEmscriptenArgs: + webGLModulesDirectory: webGLTemplate: APPLICATION:Default webGLAnalyzeBuildSize: 0 webGLUseEmbeddedResources: 0 @@ -864,7 +864,7 @@ PlayerSettings: webGLPowerPreference: 2 scriptingDefineSymbols: Android: TILT_BRUSH - Standalone: TILT_BRUSH;USD_SUPPORTED;FBX_SUPPORTED;FBXSDK_RUNTIME;LATK_SUPPORTED + Standalone: TILT_BRUSH;USD_SUPPORTED;FBX_SUPPORTED;FBXSDK_RUNTIME;HAVE_GLTFAST; Windows Store Apps: TILT_BRUSH;USD_SUPPORTED iPhone: TILT_BRUSH additionalCompilerArguments: {} @@ -899,7 +899,7 @@ PlayerSettings: allowUnsafeCode: 1 useDeterministicCompilation: 1 enableRoslynAnalyzers: 1 - additionalIl2CppArgs: + additionalIl2CppArgs: scriptingRuntimeVersion: 1 gcIncremental: 0 assemblyVersionValidation: 1 @@ -911,10 +911,10 @@ PlayerSettings: m_MobileRenderingPath: 1 metroPackageName: com.yourcompany.yourproduct metroPackageVersion: 1.0.0.0 - metroCertificatePath: - metroCertificatePassword: - metroCertificateSubject: - metroCertificateIssuer: + metroCertificatePath: + metroCertificatePassword: + metroCertificateSubject: + metroCertificateIssuer: metroCertificateNotAfter: 0000000000000000 metroApplicationDescription: Virtual Reality Painting wsaImages: {} @@ -960,23 +960,23 @@ PlayerSettings: XboxOne: enus: true metroTargetDeviceFamilies: {} - metroFTAName: + metroFTAName: metroFTAFileTypes: [] - metroProtocolName: - vcxProjDefaultLanguage: - XboxOneProductId: - XboxOneUpdateKey: - XboxOneSandboxId: - XboxOneContentId: - XboxOneTitleId: - XboxOneSCId: - XboxOneGameOsOverridePath: - XboxOnePackagingOverridePath: - XboxOneAppManifestOverridePath: + metroProtocolName: + vcxProjDefaultLanguage: + XboxOneProductId: + XboxOneUpdateKey: + XboxOneSandboxId: + XboxOneContentId: + XboxOneTitleId: + XboxOneSCId: + XboxOneGameOsOverridePath: + XboxOnePackagingOverridePath: + XboxOneAppManifestOverridePath: XboxOneVersion: 1.0.0.0 XboxOnePackageEncryption: 0 XboxOnePackageUpdateGranularity: 2 - XboxOneDescription: + XboxOneDescription: XboxOneLanguage: - enus XboxOneCapability: [] @@ -989,8 +989,8 @@ PlayerSettings: XboxOneAllowedProductIds: [] XboxOnePersistentLocalStorageSize: 0 XboxOneXTitleMemory: 8 - XboxOneOverrideIdentityName: - XboxOneOverrideIdentityPublisher: + XboxOneOverrideIdentityName: + XboxOneOverrideIdentityPublisher: vrEditorSettings: {} cloudServicesEnabled: Analytics: 0 @@ -1003,26 +1003,26 @@ PlayerSettings: UNet: 0 Unity_Ads: 0 luminIcon: - m_Name: - m_ModelFolderPath: - m_PortalFolderPath: + m_Name: + m_ModelFolderPath: + m_PortalFolderPath: luminCert: - m_CertPath: + m_CertPath: m_SignPackage: 1 luminIsChannelApp: 0 luminVersion: m_VersionCode: 1 - m_VersionName: + m_VersionName: apiCompatibilityLevel: 6 activeInputHandler: 1 windowsGamepadBackendHint: 0 - cloudProjectId: + cloudProjectId: framebufferDepthMemorylessMode: 0 qualitySettingsNames: [] - projectName: - organizationId: + projectName: + organizationId: cloudEnabled: 0 legacyClampBlendShapeWeights: 1 - playerDataPath: + playerDataPath: forceSRGBBlit: 1 virtualTexturingSupportEnabled: 0 diff --git a/ProjectSettings/ShaderGraphSettings.asset b/ProjectSettings/ShaderGraphSettings.asset new file mode 100644 index 0000000000..9b28428b92 --- /dev/null +++ b/ProjectSettings/ShaderGraphSettings.asset @@ -0,0 +1,16 @@ +%YAML 1.1 +%TAG !u! tag:unity3d.com,2011: +--- !u!114 &1 +MonoBehaviour: + m_ObjectHideFlags: 61 + m_CorrespondingSourceObject: {fileID: 0} + m_PrefabInstance: {fileID: 0} + m_PrefabAsset: {fileID: 0} + m_GameObject: {fileID: 0} + m_Enabled: 1 + m_EditorHideFlags: 0 + m_Script: {fileID: 11500000, guid: de02f9e1d18f588468e474319d09a723, type: 3} + m_Name: + m_EditorClassIdentifier: + customInterpolatorErrorThreshold: 32 + customInterpolatorWarningThreshold: 16 diff --git a/Support/bin/gltf_export_textures.py b/Support/bin/gltf_export_textures.py index e96e3e3afd..30371a8559 100644 --- a/Support/bin/gltf_export_textures.py +++ b/Support/bin/gltf_export_textures.py @@ -46,7 +46,7 @@ def process_request(request): """Process a single downsample-and-copy request""" im = PIL.Image.open(request["source"]) if "P" in im.mode: - assert False, "Unexpected: png with indexed color" + assert False, f"Unexpected: png with indexed color: {request['source']}" # Un-palettize im = im.convert() @@ -59,7 +59,7 @@ def process_request(request): assert im.width >= desired_width assert im.height >= desired_height - bpp = {"RGBA": 4, "RGB": 3}[im.mode] + bpp = {"RGBA": 4, "RGB": 3, "L": 1}[im.mode] request["input_bytes"] = im.width * im.height * bpp request["output_bytes"] = desired_width * desired_height * bpp @@ -74,7 +74,20 @@ def process_request(request): if not os.path.isdir(outdir): os.makedirs(outdir) - im.save(request["destination"]) + # If the image is a jpeg then strip off the alpha channel + if ( + request["destination"].endswith(".jpg") + or request["destination"].endswith(".jpeg") + ) and im.mode == "RGBA": + im = im.convert("RGB") + + # Catch OSError and re-raise with a more informative message + try: + im.save(request["destination"]) + except OSError as ex: + raise OSError( + f"Error saving {request['destination']}: {ex.strerror} (code {ex.errno})" + ) from ex def main():