├── .gitignore ├── Examples.meta ├── Examples ├── Lenna.png ├── Lenna.png.meta ├── example.unity └── example.unity.meta ├── LICENSE ├── LICENSE.meta ├── README.md ├── README.md.meta ├── UiRoundedCorners.meta ├── UiRoundedCorners ├── DestroyHelper.cs ├── DestroyHelper.cs.meta ├── Editor.meta ├── Editor │ ├── ImageWithIndependentRoundedCornersInspector.cs │ ├── ImageWithIndependentRoundedCornersInspector.cs.meta │ ├── ImageWithRoundedCornersInspector.cs │ ├── ImageWithRoundedCornersInspector.cs.meta │ ├── Nobi.UiRoundedCorners.Editor.asmdef │ └── Nobi.UiRoundedCorners.Editor.asmdef.meta ├── ImageWithIndependentRoundedCorners.cs ├── ImageWithIndependentRoundedCorners.cs.meta ├── ImageWithRoundedCorners.cs ├── ImageWithRoundedCorners.cs.meta ├── IndependentRoundedCorners.shader ├── IndependentRoundedCorners.shader.meta ├── Nobi.UiRoundedCorners.asmdef ├── Nobi.UiRoundedCorners.asmdef.meta ├── RoundedCorners.shader ├── RoundedCorners.shader.meta ├── SDFUtils.cginc ├── SDFUtils.cginc.meta ├── ShaderSetup.cginc └── ShaderSetup.cginc.meta ├── gif-01.gif ├── gif-01.gif.meta ├── gif-02.gif ├── gif-02.gif.meta ├── gif-04.gif ├── gif-04.gif.meta ├── how-to-install.gif ├── how-to-install.gif.meta ├── image-00.png ├── image-00.png.meta ├── package.json ├── package.json.meta ├── separate-roundness.gif ├── separate-roundness.gif.meta ├── title.gif └── title.gif.meta /.gitignore: -------------------------------------------------------------------------------- 1 | [Ll]ibrary/ 2 | [Tt]emp/ 3 | [Oo]bj/ 4 | [Bb]uild/ 5 | [Bb]uilds/ 6 | [Ll]ogs/ 7 | 8 | # Never ignore Asset meta data 9 | ![Aa]ssets/**/*.meta 10 | 11 | # Uncomment this line if you wish to ignore the asset store tools plugin 12 | # [Aa]ssets/AssetStoreTools* 13 | 14 | # Visual Studio cache directory 15 | .vs/ 16 | 17 | # Gradle cache directory 18 | .gradle/ 19 | 20 | 21 | # Autogenerated VS/MD/Consulo solution and project files 22 | ExportedObj/ 23 | .consulo/ 24 | .idea/ 25 | *.csproj 26 | *.unityproj 27 | *.sln 28 | *.suo 29 | *.tmp 30 | *.user 31 | *.userprefs 32 | *.pidb 33 | *.booproj 34 | *.svd 35 | *.pdb 36 | *.mdb 37 | *.opendb 38 | *.VC.db 39 | 40 | # Unity3D generated meta files 41 | *.pidb.meta 42 | *.pdb.meta 43 | *.mdb.meta 44 | 45 | # Unity3D generated file on crash reports 46 | sysinfo.txt 47 | 48 | # Builds 49 | *.apk 50 | *.unitypackage 51 | 52 | # Crashlytics generated file 53 | crashlytics-build.properties 54 | 55 | Assets/Plugins* 56 | Assets/UiRoundedCorners/README.md.meta -------------------------------------------------------------------------------- /Examples.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 8ddeffe740a8df443ad055f860250de7 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /Examples/Lenna.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/Examples/Lenna.png -------------------------------------------------------------------------------- /Examples/Lenna.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 29c435903c4f8404f87a061424329530 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 10 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 0 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | grayScaleToAlpha: 0 27 | generateCubemap: 6 28 | cubemapConvolution: 0 29 | seamlessCubemap: 0 30 | textureFormat: 1 31 | maxTextureSize: 2048 32 | textureSettings: 33 | serializedVersion: 2 34 | filterMode: -1 35 | aniso: -1 36 | mipBias: -100 37 | wrapU: 1 38 | wrapV: 1 39 | wrapW: -1 40 | nPOTScale: 0 41 | lightmap: 0 42 | compressionQuality: 50 43 | spriteMode: 1 44 | spriteExtrude: 1 45 | spriteMeshType: 1 46 | alignment: 0 47 | spritePivot: {x: 0.5, y: 0.5} 48 | spritePixelsToUnits: 100 49 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 50 | spriteGenerateFallbackPhysicsShape: 1 51 | alphaUsage: 1 52 | alphaIsTransparency: 1 53 | spriteTessellationDetail: -1 54 | textureType: 8 55 | textureShape: 1 56 | singleChannelComponent: 0 57 | maxTextureSizeSet: 0 58 | compressionQualitySet: 0 59 | textureFormatSet: 0 60 | platformSettings: 61 | - serializedVersion: 3 62 | buildTarget: DefaultTexturePlatform 63 | maxTextureSize: 2048 64 | resizeAlgorithm: 0 65 | textureFormat: -1 66 | textureCompression: 1 67 | compressionQuality: 50 68 | crunchedCompression: 0 69 | allowsAlphaSplitting: 0 70 | overridden: 0 71 | androidETC2FallbackOverride: 0 72 | forceMaximumCompressionQuality_BC6H_BC7: 1 73 | - serializedVersion: 3 74 | buildTarget: Standalone 75 | maxTextureSize: 2048 76 | resizeAlgorithm: 0 77 | textureFormat: -1 78 | textureCompression: 1 79 | compressionQuality: 50 80 | crunchedCompression: 0 81 | allowsAlphaSplitting: 0 82 | overridden: 0 83 | androidETC2FallbackOverride: 0 84 | forceMaximumCompressionQuality_BC6H_BC7: 1 85 | spriteSheet: 86 | serializedVersion: 2 87 | sprites: [] 88 | outline: [] 89 | physicsShape: [] 90 | bones: [] 91 | spriteID: 5e97eb03825dee720800000000000000 92 | internalID: 0 93 | vertices: [] 94 | indices: 95 | edges: [] 96 | weights: [] 97 | secondaryTextures: [] 98 | spritePackingTag: 99 | pSDRemoveMatte: 0 100 | pSDShowRemoveMatteOption: 0 101 | userData: 102 | assetBundleName: 103 | assetBundleVariant: 104 | -------------------------------------------------------------------------------- /Examples/example.unity: -------------------------------------------------------------------------------- 1 | %YAML 1.1 2 | %TAG !u! tag:unity3d.com,2011: 3 | --- !u!29 &1 4 | OcclusionCullingSettings: 5 | m_ObjectHideFlags: 0 6 | serializedVersion: 2 7 | m_OcclusionBakeSettings: 8 | smallestOccluder: 5 9 | smallestHole: 0.25 10 | backfaceThreshold: 100 11 | m_SceneGUID: 00000000000000000000000000000000 12 | m_OcclusionCullingData: {fileID: 0} 13 | --- !u!104 &2 14 | RenderSettings: 15 | m_ObjectHideFlags: 0 16 | serializedVersion: 9 17 | m_Fog: 0 18 | m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} 19 | m_FogMode: 3 20 | m_FogDensity: 0.01 21 | m_LinearFogStart: 0 22 | m_LinearFogEnd: 300 23 | m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} 24 | m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} 25 | m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} 26 | m_AmbientIntensity: 1 27 | m_AmbientMode: 0 28 | m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1} 29 | m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0} 30 | m_HaloStrength: 0.5 31 | m_FlareStrength: 1 32 | m_FlareFadeSpeed: 3 33 | m_HaloTexture: {fileID: 0} 34 | m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} 35 | m_DefaultReflectionMode: 0 36 | m_DefaultReflectionResolution: 128 37 | m_ReflectionBounces: 1 38 | m_ReflectionIntensity: 1 39 | m_CustomReflection: {fileID: 0} 40 | m_Sun: {fileID: 0} 41 | m_IndirectSpecularColor: {r: 0.37311918, g: 0.3807398, b: 0.35872716, a: 1} 42 | m_UseRadianceAmbientProbe: 0 43 | --- !u!157 &3 44 | LightmapSettings: 45 | m_ObjectHideFlags: 0 46 | serializedVersion: 12 47 | m_GIWorkflowMode: 0 48 | m_GISettings: 49 | serializedVersion: 2 50 | m_BounceScale: 1 51 | m_IndirectOutputScale: 1 52 | m_AlbedoBoost: 1 53 | m_EnvironmentLightingMode: 0 54 | m_EnableBakedLightmaps: 1 55 | m_EnableRealtimeLightmaps: 0 56 | m_LightmapEditorSettings: 57 | serializedVersion: 12 58 | m_Resolution: 2 59 | m_BakeResolution: 10 60 | m_AtlasSize: 512 61 | m_AO: 0 62 | m_AOMaxDistance: 1 63 | m_CompAOExponent: 1 64 | m_CompAOExponentDirect: 0 65 | m_ExtractAmbientOcclusion: 0 66 | m_Padding: 2 67 | m_LightmapParameters: {fileID: 0} 68 | m_LightmapsBakeMode: 1 69 | m_TextureCompression: 1 70 | m_FinalGather: 0 71 | m_FinalGatherFiltering: 1 72 | m_FinalGatherRayCount: 256 73 | m_ReflectionCompression: 2 74 | m_MixedBakeMode: 2 75 | m_BakeBackend: 1 76 | m_PVRSampling: 1 77 | m_PVRDirectSampleCount: 32 78 | m_PVRSampleCount: 256 79 | m_PVRBounces: 2 80 | m_PVREnvironmentSampleCount: 256 81 | m_PVREnvironmentReferencePointCount: 2048 82 | m_PVRFilteringMode: 2 83 | m_PVRDenoiserTypeDirect: 0 84 | m_PVRDenoiserTypeIndirect: 0 85 | m_PVRDenoiserTypeAO: 0 86 | m_PVRFilterTypeDirect: 0 87 | m_PVRFilterTypeIndirect: 0 88 | m_PVRFilterTypeAO: 0 89 | m_PVREnvironmentMIS: 0 90 | m_PVRCulling: 1 91 | m_PVRFilteringGaussRadiusDirect: 1 92 | m_PVRFilteringGaussRadiusIndirect: 5 93 | m_PVRFilteringGaussRadiusAO: 2 94 | m_PVRFilteringAtrousPositionSigmaDirect: 0.5 95 | m_PVRFilteringAtrousPositionSigmaIndirect: 2 96 | m_PVRFilteringAtrousPositionSigmaAO: 1 97 | m_ExportTrainingData: 0 98 | m_TrainingDataDestination: TrainingData 99 | m_LightProbeSampleCountMultiplier: 4 100 | m_LightingDataAsset: {fileID: 0} 101 | m_LightingSettings: {fileID: 4890085278179872738, guid: c75ca4833966edf4fa587a2891dba83b, 102 | type: 2} 103 | --- !u!196 &4 104 | NavMeshSettings: 105 | serializedVersion: 2 106 | m_ObjectHideFlags: 0 107 | m_BuildSettings: 108 | serializedVersion: 2 109 | agentTypeID: 0 110 | agentRadius: 0.5 111 | agentHeight: 2 112 | agentSlope: 45 113 | agentClimb: 0.4 114 | ledgeDropHeight: 0 115 | maxJumpAcrossDistance: 0 116 | minRegionArea: 2 117 | manualCellSize: 0 118 | cellSize: 0.16666667 119 | manualTileSize: 0 120 | tileSize: 256 121 | accuratePlacement: 0 122 | maxJobWorkers: 0 123 | preserveTilesOutsideBounds: 0 124 | debug: 125 | m_Flags: 0 126 | m_NavMeshData: {fileID: 0} 127 | --- !u!1 &314398715 128 | GameObject: 129 | m_ObjectHideFlags: 0 130 | m_CorrespondingSourceObject: {fileID: 0} 131 | m_PrefabInstance: {fileID: 0} 132 | m_PrefabAsset: {fileID: 0} 133 | serializedVersion: 6 134 | m_Component: 135 | - component: {fileID: 314398719} 136 | - component: {fileID: 314398718} 137 | - component: {fileID: 314398717} 138 | - component: {fileID: 314398716} 139 | m_Layer: 5 140 | m_Name: Canvas 141 | m_TagString: Untagged 142 | m_Icon: {fileID: 0} 143 | m_NavMeshLayer: 0 144 | m_StaticEditorFlags: 0 145 | m_IsActive: 1 146 | --- !u!114 &314398716 147 | MonoBehaviour: 148 | m_ObjectHideFlags: 0 149 | m_CorrespondingSourceObject: {fileID: 0} 150 | m_PrefabInstance: {fileID: 0} 151 | m_PrefabAsset: {fileID: 0} 152 | m_GameObject: {fileID: 314398715} 153 | m_Enabled: 1 154 | m_EditorHideFlags: 0 155 | m_Script: {fileID: 11500000, guid: dc42784cf147c0c48a680349fa168899, type: 3} 156 | m_Name: 157 | m_EditorClassIdentifier: 158 | m_IgnoreReversedGraphics: 1 159 | m_BlockingObjects: 0 160 | m_BlockingMask: 161 | serializedVersion: 2 162 | m_Bits: 16183 163 | --- !u!114 &314398717 164 | MonoBehaviour: 165 | m_ObjectHideFlags: 0 166 | m_CorrespondingSourceObject: {fileID: 0} 167 | m_PrefabInstance: {fileID: 0} 168 | m_PrefabAsset: {fileID: 0} 169 | m_GameObject: {fileID: 314398715} 170 | m_Enabled: 1 171 | m_EditorHideFlags: 0 172 | m_Script: {fileID: 11500000, guid: 0cd44c1031e13a943bb63640046fad76, type: 3} 173 | m_Name: 174 | m_EditorClassIdentifier: 175 | m_UiScaleMode: 0 176 | m_ReferencePixelsPerUnit: 100 177 | m_ScaleFactor: 1 178 | m_ReferenceResolution: {x: 800, y: 600} 179 | m_ScreenMatchMode: 0 180 | m_MatchWidthOrHeight: 0 181 | m_PhysicalUnit: 3 182 | m_FallbackScreenDPI: 96 183 | m_DefaultSpriteDPI: 96 184 | m_DynamicPixelsPerUnit: 1 185 | m_PresetInfoIsWorld: 1 186 | --- !u!223 &314398718 187 | Canvas: 188 | m_ObjectHideFlags: 0 189 | m_CorrespondingSourceObject: {fileID: 0} 190 | m_PrefabInstance: {fileID: 0} 191 | m_PrefabAsset: {fileID: 0} 192 | m_GameObject: {fileID: 314398715} 193 | m_Enabled: 1 194 | serializedVersion: 3 195 | m_RenderMode: 2 196 | m_Camera: {fileID: 1562695331} 197 | m_PlaneDistance: 100 198 | m_PixelPerfect: 0 199 | m_ReceivesEvents: 1 200 | m_OverrideSorting: 0 201 | m_OverridePixelPerfect: 0 202 | m_SortingBucketNormalizedSize: 0 203 | m_AdditionalShaderChannelsFlag: 0 204 | m_SortingLayerID: 0 205 | m_SortingOrder: 0 206 | m_TargetDisplay: 0 207 | --- !u!224 &314398719 208 | RectTransform: 209 | m_ObjectHideFlags: 0 210 | m_CorrespondingSourceObject: {fileID: 0} 211 | m_PrefabInstance: {fileID: 0} 212 | m_PrefabAsset: {fileID: 0} 213 | m_GameObject: {fileID: 314398715} 214 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 215 | m_LocalPosition: {x: 0, y: 0, z: 0} 216 | m_LocalScale: {x: 1, y: 1, z: 1} 217 | m_Children: 218 | - {fileID: 1293534749} 219 | - {fileID: 787497678} 220 | - {fileID: 1695272625} 221 | - {fileID: 418354422} 222 | m_Father: {fileID: 0} 223 | m_RootOrder: 0 224 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 225 | m_AnchorMin: {x: 0, y: 0} 226 | m_AnchorMax: {x: 0, y: 0} 227 | m_AnchoredPosition: {x: 0, y: 0} 228 | m_SizeDelta: {x: 500, y: 300} 229 | m_Pivot: {x: 0.5, y: 0.5} 230 | --- !u!1 &418354421 231 | GameObject: 232 | m_ObjectHideFlags: 0 233 | m_CorrespondingSourceObject: {fileID: 0} 234 | m_PrefabInstance: {fileID: 0} 235 | m_PrefabAsset: {fileID: 0} 236 | serializedVersion: 6 237 | m_Component: 238 | - component: {fileID: 418354422} 239 | - component: {fileID: 418354425} 240 | - component: {fileID: 418354424} 241 | - component: {fileID: 418354423} 242 | m_Layer: 5 243 | m_Name: Image 244 | m_TagString: Untagged 245 | m_Icon: {fileID: 0} 246 | m_NavMeshLayer: 0 247 | m_StaticEditorFlags: 0 248 | m_IsActive: 1 249 | --- !u!224 &418354422 250 | RectTransform: 251 | m_ObjectHideFlags: 0 252 | m_CorrespondingSourceObject: {fileID: 0} 253 | m_PrefabInstance: {fileID: 0} 254 | m_PrefabAsset: {fileID: 0} 255 | m_GameObject: {fileID: 418354421} 256 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 257 | m_LocalPosition: {x: 0, y: 0, z: 0} 258 | m_LocalScale: {x: 1, y: 1, z: 1} 259 | m_Children: 260 | - {fileID: 1697298825} 261 | m_Father: {fileID: 314398719} 262 | m_RootOrder: 3 263 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 264 | m_AnchorMin: {x: 0.5, y: 0.5} 265 | m_AnchorMax: {x: 0.5, y: 0.5} 266 | m_AnchoredPosition: {x: 88.7, y: 78.5} 267 | m_SizeDelta: {x: 100, y: 100} 268 | m_Pivot: {x: 0.5, y: 0.5} 269 | --- !u!114 &418354423 270 | MonoBehaviour: 271 | m_ObjectHideFlags: 0 272 | m_CorrespondingSourceObject: {fileID: 0} 273 | m_PrefabInstance: {fileID: 0} 274 | m_PrefabAsset: {fileID: 0} 275 | m_GameObject: {fileID: 418354421} 276 | m_Enabled: 1 277 | m_EditorHideFlags: 0 278 | m_Script: {fileID: 11500000, guid: 31a19414c41e5ae4aae2af33fee712f6, type: 3} 279 | m_Name: 280 | m_EditorClassIdentifier: 281 | m_ShowMaskGraphic: 1 282 | --- !u!114 &418354424 283 | MonoBehaviour: 284 | m_ObjectHideFlags: 0 285 | m_CorrespondingSourceObject: {fileID: 0} 286 | m_PrefabInstance: {fileID: 0} 287 | m_PrefabAsset: {fileID: 0} 288 | m_GameObject: {fileID: 418354421} 289 | m_Enabled: 1 290 | m_EditorHideFlags: 0 291 | m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} 292 | m_Name: 293 | m_EditorClassIdentifier: 294 | m_Material: {fileID: 0} 295 | m_Color: {r: 1, g: 1, b: 1, a: 1} 296 | m_RaycastTarget: 1 297 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 298 | m_Maskable: 1 299 | m_OnCullStateChanged: 300 | m_PersistentCalls: 301 | m_Calls: [] 302 | m_Sprite: {fileID: 0} 303 | m_Type: 0 304 | m_PreserveAspect: 0 305 | m_FillCenter: 1 306 | m_FillMethod: 4 307 | m_FillAmount: 1 308 | m_FillClockwise: 1 309 | m_FillOrigin: 0 310 | m_UseSpriteMesh: 0 311 | m_PixelsPerUnitMultiplier: 1 312 | --- !u!222 &418354425 313 | CanvasRenderer: 314 | m_ObjectHideFlags: 0 315 | m_CorrespondingSourceObject: {fileID: 0} 316 | m_PrefabInstance: {fileID: 0} 317 | m_PrefabAsset: {fileID: 0} 318 | m_GameObject: {fileID: 418354421} 319 | m_CullTransparentMesh: 0 320 | --- !u!21 &783075183 321 | Material: 322 | serializedVersion: 6 323 | m_ObjectHideFlags: 0 324 | m_CorrespondingSourceObject: {fileID: 0} 325 | m_PrefabInstance: {fileID: 0} 326 | m_PrefabAsset: {fileID: 0} 327 | m_Name: UI/RoundedCorners/RoundedCorners 328 | m_Shader: {fileID: 4800000, guid: 0bd2ec5d73751e34a814274a454bec41, type: 3} 329 | m_ShaderKeywords: 330 | m_LightmapFlags: 4 331 | m_EnableInstancingVariants: 0 332 | m_DoubleSidedGI: 0 333 | m_CustomRenderQueue: -1 334 | stringTagMap: {} 335 | disabledShaderPasses: [] 336 | m_SavedProperties: 337 | serializedVersion: 3 338 | m_TexEnvs: 339 | - _MainTex: 340 | m_Texture: {fileID: 0} 341 | m_Scale: {x: 1, y: 1} 342 | m_Offset: {x: 0, y: 0} 343 | m_Floats: 344 | - _ColorMask: 15 345 | - _Stencil: 0 346 | - _StencilComp: 8 347 | - _StencilOp: 0 348 | - _StencilReadMask: 255 349 | - _StencilWriteMask: 255 350 | - _UseUIAlphaClip: 0 351 | m_Colors: 352 | - _WidthHeightRadius: {r: 159, g: 29, b: 7.39, a: 0} 353 | m_BuildTextureStacks: [] 354 | --- !u!1 &787497677 355 | GameObject: 356 | m_ObjectHideFlags: 0 357 | m_CorrespondingSourceObject: {fileID: 0} 358 | m_PrefabInstance: {fileID: 0} 359 | m_PrefabAsset: {fileID: 0} 360 | serializedVersion: 6 361 | m_Component: 362 | - component: {fileID: 787497678} 363 | - component: {fileID: 787497680} 364 | - component: {fileID: 787497679} 365 | - component: {fileID: 787497681} 366 | m_Layer: 5 367 | m_Name: Lenna 368 | m_TagString: Untagged 369 | m_Icon: {fileID: 0} 370 | m_NavMeshLayer: 0 371 | m_StaticEditorFlags: 0 372 | m_IsActive: 1 373 | --- !u!224 &787497678 374 | RectTransform: 375 | m_ObjectHideFlags: 0 376 | m_CorrespondingSourceObject: {fileID: 0} 377 | m_PrefabInstance: {fileID: 0} 378 | m_PrefabAsset: {fileID: 0} 379 | m_GameObject: {fileID: 787497677} 380 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 381 | m_LocalPosition: {x: 0, y: 0, z: 0} 382 | m_LocalScale: {x: 1, y: 1, z: 1} 383 | m_Children: [] 384 | m_Father: {fileID: 314398719} 385 | m_RootOrder: 1 386 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 387 | m_AnchorMin: {x: 0.5, y: 0.5} 388 | m_AnchorMax: {x: 0.5, y: 0.5} 389 | m_AnchoredPosition: {x: -89.9, y: -23.1} 390 | m_SizeDelta: {x: 100, y: 100} 391 | m_Pivot: {x: 0.5, y: 0.5} 392 | --- !u!114 &787497679 393 | MonoBehaviour: 394 | m_ObjectHideFlags: 0 395 | m_CorrespondingSourceObject: {fileID: 0} 396 | m_PrefabInstance: {fileID: 0} 397 | m_PrefabAsset: {fileID: 0} 398 | m_GameObject: {fileID: 787497677} 399 | m_Enabled: 1 400 | m_EditorHideFlags: 0 401 | m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} 402 | m_Name: 403 | m_EditorClassIdentifier: 404 | m_Material: {fileID: 826410013} 405 | m_Color: {r: 1, g: 1, b: 1, a: 1} 406 | m_RaycastTarget: 1 407 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 408 | m_Maskable: 1 409 | m_OnCullStateChanged: 410 | m_PersistentCalls: 411 | m_Calls: [] 412 | m_Sprite: {fileID: 21300000, guid: 29c435903c4f8404f87a061424329530, type: 3} 413 | m_Type: 0 414 | m_PreserveAspect: 0 415 | m_FillCenter: 1 416 | m_FillMethod: 4 417 | m_FillAmount: 1 418 | m_FillClockwise: 1 419 | m_FillOrigin: 0 420 | m_UseSpriteMesh: 0 421 | m_PixelsPerUnitMultiplier: 1 422 | --- !u!222 &787497680 423 | CanvasRenderer: 424 | m_ObjectHideFlags: 0 425 | m_CorrespondingSourceObject: {fileID: 0} 426 | m_PrefabInstance: {fileID: 0} 427 | m_PrefabAsset: {fileID: 0} 428 | m_GameObject: {fileID: 787497677} 429 | m_CullTransparentMesh: 0 430 | --- !u!114 &787497681 431 | MonoBehaviour: 432 | m_ObjectHideFlags: 0 433 | m_CorrespondingSourceObject: {fileID: 0} 434 | m_PrefabInstance: {fileID: 0} 435 | m_PrefabAsset: {fileID: 0} 436 | m_GameObject: {fileID: 787497677} 437 | m_Enabled: 1 438 | m_EditorHideFlags: 0 439 | m_Script: {fileID: 11500000, guid: adb30198aa32dd140b5750692dd48104, type: 3} 440 | m_Name: 441 | m_EditorClassIdentifier: 442 | radius: 60 443 | image: {fileID: 787497679} 444 | --- !u!1 &803685409 445 | GameObject: 446 | m_ObjectHideFlags: 0 447 | m_CorrespondingSourceObject: {fileID: 0} 448 | m_PrefabInstance: {fileID: 0} 449 | m_PrefabAsset: {fileID: 0} 450 | serializedVersion: 6 451 | m_Component: 452 | - component: {fileID: 803685410} 453 | - component: {fileID: 803685412} 454 | - component: {fileID: 803685413} 455 | - component: {fileID: 803685411} 456 | m_Layer: 5 457 | m_Name: Foreground 458 | m_TagString: Untagged 459 | m_Icon: {fileID: 0} 460 | m_NavMeshLayer: 0 461 | m_StaticEditorFlags: 0 462 | m_IsActive: 1 463 | --- !u!224 &803685410 464 | RectTransform: 465 | m_ObjectHideFlags: 0 466 | m_CorrespondingSourceObject: {fileID: 0} 467 | m_PrefabInstance: {fileID: 0} 468 | m_PrefabAsset: {fileID: 0} 469 | m_GameObject: {fileID: 803685409} 470 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 471 | m_LocalPosition: {x: 0, y: 0, z: 0} 472 | m_LocalScale: {x: 1, y: 1, z: 1} 473 | m_Children: [] 474 | m_Father: {fileID: 1293534749} 475 | m_RootOrder: 0 476 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 477 | m_AnchorMin: {x: 0, y: 0} 478 | m_AnchorMax: {x: 1, y: 1} 479 | m_AnchoredPosition: {x: 0, y: 0} 480 | m_SizeDelta: {x: -1, y: -1} 481 | m_Pivot: {x: 0.5, y: 0.5} 482 | --- !u!114 &803685411 483 | MonoBehaviour: 484 | m_ObjectHideFlags: 0 485 | m_CorrespondingSourceObject: {fileID: 0} 486 | m_PrefabInstance: {fileID: 0} 487 | m_PrefabAsset: {fileID: 0} 488 | m_GameObject: {fileID: 803685409} 489 | m_Enabled: 1 490 | m_EditorHideFlags: 0 491 | m_Script: {fileID: 11500000, guid: adb30198aa32dd140b5750692dd48104, type: 3} 492 | m_Name: 493 | m_EditorClassIdentifier: 494 | radius: 7.39 495 | image: {fileID: 803685413} 496 | --- !u!222 &803685412 497 | CanvasRenderer: 498 | m_ObjectHideFlags: 0 499 | m_CorrespondingSourceObject: {fileID: 0} 500 | m_PrefabInstance: {fileID: 0} 501 | m_PrefabAsset: {fileID: 0} 502 | m_GameObject: {fileID: 803685409} 503 | m_CullTransparentMesh: 0 504 | --- !u!114 &803685413 505 | MonoBehaviour: 506 | m_ObjectHideFlags: 0 507 | m_CorrespondingSourceObject: {fileID: 0} 508 | m_PrefabInstance: {fileID: 0} 509 | m_PrefabAsset: {fileID: 0} 510 | m_GameObject: {fileID: 803685409} 511 | m_Enabled: 1 512 | m_EditorHideFlags: 0 513 | m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} 514 | m_Name: 515 | m_EditorClassIdentifier: 516 | m_Material: {fileID: 783075183} 517 | m_Color: {r: 1, g: 1, b: 1, a: 1} 518 | m_RaycastTarget: 1 519 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 520 | m_Maskable: 1 521 | m_OnCullStateChanged: 522 | m_PersistentCalls: 523 | m_Calls: [] 524 | m_Sprite: {fileID: 0} 525 | m_Type: 0 526 | m_PreserveAspect: 0 527 | m_FillCenter: 1 528 | m_FillMethod: 4 529 | m_FillAmount: 1 530 | m_FillClockwise: 1 531 | m_FillOrigin: 0 532 | m_UseSpriteMesh: 0 533 | m_PixelsPerUnitMultiplier: 1 534 | --- !u!21 &826410013 535 | Material: 536 | serializedVersion: 6 537 | m_ObjectHideFlags: 0 538 | m_CorrespondingSourceObject: {fileID: 0} 539 | m_PrefabInstance: {fileID: 0} 540 | m_PrefabAsset: {fileID: 0} 541 | m_Name: UI/RoundedCorners/RoundedCorners 542 | m_Shader: {fileID: 4800000, guid: 0bd2ec5d73751e34a814274a454bec41, type: 3} 543 | m_ShaderKeywords: 544 | m_LightmapFlags: 4 545 | m_EnableInstancingVariants: 0 546 | m_DoubleSidedGI: 0 547 | m_CustomRenderQueue: -1 548 | stringTagMap: {} 549 | disabledShaderPasses: [] 550 | m_SavedProperties: 551 | serializedVersion: 3 552 | m_TexEnvs: 553 | - _MainTex: 554 | m_Texture: {fileID: 0} 555 | m_Scale: {x: 1, y: 1} 556 | m_Offset: {x: 0, y: 0} 557 | m_Floats: 558 | - _ColorMask: 15 559 | - _Stencil: 0 560 | - _StencilComp: 8 561 | - _StencilOp: 0 562 | - _StencilReadMask: 255 563 | - _StencilWriteMask: 255 564 | - _UseUIAlphaClip: 0 565 | m_Colors: 566 | - _WidthHeightRadius: {r: 100, g: 100, b: 60, a: 0} 567 | m_BuildTextureStacks: [] 568 | --- !u!1 &921931709 569 | GameObject: 570 | m_ObjectHideFlags: 0 571 | m_CorrespondingSourceObject: {fileID: 0} 572 | m_PrefabInstance: {fileID: 0} 573 | m_PrefabAsset: {fileID: 0} 574 | serializedVersion: 6 575 | m_Component: 576 | - component: {fileID: 921931710} 577 | - component: {fileID: 921931712} 578 | - component: {fileID: 921931711} 579 | m_Layer: 5 580 | m_Name: Text 581 | m_TagString: Untagged 582 | m_Icon: {fileID: 0} 583 | m_NavMeshLayer: 0 584 | m_StaticEditorFlags: 0 585 | m_IsActive: 1 586 | --- !u!224 &921931710 587 | RectTransform: 588 | m_ObjectHideFlags: 0 589 | m_CorrespondingSourceObject: {fileID: 0} 590 | m_PrefabInstance: {fileID: 0} 591 | m_PrefabAsset: {fileID: 0} 592 | m_GameObject: {fileID: 921931709} 593 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 594 | m_LocalPosition: {x: 0, y: 0, z: 0} 595 | m_LocalScale: {x: 1, y: 1, z: 1} 596 | m_Children: [] 597 | m_Father: {fileID: 1293534749} 598 | m_RootOrder: 1 599 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 600 | m_AnchorMin: {x: 0.5, y: 0.5} 601 | m_AnchorMax: {x: 0.5, y: 0.5} 602 | m_AnchoredPosition: {x: 0, y: 0} 603 | m_SizeDelta: {x: 160, y: 30} 604 | m_Pivot: {x: 0.5, y: 0.5} 605 | --- !u!114 &921931711 606 | MonoBehaviour: 607 | m_ObjectHideFlags: 0 608 | m_CorrespondingSourceObject: {fileID: 0} 609 | m_PrefabInstance: {fileID: 0} 610 | m_PrefabAsset: {fileID: 0} 611 | m_GameObject: {fileID: 921931709} 612 | m_Enabled: 1 613 | m_EditorHideFlags: 0 614 | m_Script: {fileID: 11500000, guid: 5f7201a12d95ffc409449d95f23cf332, type: 3} 615 | m_Name: 616 | m_EditorClassIdentifier: 617 | m_Material: {fileID: 0} 618 | m_Color: {r: 0.19607843, g: 0.19607843, b: 0.19607843, a: 1} 619 | m_RaycastTarget: 1 620 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 621 | m_Maskable: 1 622 | m_OnCullStateChanged: 623 | m_PersistentCalls: 624 | m_Calls: [] 625 | m_FontData: 626 | m_Font: {fileID: 10102, guid: 0000000000000000e000000000000000, type: 0} 627 | m_FontSize: 14 628 | m_FontStyle: 0 629 | m_BestFit: 0 630 | m_MinSize: 10 631 | m_MaxSize: 40 632 | m_Alignment: 4 633 | m_AlignByGeometry: 0 634 | m_RichText: 1 635 | m_HorizontalOverflow: 0 636 | m_VerticalOverflow: 0 637 | m_LineSpacing: 1 638 | m_Text: Button 639 | --- !u!222 &921931712 640 | CanvasRenderer: 641 | m_ObjectHideFlags: 0 642 | m_CorrespondingSourceObject: {fileID: 0} 643 | m_PrefabInstance: {fileID: 0} 644 | m_PrefabAsset: {fileID: 0} 645 | m_GameObject: {fileID: 921931709} 646 | m_CullTransparentMesh: 0 647 | --- !u!21 &1262233990 648 | Material: 649 | serializedVersion: 6 650 | m_ObjectHideFlags: 0 651 | m_CorrespondingSourceObject: {fileID: 0} 652 | m_PrefabInstance: {fileID: 0} 653 | m_PrefabAsset: {fileID: 0} 654 | m_Name: UI/RoundedCorners/RoundedCorners 655 | m_Shader: {fileID: 4800000, guid: 0bd2ec5d73751e34a814274a454bec41, type: 3} 656 | m_ShaderKeywords: 657 | m_LightmapFlags: 4 658 | m_EnableInstancingVariants: 0 659 | m_DoubleSidedGI: 0 660 | m_CustomRenderQueue: -1 661 | stringTagMap: {} 662 | disabledShaderPasses: [] 663 | m_SavedProperties: 664 | serializedVersion: 3 665 | m_TexEnvs: 666 | - _MainTex: 667 | m_Texture: {fileID: 0} 668 | m_Scale: {x: 1, y: 1} 669 | m_Offset: {x: 0, y: 0} 670 | m_Floats: 671 | - _ColorMask: 15 672 | - _Stencil: 0 673 | - _StencilComp: 8 674 | - _StencilOp: 0 675 | - _StencilReadMask: 255 676 | - _StencilWriteMask: 255 677 | - _UseUIAlphaClip: 0 678 | m_Colors: 679 | - _WidthHeightRadius: {r: 100, g: 100, b: 16, a: 0} 680 | m_BuildTextureStacks: [] 681 | --- !u!1 &1293534748 682 | GameObject: 683 | m_ObjectHideFlags: 0 684 | m_CorrespondingSourceObject: {fileID: 0} 685 | m_PrefabInstance: {fileID: 0} 686 | m_PrefabAsset: {fileID: 0} 687 | serializedVersion: 6 688 | m_Component: 689 | - component: {fileID: 1293534749} 690 | - component: {fileID: 1293534752} 691 | - component: {fileID: 1293534753} 692 | - component: {fileID: 1293534750} 693 | - component: {fileID: 1293534751} 694 | m_Layer: 5 695 | m_Name: Button 696 | m_TagString: Untagged 697 | m_Icon: {fileID: 0} 698 | m_NavMeshLayer: 0 699 | m_StaticEditorFlags: 0 700 | m_IsActive: 1 701 | --- !u!224 &1293534749 702 | RectTransform: 703 | m_ObjectHideFlags: 0 704 | m_CorrespondingSourceObject: {fileID: 0} 705 | m_PrefabInstance: {fileID: 0} 706 | m_PrefabAsset: {fileID: 0} 707 | m_GameObject: {fileID: 1293534748} 708 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 709 | m_LocalPosition: {x: 0, y: 0, z: 0} 710 | m_LocalScale: {x: 1, y: 1, z: 1} 711 | m_Children: 712 | - {fileID: 803685410} 713 | - {fileID: 921931710} 714 | m_Father: {fileID: 314398719} 715 | m_RootOrder: 0 716 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 717 | m_AnchorMin: {x: 0, y: 1} 718 | m_AnchorMax: {x: 0, y: 1} 719 | m_AnchoredPosition: {x: 94, y: -45} 720 | m_SizeDelta: {x: 160, y: 30} 721 | m_Pivot: {x: 0.5, y: 0.5} 722 | --- !u!114 &1293534750 723 | MonoBehaviour: 724 | m_ObjectHideFlags: 0 725 | m_CorrespondingSourceObject: {fileID: 0} 726 | m_PrefabInstance: {fileID: 0} 727 | m_PrefabAsset: {fileID: 0} 728 | m_GameObject: {fileID: 1293534748} 729 | m_Enabled: 1 730 | m_EditorHideFlags: 0 731 | m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3} 732 | m_Name: 733 | m_EditorClassIdentifier: 734 | m_Navigation: 735 | m_Mode: 3 736 | m_WrapAround: 0 737 | m_SelectOnUp: {fileID: 0} 738 | m_SelectOnDown: {fileID: 0} 739 | m_SelectOnLeft: {fileID: 0} 740 | m_SelectOnRight: {fileID: 0} 741 | m_Transition: 1 742 | m_Colors: 743 | m_NormalColor: {r: 0.7924528, g: 0.12335351, b: 0.45167083, a: 1} 744 | m_HighlightedColor: {r: 0, g: 0.9811321, b: 0.84751457, a: 1} 745 | m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1} 746 | m_SelectedColor: {r: 0, g: 0.9811321, b: 0.84751457, a: 1} 747 | m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608} 748 | m_ColorMultiplier: 1 749 | m_FadeDuration: 0.1 750 | m_SpriteState: 751 | m_HighlightedSprite: {fileID: 0} 752 | m_PressedSprite: {fileID: 0} 753 | m_SelectedSprite: {fileID: 0} 754 | m_DisabledSprite: {fileID: 0} 755 | m_AnimationTriggers: 756 | m_NormalTrigger: Normal 757 | m_HighlightedTrigger: Highlighted 758 | m_PressedTrigger: Pressed 759 | m_SelectedTrigger: Highlighted 760 | m_DisabledTrigger: Disabled 761 | m_Interactable: 1 762 | m_TargetGraphic: {fileID: 803685413} 763 | m_OnClick: 764 | m_PersistentCalls: 765 | m_Calls: [] 766 | --- !u!114 &1293534751 767 | MonoBehaviour: 768 | m_ObjectHideFlags: 0 769 | m_CorrespondingSourceObject: {fileID: 0} 770 | m_PrefabInstance: {fileID: 0} 771 | m_PrefabAsset: {fileID: 0} 772 | m_GameObject: {fileID: 1293534748} 773 | m_Enabled: 1 774 | m_EditorHideFlags: 0 775 | m_Script: {fileID: 11500000, guid: adb30198aa32dd140b5750692dd48104, type: 3} 776 | m_Name: 777 | m_EditorClassIdentifier: 778 | radius: 8 779 | image: {fileID: 1293534753} 780 | --- !u!222 &1293534752 781 | CanvasRenderer: 782 | m_ObjectHideFlags: 0 783 | m_CorrespondingSourceObject: {fileID: 0} 784 | m_PrefabInstance: {fileID: 0} 785 | m_PrefabAsset: {fileID: 0} 786 | m_GameObject: {fileID: 1293534748} 787 | m_CullTransparentMesh: 0 788 | --- !u!114 &1293534753 789 | MonoBehaviour: 790 | m_ObjectHideFlags: 0 791 | m_CorrespondingSourceObject: {fileID: 0} 792 | m_PrefabInstance: {fileID: 0} 793 | m_PrefabAsset: {fileID: 0} 794 | m_GameObject: {fileID: 1293534748} 795 | m_Enabled: 1 796 | m_EditorHideFlags: 0 797 | m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} 798 | m_Name: 799 | m_EditorClassIdentifier: 800 | m_Material: {fileID: 1465408271} 801 | m_Color: {r: 0, g: 0, b: 0, a: 1} 802 | m_RaycastTarget: 0 803 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 804 | m_Maskable: 1 805 | m_OnCullStateChanged: 806 | m_PersistentCalls: 807 | m_Calls: [] 808 | m_Sprite: {fileID: 0} 809 | m_Type: 0 810 | m_PreserveAspect: 0 811 | m_FillCenter: 1 812 | m_FillMethod: 4 813 | m_FillAmount: 1 814 | m_FillClockwise: 1 815 | m_FillOrigin: 0 816 | m_UseSpriteMesh: 0 817 | m_PixelsPerUnitMultiplier: 1 818 | --- !u!21 &1465408271 819 | Material: 820 | serializedVersion: 6 821 | m_ObjectHideFlags: 0 822 | m_CorrespondingSourceObject: {fileID: 0} 823 | m_PrefabInstance: {fileID: 0} 824 | m_PrefabAsset: {fileID: 0} 825 | m_Name: UI/RoundedCorners/RoundedCorners 826 | m_Shader: {fileID: 4800000, guid: 0bd2ec5d73751e34a814274a454bec41, type: 3} 827 | m_ShaderKeywords: 828 | m_LightmapFlags: 4 829 | m_EnableInstancingVariants: 0 830 | m_DoubleSidedGI: 0 831 | m_CustomRenderQueue: -1 832 | stringTagMap: {} 833 | disabledShaderPasses: [] 834 | m_SavedProperties: 835 | serializedVersion: 3 836 | m_TexEnvs: 837 | - _MainTex: 838 | m_Texture: {fileID: 0} 839 | m_Scale: {x: 1, y: 1} 840 | m_Offset: {x: 0, y: 0} 841 | m_Floats: 842 | - _ColorMask: 15 843 | - _Stencil: 0 844 | - _StencilComp: 8 845 | - _StencilOp: 0 846 | - _StencilReadMask: 255 847 | - _StencilWriteMask: 255 848 | - _UseUIAlphaClip: 0 849 | m_Colors: 850 | - _WidthHeightRadius: {r: 160, g: 30, b: 8, a: 0} 851 | m_BuildTextureStacks: [] 852 | --- !u!1 &1562695329 853 | GameObject: 854 | m_ObjectHideFlags: 0 855 | m_CorrespondingSourceObject: {fileID: 0} 856 | m_PrefabInstance: {fileID: 0} 857 | m_PrefabAsset: {fileID: 0} 858 | serializedVersion: 6 859 | m_Component: 860 | - component: {fileID: 1562695332} 861 | - component: {fileID: 1562695331} 862 | - component: {fileID: 1562695330} 863 | m_Layer: 0 864 | m_Name: Camera 865 | m_TagString: Untagged 866 | m_Icon: {fileID: 0} 867 | m_NavMeshLayer: 0 868 | m_StaticEditorFlags: 0 869 | m_IsActive: 1 870 | --- !u!81 &1562695330 871 | AudioListener: 872 | m_ObjectHideFlags: 0 873 | m_CorrespondingSourceObject: {fileID: 0} 874 | m_PrefabInstance: {fileID: 0} 875 | m_PrefabAsset: {fileID: 0} 876 | m_GameObject: {fileID: 1562695329} 877 | m_Enabled: 1 878 | --- !u!20 &1562695331 879 | Camera: 880 | m_ObjectHideFlags: 0 881 | m_CorrespondingSourceObject: {fileID: 0} 882 | m_PrefabInstance: {fileID: 0} 883 | m_PrefabAsset: {fileID: 0} 884 | m_GameObject: {fileID: 1562695329} 885 | m_Enabled: 1 886 | serializedVersion: 2 887 | m_ClearFlags: 2 888 | m_BackGroundColor: {r: 0.2784314, g: 0.2784314, b: 0.2784314, a: 1} 889 | m_projectionMatrixMode: 1 890 | m_GateFitMode: 2 891 | m_FOVAxisMode: 0 892 | m_SensorSize: {x: 36, y: 24} 893 | m_LensShift: {x: 0, y: 0} 894 | m_FocalLength: 50 895 | m_NormalizedViewPortRect: 896 | serializedVersion: 2 897 | x: 0 898 | y: 0 899 | width: 1 900 | height: 1 901 | near clip plane: 0.3 902 | far clip plane: 1000 903 | field of view: 60 904 | orthographic: 0 905 | orthographic size: 5 906 | m_Depth: 0 907 | m_CullingMask: 908 | serializedVersion: 2 909 | m_Bits: 4294967295 910 | m_RenderingPath: -1 911 | m_TargetTexture: {fileID: 0} 912 | m_TargetDisplay: 0 913 | m_TargetEye: 3 914 | m_HDR: 1 915 | m_AllowMSAA: 1 916 | m_AllowDynamicResolution: 0 917 | m_ForceIntoRT: 0 918 | m_OcclusionCulling: 1 919 | m_StereoConvergence: 10 920 | m_StereoSeparation: 0.022 921 | --- !u!4 &1562695332 922 | Transform: 923 | m_ObjectHideFlags: 0 924 | m_CorrespondingSourceObject: {fileID: 0} 925 | m_PrefabInstance: {fileID: 0} 926 | m_PrefabAsset: {fileID: 0} 927 | m_GameObject: {fileID: 1562695329} 928 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 929 | m_LocalPosition: {x: 0, y: 0, z: -369} 930 | m_LocalScale: {x: 1, y: 1, z: 1} 931 | m_Children: [] 932 | m_Father: {fileID: 0} 933 | m_RootOrder: 1 934 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 935 | --- !u!1 &1695272624 936 | GameObject: 937 | m_ObjectHideFlags: 0 938 | m_CorrespondingSourceObject: {fileID: 0} 939 | m_PrefabInstance: {fileID: 0} 940 | m_PrefabAsset: {fileID: 0} 941 | serializedVersion: 6 942 | m_Component: 943 | - component: {fileID: 1695272625} 944 | - component: {fileID: 1695272628} 945 | - component: {fileID: 1695272627} 946 | - component: {fileID: 1695272626} 947 | m_Layer: 5 948 | m_Name: Lenna Independent Corners 949 | m_TagString: Untagged 950 | m_Icon: {fileID: 0} 951 | m_NavMeshLayer: 0 952 | m_StaticEditorFlags: 0 953 | m_IsActive: 1 954 | --- !u!224 &1695272625 955 | RectTransform: 956 | m_ObjectHideFlags: 0 957 | m_CorrespondingSourceObject: {fileID: 0} 958 | m_PrefabInstance: {fileID: 0} 959 | m_PrefabAsset: {fileID: 0} 960 | m_GameObject: {fileID: 1695272624} 961 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 962 | m_LocalPosition: {x: 0, y: 0, z: 0} 963 | m_LocalScale: {x: 1, y: 1, z: 1} 964 | m_Children: [] 965 | m_Father: {fileID: 314398719} 966 | m_RootOrder: 2 967 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 968 | m_AnchorMin: {x: 0.5, y: 0.5} 969 | m_AnchorMax: {x: 0.5, y: 0.5} 970 | m_AnchoredPosition: {x: 97.1, y: -44.1} 971 | m_SizeDelta: {x: 100, y: 100} 972 | m_Pivot: {x: 0.5, y: 0.5} 973 | --- !u!114 &1695272626 974 | MonoBehaviour: 975 | m_ObjectHideFlags: 0 976 | m_CorrespondingSourceObject: {fileID: 0} 977 | m_PrefabInstance: {fileID: 0} 978 | m_PrefabAsset: {fileID: 0} 979 | m_GameObject: {fileID: 1695272624} 980 | m_Enabled: 1 981 | m_EditorHideFlags: 0 982 | m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} 983 | m_Name: 984 | m_EditorClassIdentifier: 985 | m_Material: {fileID: 1727631307} 986 | m_Color: {r: 1, g: 1, b: 1, a: 1} 987 | m_RaycastTarget: 0 988 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 989 | m_Maskable: 1 990 | m_OnCullStateChanged: 991 | m_PersistentCalls: 992 | m_Calls: [] 993 | m_Sprite: {fileID: 21300000, guid: 29c435903c4f8404f87a061424329530, type: 3} 994 | m_Type: 0 995 | m_PreserveAspect: 0 996 | m_FillCenter: 1 997 | m_FillMethod: 4 998 | m_FillAmount: 1 999 | m_FillClockwise: 1 1000 | m_FillOrigin: 0 1001 | m_UseSpriteMesh: 0 1002 | m_PixelsPerUnitMultiplier: 1 1003 | --- !u!114 &1695272627 1004 | MonoBehaviour: 1005 | m_ObjectHideFlags: 0 1006 | m_CorrespondingSourceObject: {fileID: 0} 1007 | m_PrefabInstance: {fileID: 0} 1008 | m_PrefabAsset: {fileID: 0} 1009 | m_GameObject: {fileID: 1695272624} 1010 | m_Enabled: 1 1011 | m_EditorHideFlags: 0 1012 | m_Script: {fileID: 11500000, guid: 109c41f08973846429af681aea0a30c4, type: 3} 1013 | m_Name: 1014 | m_EditorClassIdentifier: 1015 | r: {x: 10, y: 50, z: 10, w: 50} 1016 | rect2props: {x: 0.0000019073486, y: -0.0000076293945, z: 63.639614, w: 35.355343} 1017 | image: {fileID: 1695272626} 1018 | --- !u!222 &1695272628 1019 | CanvasRenderer: 1020 | m_ObjectHideFlags: 0 1021 | m_CorrespondingSourceObject: {fileID: 0} 1022 | m_PrefabInstance: {fileID: 0} 1023 | m_PrefabAsset: {fileID: 0} 1024 | m_GameObject: {fileID: 1695272624} 1025 | m_CullTransparentMesh: 0 1026 | --- !u!1 &1697298824 1027 | GameObject: 1028 | m_ObjectHideFlags: 0 1029 | m_CorrespondingSourceObject: {fileID: 0} 1030 | m_PrefabInstance: {fileID: 0} 1031 | m_PrefabAsset: {fileID: 0} 1032 | serializedVersion: 6 1033 | m_Component: 1034 | - component: {fileID: 1697298825} 1035 | - component: {fileID: 1697298827} 1036 | - component: {fileID: 1697298826} 1037 | - component: {fileID: 1697298828} 1038 | m_Layer: 5 1039 | m_Name: Image 1040 | m_TagString: Untagged 1041 | m_Icon: {fileID: 0} 1042 | m_NavMeshLayer: 0 1043 | m_StaticEditorFlags: 0 1044 | m_IsActive: 1 1045 | --- !u!224 &1697298825 1046 | RectTransform: 1047 | m_ObjectHideFlags: 0 1048 | m_CorrespondingSourceObject: {fileID: 0} 1049 | m_PrefabInstance: {fileID: 0} 1050 | m_PrefabAsset: {fileID: 0} 1051 | m_GameObject: {fileID: 1697298824} 1052 | m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} 1053 | m_LocalPosition: {x: 0, y: 0, z: 0} 1054 | m_LocalScale: {x: 1, y: 1, z: 1} 1055 | m_Children: [] 1056 | m_Father: {fileID: 418354422} 1057 | m_RootOrder: 0 1058 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 1059 | m_AnchorMin: {x: 0.5, y: 0.5} 1060 | m_AnchorMax: {x: 0.5, y: 0.5} 1061 | m_AnchoredPosition: {x: 50.3, y: 23.3} 1062 | m_SizeDelta: {x: 100, y: 100} 1063 | m_Pivot: {x: 0.5, y: 0.5} 1064 | --- !u!114 &1697298826 1065 | MonoBehaviour: 1066 | m_ObjectHideFlags: 0 1067 | m_CorrespondingSourceObject: {fileID: 0} 1068 | m_PrefabInstance: {fileID: 0} 1069 | m_PrefabAsset: {fileID: 0} 1070 | m_GameObject: {fileID: 1697298824} 1071 | m_Enabled: 1 1072 | m_EditorHideFlags: 0 1073 | m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3} 1074 | m_Name: 1075 | m_EditorClassIdentifier: 1076 | m_Material: {fileID: 1262233990} 1077 | m_Color: {r: 0.7830189, g: 0.16620687, b: 0.16620687, a: 1} 1078 | m_RaycastTarget: 1 1079 | m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0} 1080 | m_Maskable: 1 1081 | m_OnCullStateChanged: 1082 | m_PersistentCalls: 1083 | m_Calls: [] 1084 | m_Sprite: {fileID: 0} 1085 | m_Type: 0 1086 | m_PreserveAspect: 0 1087 | m_FillCenter: 1 1088 | m_FillMethod: 4 1089 | m_FillAmount: 1 1090 | m_FillClockwise: 1 1091 | m_FillOrigin: 0 1092 | m_UseSpriteMesh: 0 1093 | m_PixelsPerUnitMultiplier: 1 1094 | --- !u!222 &1697298827 1095 | CanvasRenderer: 1096 | m_ObjectHideFlags: 0 1097 | m_CorrespondingSourceObject: {fileID: 0} 1098 | m_PrefabInstance: {fileID: 0} 1099 | m_PrefabAsset: {fileID: 0} 1100 | m_GameObject: {fileID: 1697298824} 1101 | m_CullTransparentMesh: 0 1102 | --- !u!114 &1697298828 1103 | MonoBehaviour: 1104 | m_ObjectHideFlags: 0 1105 | m_CorrespondingSourceObject: {fileID: 0} 1106 | m_PrefabInstance: {fileID: 0} 1107 | m_PrefabAsset: {fileID: 0} 1108 | m_GameObject: {fileID: 1697298824} 1109 | m_Enabled: 1 1110 | m_EditorHideFlags: 0 1111 | m_Script: {fileID: 11500000, guid: adb30198aa32dd140b5750692dd48104, type: 3} 1112 | m_Name: 1113 | m_EditorClassIdentifier: 1114 | radius: 16 1115 | image: {fileID: 1697298826} 1116 | --- !u!21 &1727631307 1117 | Material: 1118 | serializedVersion: 6 1119 | m_ObjectHideFlags: 0 1120 | m_CorrespondingSourceObject: {fileID: 0} 1121 | m_PrefabInstance: {fileID: 0} 1122 | m_PrefabAsset: {fileID: 0} 1123 | m_Name: UI/RoundedCorners/IndependentRoundedCorners 1124 | m_Shader: {fileID: 4800000, guid: d3beb88e61f88ca4393acdefb005fa70, type: 3} 1125 | m_ShaderKeywords: 1126 | m_LightmapFlags: 4 1127 | m_EnableInstancingVariants: 0 1128 | m_DoubleSidedGI: 0 1129 | m_CustomRenderQueue: -1 1130 | stringTagMap: {} 1131 | disabledShaderPasses: [] 1132 | m_SavedProperties: 1133 | serializedVersion: 3 1134 | m_TexEnvs: 1135 | - _MainTex: 1136 | m_Texture: {fileID: 0} 1137 | m_Scale: {x: 1, y: 1} 1138 | m_Offset: {x: 0, y: 0} 1139 | m_Floats: 1140 | - _ColorMask: 15 1141 | - _Stencil: 0 1142 | - _StencilComp: 8 1143 | - _StencilOp: 0 1144 | - _StencilReadMask: 255 1145 | - _StencilWriteMask: 255 1146 | - _UseUIAlphaClip: 0 1147 | m_Colors: 1148 | - _halfSize: {r: 50, g: 50, b: 0, a: 0} 1149 | - _r: {r: 10, g: 50, b: 10, a: 50} 1150 | - _rect2props: {r: 0.0000019073486, g: -0.0000076293945, b: 63.639614, a: 35.355343} 1151 | m_BuildTextureStacks: [] 1152 | --- !u!1 &1923065472 1153 | GameObject: 1154 | m_ObjectHideFlags: 0 1155 | m_CorrespondingSourceObject: {fileID: 0} 1156 | m_PrefabInstance: {fileID: 0} 1157 | m_PrefabAsset: {fileID: 0} 1158 | serializedVersion: 6 1159 | m_Component: 1160 | - component: {fileID: 1923065473} 1161 | - component: {fileID: 1923065475} 1162 | - component: {fileID: 1923065474} 1163 | m_Layer: 0 1164 | m_Name: EventSystem 1165 | m_TagString: Untagged 1166 | m_Icon: {fileID: 0} 1167 | m_NavMeshLayer: 0 1168 | m_StaticEditorFlags: 0 1169 | m_IsActive: 1 1170 | --- !u!4 &1923065473 1171 | Transform: 1172 | m_ObjectHideFlags: 0 1173 | m_CorrespondingSourceObject: {fileID: 0} 1174 | m_PrefabInstance: {fileID: 0} 1175 | m_PrefabAsset: {fileID: 0} 1176 | m_GameObject: {fileID: 1923065472} 1177 | m_LocalRotation: {x: -0, y: -0, z: -0, w: 1} 1178 | m_LocalPosition: {x: 0, y: 0, z: -369} 1179 | m_LocalScale: {x: 1, y: 1, z: 1} 1180 | m_Children: [] 1181 | m_Father: {fileID: 0} 1182 | m_RootOrder: 2 1183 | m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} 1184 | --- !u!114 &1923065474 1185 | MonoBehaviour: 1186 | m_ObjectHideFlags: 0 1187 | m_CorrespondingSourceObject: {fileID: 0} 1188 | m_PrefabInstance: {fileID: 0} 1189 | m_PrefabAsset: {fileID: 0} 1190 | m_GameObject: {fileID: 1923065472} 1191 | m_Enabled: 1 1192 | m_EditorHideFlags: 0 1193 | m_Script: {fileID: 11500000, guid: 4f231c4fb786f3946a6b90b886c48677, type: 3} 1194 | m_Name: 1195 | m_EditorClassIdentifier: 1196 | m_HorizontalAxis: Horizontal 1197 | m_VerticalAxis: Vertical 1198 | m_SubmitButton: Submit 1199 | m_CancelButton: Cancel 1200 | m_InputActionsPerSecond: 10 1201 | m_RepeatDelay: 0.5 1202 | m_ForceModuleActive: 0 1203 | --- !u!114 &1923065475 1204 | MonoBehaviour: 1205 | m_ObjectHideFlags: 0 1206 | m_CorrespondingSourceObject: {fileID: 0} 1207 | m_PrefabInstance: {fileID: 0} 1208 | m_PrefabAsset: {fileID: 0} 1209 | m_GameObject: {fileID: 1923065472} 1210 | m_Enabled: 1 1211 | m_EditorHideFlags: 0 1212 | m_Script: {fileID: 11500000, guid: 76c392e42b5098c458856cdf6ecaaaa1, type: 3} 1213 | m_Name: 1214 | m_EditorClassIdentifier: 1215 | m_FirstSelected: {fileID: 0} 1216 | m_sendNavigationEvents: 1 1217 | m_DragThreshold: 10 1218 | -------------------------------------------------------------------------------- /Examples/example.unity.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3fe7f49864db35c419623c5112a65cd1 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2019 Kirill Evdokimov 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /LICENSE.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 1b43d824145a28946bd5f4edd280b0d8 3 | DefaultImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Unity-UI-Rounded-Corners 2 | 3 | These components and shaders allow you to add rounded corners to UI elements! 4 | 5 | 6 | --- 7 | 8 | ![](title.gif) 9 | 10 | ## How to install 11 | ### Option 1: Package Manager (Unity 2019.3 and higher) 12 | ![](how-to-install.gif) 13 | URL to copypaste: 14 | ``` 15 | https://github.com/kirevdokimov/Unity-UI-Rounded-Corners.git 16 | ``` 17 | 18 | ### Option 2: Package Manager (Manual) 19 | - Open `%projectname%/Packages/manifest.json` 20 | - Add the following to the dependencies section: 21 | ``` 22 | "com.nobi.roundedcorners": "https://github.com/kirevdokimov/Unity-UI-Rounded-Corners.git" 23 | ``` 24 | 25 | ## How to use 26 | #### Symmetrical roundness 27 | - Add `ImageWithRoundedCorners` component to a GameObject with an `Image` 28 | - Adjust `Radius` property 29 | #### Certain roundness value for each corner 30 | - Add `ImageWithIndependentRoundedCorners` to a GameObject with an `Image` 31 | - Adjust `r` Vector4 property. Each vector component represent radius, clockwise, starting with top-left corner 32 | #### Important thing 33 | If you need to add or change the image at runtime, call `Validate()` and then `Refresh()` to update the materials. 34 | 35 | 36 | # Features 37 | ## Changing roundness separately or all at once 38 | ![](separate-roundness.gif) 39 | ## Keeps round while resizing 40 | ![](gif-01.gif) 41 | ## Better quality than sprites 42 | ![](image-00.png) 43 | ## Supports Unity Mask 44 | ![](gif-02.gif) 45 | ## Supports Tint 46 | ![](gif-04.gif) -------------------------------------------------------------------------------- /README.md.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c5e96d7fdc79c064f8744872ad300861 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /UiRoundedCorners.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c5fc0ea21303bfe4fb663b71ffa38b8e 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /UiRoundedCorners/DestroyHelper.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | 3 | namespace Nobi.UiRoundedCorners { 4 | internal static class DestroyHelper { 5 | internal static void Destroy(Object @object) { 6 | #if UNITY_EDITOR 7 | if (Application.isPlaying) { 8 | Object.Destroy(@object); 9 | } else { 10 | Object.DestroyImmediate(@object); 11 | } 12 | #else 13 | Object.Destroy(@object); 14 | #endif 15 | } 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /UiRoundedCorners/DestroyHelper.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 374d389d769fe864c8aa8eccfa70b0b2 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /UiRoundedCorners/Editor.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: bc55785c2d5655f4e839d5408f397028 3 | folderAsset: yes 4 | DefaultImporter: 5 | externalObjects: {} 6 | userData: 7 | assetBundleName: 8 | assetBundleVariant: 9 | -------------------------------------------------------------------------------- /UiRoundedCorners/Editor/ImageWithIndependentRoundedCornersInspector.cs: -------------------------------------------------------------------------------- 1 | using UnityEditor; 2 | using UnityEngine.UI; 3 | 4 | namespace Nobi.UiRoundedCorners.Editor { 5 | [CustomEditor(typeof(ImageWithIndependentRoundedCorners))] 6 | public class ImageWithIndependentRoundedCornersInspector : UnityEditor.Editor { 7 | private ImageWithIndependentRoundedCorners script; 8 | 9 | private void OnEnable() { 10 | script = (ImageWithIndependentRoundedCorners)target; 11 | } 12 | 13 | public override void OnInspectorGUI() { 14 | base.OnInspectorGUI(); 15 | 16 | if (!script.TryGetComponent(out var _)) { 17 | EditorGUILayout.HelpBox("This script requires an MaskableGraphic (Image or RawImage) component on the same gameobject", MessageType.Warning); 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /UiRoundedCorners/Editor/ImageWithIndependentRoundedCornersInspector.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2364a6676566e7842a1a053d02d5ec5b 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /UiRoundedCorners/Editor/ImageWithRoundedCornersInspector.cs: -------------------------------------------------------------------------------- 1 | using UnityEditor; 2 | using UnityEngine.UI; 3 | 4 | namespace Nobi.UiRoundedCorners.Editor { 5 | [CustomEditor(typeof(ImageWithRoundedCorners))] 6 | public class ImageWithRoundedCornersInspector : UnityEditor.Editor { 7 | private ImageWithRoundedCorners script; 8 | 9 | private void OnEnable() { 10 | script = (ImageWithRoundedCorners)target; 11 | } 12 | 13 | public override void OnInspectorGUI() { 14 | base.OnInspectorGUI(); 15 | 16 | if (!script.TryGetComponent(out var _)) { 17 | EditorGUILayout.HelpBox("This script requires an MaskableGraphic (Image or RawImage) component on the same gameobject", MessageType.Warning); 18 | } 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /UiRoundedCorners/Editor/ImageWithRoundedCornersInspector.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 2b7cf3ef8317dd04eaff6d4b44a16520 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /UiRoundedCorners/Editor/Nobi.UiRoundedCorners.Editor.asmdef: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Nobi.UiRoundedCorners.Editor", 3 | "rootNamespace": "", 4 | "references": [ 5 | "GUID:02fb846f82d73b64f884c961e8616088" 6 | ], 7 | "includePlatforms": [ 8 | "Editor" 9 | ], 10 | "excludePlatforms": [], 11 | "allowUnsafeCode": false, 12 | "overrideReferences": false, 13 | "precompiledReferences": [], 14 | "autoReferenced": true, 15 | "defineConstraints": [], 16 | "versionDefines": [], 17 | "noEngineReferences": false 18 | } -------------------------------------------------------------------------------- /UiRoundedCorners/Editor/Nobi.UiRoundedCorners.Editor.asmdef.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 10725695f79a428429a1a3c374a5a230 3 | AssemblyDefinitionImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /UiRoundedCorners/ImageWithIndependentRoundedCorners.cs: -------------------------------------------------------------------------------- 1 | using Nobi.UiRoundedCorners; 2 | using UnityEditor; 3 | using UnityEngine; 4 | using UnityEngine.UI; 5 | 6 | namespace Nobi.UiRoundedCorners { 7 | [ExecuteInEditMode] //Required to do validation with OnEnable() 8 | [DisallowMultipleComponent] //You can only have one of these in every object 9 | [RequireComponent(typeof(RectTransform))] 10 | public class ImageWithIndependentRoundedCorners : MonoBehaviour { 11 | private static readonly int prop_halfSize = Shader.PropertyToID("_halfSize"); 12 | private static readonly int prop_radiuses = Shader.PropertyToID("_r"); 13 | private static readonly int prop_rect2props = Shader.PropertyToID("_rect2props"); 14 | 15 | // Vector2.right rotated clockwise by 45 degrees 16 | private static readonly Vector2 wNorm = new Vector2(.7071068f, -.7071068f); 17 | // Vector2.right rotated counter-clockwise by 45 degrees 18 | private static readonly Vector2 hNorm = new Vector2(.7071068f, .7071068f); 19 | 20 | public Vector4 r = new Vector4(40f, 40f, 40f, 40f); 21 | private Material material; 22 | 23 | // xy - position, 24 | // zw - halfSize 25 | [HideInInspector, SerializeField] private Vector4 rect2props; 26 | [HideInInspector, SerializeField] private MaskableGraphic image; 27 | 28 | private void OnValidate() { 29 | Validate(); 30 | Refresh(); 31 | } 32 | 33 | private void OnEnable() { 34 | //You can only add either ImageWithRoundedCorners or ImageWithIndependentRoundedCorners 35 | //It will replace the other component when added into the object. 36 | var other = GetComponent(); 37 | if (other != null) 38 | { 39 | r = Vector4.one * other.radius; //When it does, transfer the radius value to this script 40 | DestroyHelper.Destroy(other); 41 | } 42 | 43 | Validate(); 44 | Refresh(); 45 | } 46 | 47 | private void OnRectTransformDimensionsChange() { 48 | if (enabled && material != null) { 49 | Refresh(); 50 | } 51 | } 52 | 53 | private void OnDestroy() { 54 | image.material = null; //This makes so that when the component is removed, the UI material returns to null 55 | 56 | DestroyHelper.Destroy(material); 57 | image = null; 58 | material = null; 59 | } 60 | 61 | public void Validate() { 62 | if (material == null) { 63 | material = new Material(Shader.Find("UI/RoundedCorners/IndependentRoundedCorners")); 64 | } 65 | 66 | if (image == null) { 67 | TryGetComponent(out image); 68 | } 69 | 70 | if (image != null) { 71 | image.material = material; 72 | } 73 | } 74 | 75 | public void Refresh() { 76 | var rect = ((RectTransform)transform).rect; 77 | RecalculateProps(rect.size); 78 | material.SetVector(prop_rect2props, rect2props); 79 | material.SetVector(prop_halfSize, rect.size * .5f); 80 | material.SetVector(prop_radiuses, r); 81 | } 82 | 83 | private void RecalculateProps(Vector2 size) { 84 | // Vector that goes from left to right sides of rect2 85 | var aVec = new Vector2(size.x, -size.y + r.x + r.z); 86 | 87 | // Project vector aVec to wNorm to get magnitude of rect2 width vector 88 | var halfWidth = Vector2.Dot(aVec, wNorm) * .5f; 89 | rect2props.z = halfWidth; 90 | 91 | 92 | // Vector that goes from bottom to top sides of rect2 93 | var bVec = new Vector2(size.x, size.y - r.w - r.y); 94 | 95 | // Project vector bVec to hNorm to get magnitude of rect2 height vector 96 | var halfHeight = Vector2.Dot(bVec, hNorm) * .5f; 97 | rect2props.w = halfHeight; 98 | 99 | 100 | // Vector that goes from left to top sides of rect2 101 | var efVec = new Vector2(size.x - r.x - r.y, 0); 102 | 103 | // Vector that goes from point E to point G, which is top-left of rect2 104 | var egVec = hNorm * Vector2.Dot(efVec, hNorm); 105 | 106 | // Position of point E relative to center of coord system 107 | var ePoint = new Vector2(r.x - (size.x / 2), size.y / 2); 108 | 109 | // Origin of rect2 relative to center of coord system 110 | // ePoint + egVec == vector to top-left corner of rect2 111 | // wNorm * halfWidth + hNorm * -halfHeight == vector from top-left corner to center 112 | var origin = ePoint + egVec + wNorm * halfWidth + hNorm * -halfHeight; 113 | rect2props.x = origin.x; 114 | rect2props.y = origin.y; 115 | } 116 | } 117 | } 118 | 119 | /// 120 | /// Display Vector4 as 4 separate fields for each corners. 121 | /// It's way easier to use than w,x,y,z in Vector4. 122 | /// 123 | #if UNITY_EDITOR 124 | [CustomEditor(typeof(ImageWithIndependentRoundedCorners))] 125 | public class Vector4Editor : Editor 126 | { 127 | public override void OnInspectorGUI() 128 | { 129 | //DrawDefaultInspector(); 130 | 131 | serializedObject.Update(); 132 | 133 | SerializedProperty vector4Prop = serializedObject.FindProperty("r"); 134 | 135 | EditorGUILayout.PropertyField(vector4Prop.FindPropertyRelative("x"), new GUIContent("Top Left Corner")); 136 | EditorGUILayout.PropertyField(vector4Prop.FindPropertyRelative("y"), new GUIContent("Top Right Corner")); 137 | EditorGUILayout.PropertyField(vector4Prop.FindPropertyRelative("w"), new GUIContent("Bottom Left Corner")); 138 | EditorGUILayout.PropertyField(vector4Prop.FindPropertyRelative("z"), new GUIContent("Bottom Right Corner")); 139 | 140 | serializedObject.ApplyModifiedProperties(); 141 | } 142 | } 143 | #endif -------------------------------------------------------------------------------- /UiRoundedCorners/ImageWithIndependentRoundedCorners.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 109c41f08973846429af681aea0a30c4 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /UiRoundedCorners/ImageWithRoundedCorners.cs: -------------------------------------------------------------------------------- 1 | using UnityEngine; 2 | using UnityEngine.UI; 3 | 4 | namespace Nobi.UiRoundedCorners { 5 | [ExecuteInEditMode] //Required to check the OnEnable function 6 | [DisallowMultipleComponent] //You can only have one of these in every object. 7 | [RequireComponent(typeof(RectTransform))] 8 | public class ImageWithRoundedCorners : MonoBehaviour { 9 | private static readonly int Props = Shader.PropertyToID("_WidthHeightRadius"); 10 | 11 | public float radius = 40f; 12 | private Material material; 13 | 14 | [HideInInspector, SerializeField] private MaskableGraphic image; 15 | 16 | private void OnValidate() { 17 | Validate(); 18 | Refresh(); 19 | } 20 | 21 | private void OnDestroy() { 22 | image.material = null; //This makes so that when the component is removed, the UI material returns to null 23 | 24 | DestroyHelper.Destroy(material); 25 | image = null; 26 | material = null; 27 | } 28 | 29 | private void OnEnable() { 30 | //You can only add either ImageWithRoundedCorners or ImageWithIndependentRoundedCorners 31 | //It will replace the other component when added into the object. 32 | var other = GetComponent(); 33 | if (other != null) 34 | { 35 | radius = other.r.x; //When it does, transfer the radius value to this script 36 | DestroyHelper.Destroy(other); 37 | } 38 | 39 | Validate(); 40 | Refresh(); 41 | } 42 | 43 | private void OnRectTransformDimensionsChange() { 44 | if (enabled && material != null) { 45 | Refresh(); 46 | } 47 | } 48 | 49 | public void Validate() { 50 | if (material == null) { 51 | material = new Material(Shader.Find("UI/RoundedCorners/RoundedCorners")); 52 | } 53 | 54 | if (image == null) { 55 | TryGetComponent(out image); 56 | } 57 | 58 | if (image != null) { 59 | image.material = material; 60 | } 61 | } 62 | 63 | public void Refresh() { 64 | var rect = ((RectTransform)transform).rect; 65 | 66 | //Multiply radius value by 2 to make the radius value appear consistent with ImageWithIndependentRoundedCorners script. 67 | //Right now, the ImageWithIndependentRoundedCorners appears to have double the radius than this. 68 | material.SetVector(Props, new Vector4(rect.width, rect.height, radius * 2, 0)); 69 | } 70 | } 71 | } -------------------------------------------------------------------------------- /UiRoundedCorners/ImageWithRoundedCorners.cs.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: adb30198aa32dd140b5750692dd48104 3 | MonoImporter: 4 | externalObjects: {} 5 | serializedVersion: 2 6 | defaultReferences: [] 7 | executionOrder: 0 8 | icon: {instanceID: 0} 9 | userData: 10 | assetBundleName: 11 | assetBundleVariant: 12 | -------------------------------------------------------------------------------- /UiRoundedCorners/IndependentRoundedCorners.shader: -------------------------------------------------------------------------------- 1 | Shader "UI/RoundedCorners/IndependentRoundedCorners" { 2 | 3 | Properties { 4 | [HideInInspector] _MainTex ("Texture", 2D) = "white" {} 5 | 6 | // --- Mask support --- 7 | [HideInInspector] _StencilComp ("Stencil Comparison", Float) = 8 8 | [HideInInspector] _Stencil ("Stencil ID", Float) = 0 9 | [HideInInspector] _StencilOp ("Stencil Operation", Float) = 0 10 | [HideInInspector] _StencilWriteMask ("Stencil Write Mask", Float) = 255 11 | [HideInInspector] _StencilReadMask ("Stencil Read Mask", Float) = 255 12 | [HideInInspector] _ColorMask ("Color Mask", Float) = 15 13 | [HideInInspector] _UseUIAlphaClip ("Use Alpha Clip", Float) = 0 14 | // Definition in Properties section is required to Mask works properly 15 | _r ("r", Vector) = (0,0,0,0) 16 | _halfSize ("halfSize", Vector) = (0,0,0,0) 17 | _rect2props ("rect2props", Vector) = (0,0,0,0) 18 | // --- 19 | } 20 | 21 | SubShader { 22 | Tags { 23 | "RenderType"="Transparent" 24 | "Queue"="Transparent" 25 | } 26 | 27 | // --- Mask support --- 28 | Stencil { 29 | Ref [_Stencil] 30 | Comp [_StencilComp] 31 | Pass [_StencilOp] 32 | ReadMask [_StencilReadMask] 33 | WriteMask [_StencilWriteMask] 34 | } 35 | Cull Off 36 | Lighting Off 37 | ZTest [unity_GUIZTestMode] 38 | ColorMask [_ColorMask] 39 | // --- 40 | 41 | Blend SrcAlpha OneMinusSrcAlpha, One OneMinusSrcAlpha 42 | ZWrite Off 43 | 44 | Pass { 45 | CGPROGRAM 46 | 47 | #include "UnityCG.cginc" 48 | #include "UnityUI.cginc" 49 | #include "SDFUtils.cginc" 50 | #include "ShaderSetup.cginc" 51 | 52 | #pragma vertex vert 53 | #pragma fragment frag 54 | 55 | #pragma multi_compile_local _ UNITY_UI_CLIP_RECT 56 | #pragma multi_compile_local _ UNITY_UI_ALPHACLIP 57 | 58 | float4 _r; 59 | float4 _halfSize; 60 | float4 _rect2props; 61 | sampler2D _MainTex; 62 | float4 _ClipRect; 63 | fixed4 _TextureSampleAdd; 64 | 65 | fixed4 frag (v2f i) : SV_Target { 66 | half4 color = (tex2D(_MainTex, i.uv) + _TextureSampleAdd) * i.color; 67 | 68 | #ifdef UNITY_UI_CLIP_RECT 69 | color.a *= UnityGet2DClipping(i.worldPosition.xy, _ClipRect); 70 | #endif 71 | 72 | #ifdef UNITY_UI_ALPHACLIP 73 | clip(color.a - 0.001); 74 | #endif 75 | 76 | if (color.a <= 0) { 77 | return color; 78 | } 79 | 80 | float alpha = CalcAlphaForIndependentCorners(i.uv, _halfSize.xy, _rect2props, _r); 81 | 82 | #ifdef UNITY_UI_ALPHACLIP 83 | clip(alpha - 0.001); 84 | #endif 85 | 86 | return mixAlpha(tex2D(_MainTex, i.uv), i.color, alpha); 87 | } 88 | 89 | ENDCG 90 | } 91 | } 92 | } 93 | -------------------------------------------------------------------------------- /UiRoundedCorners/IndependentRoundedCorners.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d3beb88e61f88ca4393acdefb005fa70 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /UiRoundedCorners/Nobi.UiRoundedCorners.asmdef: -------------------------------------------------------------------------------- 1 | { 2 | "name": "Nobi.UiRoundedCorners", 3 | "references": [], 4 | "optionalUnityReferences": [], 5 | "includePlatforms": [], 6 | "excludePlatforms": [], 7 | "allowUnsafeCode": false 8 | } -------------------------------------------------------------------------------- /UiRoundedCorners/Nobi.UiRoundedCorners.asmdef.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 02fb846f82d73b64f884c961e8616088 3 | AssemblyDefinitionImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /UiRoundedCorners/RoundedCorners.shader: -------------------------------------------------------------------------------- 1 | Shader "UI/RoundedCorners/RoundedCorners" { 2 | Properties { 3 | [HideInInspector] _MainTex ("Texture", 2D) = "white" {} 4 | 5 | // --- Mask support --- 6 | [HideInInspector] _StencilComp ("Stencil Comparison", Float) = 8 7 | [HideInInspector] _Stencil ("Stencil ID", Float) = 0 8 | [HideInInspector] _StencilOp ("Stencil Operation", Float) = 0 9 | [HideInInspector] _StencilWriteMask ("Stencil Write Mask", Float) = 255 10 | [HideInInspector] _StencilReadMask ("Stencil Read Mask", Float) = 255 11 | [HideInInspector] _ColorMask ("Color Mask", Float) = 15 12 | [HideInInspector] _UseUIAlphaClip ("Use Alpha Clip", Float) = 0 13 | 14 | // Definition in Properties section is required to Mask works properly 15 | _WidthHeightRadius ("WidthHeightRadius", Vector) = (0,0,0,0) 16 | // --- 17 | } 18 | 19 | SubShader { 20 | Tags { 21 | "RenderType"="Transparent" 22 | "Queue"="Transparent" 23 | } 24 | 25 | // --- Mask support --- 26 | Stencil { 27 | Ref [_Stencil] 28 | Comp [_StencilComp] 29 | Pass [_StencilOp] 30 | ReadMask [_StencilReadMask] 31 | WriteMask [_StencilWriteMask] 32 | } 33 | Cull Off 34 | Lighting Off 35 | ZTest [unity_GUIZTestMode] 36 | ColorMask [_ColorMask] 37 | // --- 38 | 39 | Blend SrcAlpha OneMinusSrcAlpha, One OneMinusSrcAlpha 40 | ZWrite Off 41 | 42 | Pass { 43 | CGPROGRAM 44 | 45 | #include "UnityCG.cginc" 46 | #include "UnityUI.cginc" 47 | #include "SDFUtils.cginc" 48 | #include "ShaderSetup.cginc" 49 | 50 | #pragma vertex vert 51 | #pragma fragment frag 52 | 53 | #pragma multi_compile_local _ UNITY_UI_CLIP_RECT 54 | #pragma multi_compile_local _ UNITY_UI_ALPHACLIP 55 | 56 | float4 _WidthHeightRadius; 57 | sampler2D _MainTex; 58 | fixed4 _TextureSampleAdd; 59 | float4 _ClipRect; 60 | 61 | fixed4 frag (v2f i) : SV_Target { 62 | half4 color = (tex2D(_MainTex, i.uv) + _TextureSampleAdd) * i.color; 63 | 64 | #ifdef UNITY_UI_CLIP_RECT 65 | color.a *= UnityGet2DClipping(i.worldPosition.xy, _ClipRect); 66 | #endif 67 | 68 | #ifdef UNITY_UI_ALPHACLIP 69 | clip(color.a - 0.001); 70 | #endif 71 | 72 | if (color.a <= 0) { 73 | return color; 74 | } 75 | 76 | float alpha = CalcAlpha(i.uv, _WidthHeightRadius.xy, _WidthHeightRadius.z); 77 | 78 | #ifdef UNITY_UI_ALPHACLIP 79 | clip(alpha - 0.001); 80 | #endif 81 | 82 | return mixAlpha(tex2D(_MainTex, i.uv), i.color, alpha); 83 | } 84 | 85 | ENDCG 86 | } 87 | } 88 | } 89 | -------------------------------------------------------------------------------- /UiRoundedCorners/RoundedCorners.shader.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 0bd2ec5d73751e34a814274a454bec41 3 | ShaderImporter: 4 | externalObjects: {} 5 | defaultTextures: [] 6 | nonModifiableTextures: [] 7 | userData: 8 | assetBundleName: 9 | assetBundleVariant: 10 | -------------------------------------------------------------------------------- /UiRoundedCorners/SDFUtils.cginc: -------------------------------------------------------------------------------- 1 | // SDF Function for rectangle 2 | float rectangle(float2 samplePosition, float2 halfSize){ 3 | // X component represents signed distance to closest vertical edge of rectangle 4 | // Same for Y but for closest horizontal edge 5 | // HalfSize represents two distances from each axis of 2d space to a сorresponding edge 6 | float2 distanceToEdge = abs(samplePosition) - halfSize; 7 | // max(n, 0) to remove distances that signed with minus (distances inside rectangle) 8 | // length to calculate distance from outside (distances that > 0) to rectangle 9 | float outsideDistance = length(max(distanceToEdge, 0)); 10 | // max(x,y) is a cheap way to calculate distance to closest edge inside rectangle 11 | // with min we just make sure that inside distances would not impact on outside distances 12 | float insideDistance = min(max(distanceToEdge.x, distanceToEdge.y), 0); 13 | return outsideDistance + insideDistance; 14 | } 15 | 16 | // An extension of rectangle() function to modify signed distance (effect as a wrap around rectangle) 17 | float roundedRectangle(float2 samplePosition, float absoluteRound, float2 halfSize){ 18 | // subtrancting value from final distance effects like a wrap around rectangle, so 19 | // the solution is to decrease actual rectangle with `absoluteRound` value 20 | // and then make an effect of wrap with size of `absoluteRound` 21 | return rectangle(samplePosition, halfSize - absoluteRound) - absoluteRound; 22 | } 23 | 24 | // Smoothstep function with antialiasing 25 | float AntialiasedCutoff(float distance){ 26 | float distanceChange = fwidth(distance) * 0.5; 27 | return smoothstep(distanceChange, -distanceChange, distance); 28 | } 29 | 30 | float CalcAlpha(float2 samplePosition, float2 size, float radius){ 31 | // -.5 = translate origin of samplePositions from (0, 0) to (.5, .5) 32 | // because for Image component (0,0) is bottom-right, not a center 33 | // * size = scale samplePositions to localSpace of Image with this size 34 | float2 samplePositionTranslated = (samplePosition - .5) * size; 35 | float distToRect = roundedRectangle(samplePositionTranslated, radius * .5, size * .5); 36 | return AntialiasedCutoff(distToRect); 37 | } 38 | 39 | inline float2 translate(float2 samplePosition, float2 offset){ 40 | return samplePosition - offset; 41 | } 42 | 43 | float intersect(float shape1, float shape2){ 44 | return max(shape1, shape2); 45 | } 46 | 47 | float2 rotate(float2 samplePosition, float rotation){ 48 | const float PI = 3.14159; 49 | float angle = rotation * PI * 2 * -1; 50 | float sine, cosine; 51 | sincos(angle, sine, cosine); 52 | return float2(cosine * samplePosition.x + sine * samplePosition.y, cosine * samplePosition.y - sine * samplePosition.x); 53 | } 54 | 55 | float circle(float2 position, float radius){ 56 | return length(position) - radius; 57 | } 58 | 59 | float CalcAlphaForIndependentCorners(float2 samplePosition, float2 halfSize, float4 rect2props, float4 r){ 60 | 61 | samplePosition = (samplePosition - .5) * halfSize * 2; 62 | 63 | float r1 = rectangle(samplePosition, halfSize); 64 | 65 | float2 r2Position = rotate(translate(samplePosition, rect2props.xy), .125); 66 | float r2 = rectangle(r2Position, rect2props.zw); 67 | 68 | float2 circle0Position = translate(samplePosition, float2(-halfSize.x + r.x, halfSize.y - r.x)); 69 | float c0 = circle(circle0Position, r.x); 70 | 71 | float2 circle1Position = translate(samplePosition, float2(halfSize.x - r.y, halfSize.y - r.y)); 72 | float c1 = circle(circle1Position, r.y); 73 | 74 | float2 circle2Position = translate(samplePosition, float2(halfSize.x - r.z, -halfSize.y + r.z)); 75 | float c2 = circle(circle2Position, r.z); 76 | 77 | float2 circle3Position = translate(samplePosition, -halfSize + r.w); 78 | float c3 = circle(circle3Position, r.w); 79 | 80 | float dist = max(r1,min(min(min(min(r2, c0), c1), c2), c3)); 81 | return AntialiasedCutoff(dist); 82 | } -------------------------------------------------------------------------------- /UiRoundedCorners/SDFUtils.cginc.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 209beda86bef4cdf945cf90c8999e832 3 | timeCreated: 1575732888 -------------------------------------------------------------------------------- /UiRoundedCorners/ShaderSetup.cginc: -------------------------------------------------------------------------------- 1 | struct appdata { 2 | float4 vertex : POSITION; 3 | float2 uv : TEXCOORD0; 4 | float4 color : COLOR; // set from Image component property 5 | UNITY_VERTEX_INPUT_INSTANCE_ID 6 | }; 7 | 8 | struct v2f { 9 | float2 uv : TEXCOORD0; 10 | float4 vertex : SV_POSITION; 11 | float4 color : COLOR; 12 | float4 worldPosition : TEXCOORD1; 13 | UNITY_VERTEX_OUTPUT_STEREO 14 | }; 15 | 16 | v2f vert (appdata v) { 17 | v2f o; 18 | UNITY_SETUP_INSTANCE_ID(v); 19 | UNITY_INITIALIZE_OUTPUT(v2f, o); 20 | UNITY_INITIALIZE_VERTEX_OUTPUT_STEREO(o); 21 | o.worldPosition = v.vertex; 22 | o.vertex = UnityObjectToClipPos(v.vertex); 23 | o.uv = v.uv; 24 | o.color = v.color; 25 | return o; 26 | } 27 | 28 | inline fixed4 mixAlpha(fixed4 mainTexColor, fixed4 color, float sdfAlpha){ 29 | fixed4 col = mainTexColor * color; 30 | col.a = min(col.a, sdfAlpha); 31 | return col; 32 | } -------------------------------------------------------------------------------- /UiRoundedCorners/ShaderSetup.cginc.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c8b27b6dc4af4c65a0d1531a5c3a9880 3 | timeCreated: 1575827487 -------------------------------------------------------------------------------- /gif-01.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/gif-01.gif -------------------------------------------------------------------------------- /gif-01.gif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 81cf59c3bbdc67840b1ee3781f994d3f 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 10 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | grayScaleToAlpha: 0 27 | generateCubemap: 6 28 | cubemapConvolution: 0 29 | seamlessCubemap: 0 30 | textureFormat: 1 31 | maxTextureSize: 2048 32 | textureSettings: 33 | serializedVersion: 2 34 | filterMode: -1 35 | aniso: -1 36 | mipBias: -100 37 | wrapU: -1 38 | wrapV: -1 39 | wrapW: -1 40 | nPOTScale: 1 41 | lightmap: 0 42 | compressionQuality: 50 43 | spriteMode: 0 44 | spriteExtrude: 1 45 | spriteMeshType: 1 46 | alignment: 0 47 | spritePivot: {x: 0.5, y: 0.5} 48 | spritePixelsToUnits: 100 49 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 50 | spriteGenerateFallbackPhysicsShape: 1 51 | alphaUsage: 1 52 | alphaIsTransparency: 0 53 | spriteTessellationDetail: -1 54 | textureType: 0 55 | textureShape: 1 56 | singleChannelComponent: 0 57 | maxTextureSizeSet: 0 58 | compressionQualitySet: 0 59 | textureFormatSet: 0 60 | platformSettings: 61 | - serializedVersion: 3 62 | buildTarget: DefaultTexturePlatform 63 | maxTextureSize: 2048 64 | resizeAlgorithm: 0 65 | textureFormat: -1 66 | textureCompression: 1 67 | compressionQuality: 50 68 | crunchedCompression: 0 69 | allowsAlphaSplitting: 0 70 | overridden: 0 71 | androidETC2FallbackOverride: 0 72 | forceMaximumCompressionQuality_BC6H_BC7: 0 73 | spriteSheet: 74 | serializedVersion: 2 75 | sprites: [] 76 | outline: [] 77 | physicsShape: [] 78 | bones: [] 79 | spriteID: 80 | internalID: 0 81 | vertices: [] 82 | indices: 83 | edges: [] 84 | weights: [] 85 | secondaryTextures: [] 86 | spritePackingTag: 87 | pSDRemoveMatte: 0 88 | pSDShowRemoveMatteOption: 0 89 | userData: 90 | assetBundleName: 91 | assetBundleVariant: 92 | -------------------------------------------------------------------------------- /gif-02.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/gif-02.gif -------------------------------------------------------------------------------- /gif-02.gif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 111580c72624cb247800b9b7420d9cd1 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 10 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | grayScaleToAlpha: 0 27 | generateCubemap: 6 28 | cubemapConvolution: 0 29 | seamlessCubemap: 0 30 | textureFormat: 1 31 | maxTextureSize: 2048 32 | textureSettings: 33 | serializedVersion: 2 34 | filterMode: -1 35 | aniso: -1 36 | mipBias: -100 37 | wrapU: -1 38 | wrapV: -1 39 | wrapW: -1 40 | nPOTScale: 1 41 | lightmap: 0 42 | compressionQuality: 50 43 | spriteMode: 0 44 | spriteExtrude: 1 45 | spriteMeshType: 1 46 | alignment: 0 47 | spritePivot: {x: 0.5, y: 0.5} 48 | spritePixelsToUnits: 100 49 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 50 | spriteGenerateFallbackPhysicsShape: 1 51 | alphaUsage: 1 52 | alphaIsTransparency: 0 53 | spriteTessellationDetail: -1 54 | textureType: 0 55 | textureShape: 1 56 | singleChannelComponent: 0 57 | maxTextureSizeSet: 0 58 | compressionQualitySet: 0 59 | textureFormatSet: 0 60 | platformSettings: 61 | - serializedVersion: 3 62 | buildTarget: DefaultTexturePlatform 63 | maxTextureSize: 2048 64 | resizeAlgorithm: 0 65 | textureFormat: -1 66 | textureCompression: 1 67 | compressionQuality: 50 68 | crunchedCompression: 0 69 | allowsAlphaSplitting: 0 70 | overridden: 0 71 | androidETC2FallbackOverride: 0 72 | forceMaximumCompressionQuality_BC6H_BC7: 0 73 | spriteSheet: 74 | serializedVersion: 2 75 | sprites: [] 76 | outline: [] 77 | physicsShape: [] 78 | bones: [] 79 | spriteID: 80 | internalID: 0 81 | vertices: [] 82 | indices: 83 | edges: [] 84 | weights: [] 85 | secondaryTextures: [] 86 | spritePackingTag: 87 | pSDRemoveMatte: 0 88 | pSDShowRemoveMatteOption: 0 89 | userData: 90 | assetBundleName: 91 | assetBundleVariant: 92 | -------------------------------------------------------------------------------- /gif-04.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/gif-04.gif -------------------------------------------------------------------------------- /gif-04.gif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 197ce8c46eddfe24eb0003cdb98b6019 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 10 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | grayScaleToAlpha: 0 27 | generateCubemap: 6 28 | cubemapConvolution: 0 29 | seamlessCubemap: 0 30 | textureFormat: 1 31 | maxTextureSize: 2048 32 | textureSettings: 33 | serializedVersion: 2 34 | filterMode: -1 35 | aniso: -1 36 | mipBias: -100 37 | wrapU: -1 38 | wrapV: -1 39 | wrapW: -1 40 | nPOTScale: 1 41 | lightmap: 0 42 | compressionQuality: 50 43 | spriteMode: 0 44 | spriteExtrude: 1 45 | spriteMeshType: 1 46 | alignment: 0 47 | spritePivot: {x: 0.5, y: 0.5} 48 | spritePixelsToUnits: 100 49 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 50 | spriteGenerateFallbackPhysicsShape: 1 51 | alphaUsage: 1 52 | alphaIsTransparency: 0 53 | spriteTessellationDetail: -1 54 | textureType: 0 55 | textureShape: 1 56 | singleChannelComponent: 0 57 | maxTextureSizeSet: 0 58 | compressionQualitySet: 0 59 | textureFormatSet: 0 60 | platformSettings: 61 | - serializedVersion: 3 62 | buildTarget: DefaultTexturePlatform 63 | maxTextureSize: 2048 64 | resizeAlgorithm: 0 65 | textureFormat: -1 66 | textureCompression: 1 67 | compressionQuality: 50 68 | crunchedCompression: 0 69 | allowsAlphaSplitting: 0 70 | overridden: 0 71 | androidETC2FallbackOverride: 0 72 | forceMaximumCompressionQuality_BC6H_BC7: 0 73 | spriteSheet: 74 | serializedVersion: 2 75 | sprites: [] 76 | outline: [] 77 | physicsShape: [] 78 | bones: [] 79 | spriteID: 80 | internalID: 0 81 | vertices: [] 82 | indices: 83 | edges: [] 84 | weights: [] 85 | secondaryTextures: [] 86 | spritePackingTag: 87 | pSDRemoveMatte: 0 88 | pSDShowRemoveMatteOption: 0 89 | userData: 90 | assetBundleName: 91 | assetBundleVariant: 92 | -------------------------------------------------------------------------------- /how-to-install.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/how-to-install.gif -------------------------------------------------------------------------------- /how-to-install.gif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: d1677fd3d5717c646936d36e4a721d9a 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 11 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | vTOnly: 0 27 | grayScaleToAlpha: 0 28 | generateCubemap: 6 29 | cubemapConvolution: 0 30 | seamlessCubemap: 0 31 | textureFormat: 1 32 | maxTextureSize: 2048 33 | textureSettings: 34 | serializedVersion: 2 35 | filterMode: 1 36 | aniso: 1 37 | mipBias: 0 38 | wrapU: 0 39 | wrapV: 0 40 | wrapW: 0 41 | nPOTScale: 1 42 | lightmap: 0 43 | compressionQuality: 50 44 | spriteMode: 0 45 | spriteExtrude: 1 46 | spriteMeshType: 1 47 | alignment: 0 48 | spritePivot: {x: 0.5, y: 0.5} 49 | spritePixelsToUnits: 100 50 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 51 | spriteGenerateFallbackPhysicsShape: 1 52 | alphaUsage: 1 53 | alphaIsTransparency: 0 54 | spriteTessellationDetail: -1 55 | textureType: 0 56 | textureShape: 1 57 | singleChannelComponent: 0 58 | flipbookRows: 1 59 | flipbookColumns: 1 60 | maxTextureSizeSet: 0 61 | compressionQualitySet: 0 62 | textureFormatSet: 0 63 | ignorePngGamma: 0 64 | applyGammaDecoding: 0 65 | platformSettings: 66 | - serializedVersion: 3 67 | buildTarget: DefaultTexturePlatform 68 | maxTextureSize: 2048 69 | resizeAlgorithm: 0 70 | textureFormat: -1 71 | textureCompression: 1 72 | compressionQuality: 50 73 | crunchedCompression: 0 74 | allowsAlphaSplitting: 0 75 | overridden: 0 76 | androidETC2FallbackOverride: 0 77 | forceMaximumCompressionQuality_BC6H_BC7: 0 78 | spriteSheet: 79 | serializedVersion: 2 80 | sprites: [] 81 | outline: [] 82 | physicsShape: [] 83 | bones: [] 84 | spriteID: 85 | internalID: 0 86 | vertices: [] 87 | indices: 88 | edges: [] 89 | weights: [] 90 | secondaryTextures: [] 91 | spritePackingTag: 92 | pSDRemoveMatte: 0 93 | pSDShowRemoveMatteOption: 0 94 | userData: 95 | assetBundleName: 96 | assetBundleVariant: 97 | -------------------------------------------------------------------------------- /image-00.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/image-00.png -------------------------------------------------------------------------------- /image-00.png.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 3cd486b28604a80448b2660fcd9971bb 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 10 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | grayScaleToAlpha: 0 27 | generateCubemap: 6 28 | cubemapConvolution: 0 29 | seamlessCubemap: 0 30 | textureFormat: 1 31 | maxTextureSize: 2048 32 | textureSettings: 33 | serializedVersion: 2 34 | filterMode: -1 35 | aniso: -1 36 | mipBias: -100 37 | wrapU: -1 38 | wrapV: -1 39 | wrapW: -1 40 | nPOTScale: 1 41 | lightmap: 0 42 | compressionQuality: 50 43 | spriteMode: 0 44 | spriteExtrude: 1 45 | spriteMeshType: 1 46 | alignment: 0 47 | spritePivot: {x: 0.5, y: 0.5} 48 | spritePixelsToUnits: 100 49 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 50 | spriteGenerateFallbackPhysicsShape: 1 51 | alphaUsage: 1 52 | alphaIsTransparency: 0 53 | spriteTessellationDetail: -1 54 | textureType: 0 55 | textureShape: 1 56 | singleChannelComponent: 0 57 | maxTextureSizeSet: 0 58 | compressionQualitySet: 0 59 | textureFormatSet: 0 60 | platformSettings: 61 | - serializedVersion: 3 62 | buildTarget: DefaultTexturePlatform 63 | maxTextureSize: 2048 64 | resizeAlgorithm: 0 65 | textureFormat: -1 66 | textureCompression: 1 67 | compressionQuality: 50 68 | crunchedCompression: 0 69 | allowsAlphaSplitting: 0 70 | overridden: 0 71 | androidETC2FallbackOverride: 0 72 | forceMaximumCompressionQuality_BC6H_BC7: 0 73 | spriteSheet: 74 | serializedVersion: 2 75 | sprites: [] 76 | outline: [] 77 | physicsShape: [] 78 | bones: [] 79 | spriteID: 80 | internalID: 0 81 | vertices: [] 82 | indices: 83 | edges: [] 84 | weights: [] 85 | secondaryTextures: [] 86 | spritePackingTag: 87 | pSDRemoveMatte: 0 88 | pSDShowRemoveMatteOption: 0 89 | userData: 90 | assetBundleName: 91 | assetBundleVariant: 92 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "com.nobi.roundedcorners", 3 | "displayName": "UI Rounded Corners", 4 | "version": "3.3.0", 5 | "description": "This package provides components and shaders that allow you to add rounded corners to UI elements!", 6 | "keywords": [ 7 | "UI", 8 | "Shader", 9 | "Cg", 10 | "Hlsl" 11 | ], 12 | "category": "UI", 13 | "files": [ 14 | "/LICENSE", 15 | "/LICENSE.meta", 16 | "/README.md", 17 | "/README.md.meta", 18 | "/package.json", 19 | "/package.json.meta", 20 | "/UiRoundedCorners", 21 | "/UiRoundedCorners.meta" 22 | ] 23 | } 24 | -------------------------------------------------------------------------------- /package.json.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: c81519d75a1f38d4bad36f6d94701365 3 | TextScriptImporter: 4 | externalObjects: {} 5 | userData: 6 | assetBundleName: 7 | assetBundleVariant: 8 | -------------------------------------------------------------------------------- /separate-roundness.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/separate-roundness.gif -------------------------------------------------------------------------------- /separate-roundness.gif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: 48ee6ab80b7092341be0309e858079ba 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 11 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | vTOnly: 0 27 | grayScaleToAlpha: 0 28 | generateCubemap: 6 29 | cubemapConvolution: 0 30 | seamlessCubemap: 0 31 | textureFormat: 1 32 | maxTextureSize: 2048 33 | textureSettings: 34 | serializedVersion: 2 35 | filterMode: 1 36 | aniso: 1 37 | mipBias: 0 38 | wrapU: 0 39 | wrapV: 0 40 | wrapW: 0 41 | nPOTScale: 1 42 | lightmap: 0 43 | compressionQuality: 50 44 | spriteMode: 0 45 | spriteExtrude: 1 46 | spriteMeshType: 1 47 | alignment: 0 48 | spritePivot: {x: 0.5, y: 0.5} 49 | spritePixelsToUnits: 100 50 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 51 | spriteGenerateFallbackPhysicsShape: 1 52 | alphaUsage: 1 53 | alphaIsTransparency: 0 54 | spriteTessellationDetail: -1 55 | textureType: 0 56 | textureShape: 1 57 | singleChannelComponent: 0 58 | flipbookRows: 1 59 | flipbookColumns: 1 60 | maxTextureSizeSet: 0 61 | compressionQualitySet: 0 62 | textureFormatSet: 0 63 | ignorePngGamma: 0 64 | applyGammaDecoding: 0 65 | platformSettings: 66 | - serializedVersion: 3 67 | buildTarget: DefaultTexturePlatform 68 | maxTextureSize: 2048 69 | resizeAlgorithm: 0 70 | textureFormat: -1 71 | textureCompression: 1 72 | compressionQuality: 50 73 | crunchedCompression: 0 74 | allowsAlphaSplitting: 0 75 | overridden: 0 76 | androidETC2FallbackOverride: 0 77 | forceMaximumCompressionQuality_BC6H_BC7: 0 78 | spriteSheet: 79 | serializedVersion: 2 80 | sprites: [] 81 | outline: [] 82 | physicsShape: [] 83 | bones: [] 84 | spriteID: 85 | internalID: 0 86 | vertices: [] 87 | indices: 88 | edges: [] 89 | weights: [] 90 | secondaryTextures: [] 91 | spritePackingTag: 92 | pSDRemoveMatte: 0 93 | pSDShowRemoveMatteOption: 0 94 | userData: 95 | assetBundleName: 96 | assetBundleVariant: 97 | -------------------------------------------------------------------------------- /title.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ReForge-Mode/Unity_UI_Rounded_Corners/0ae398b2cbc24ff46687389c38055a4054a0c63a/title.gif -------------------------------------------------------------------------------- /title.gif.meta: -------------------------------------------------------------------------------- 1 | fileFormatVersion: 2 2 | guid: ab5cf66c25d237c4897de2700b0fc815 3 | TextureImporter: 4 | internalIDToNameTable: [] 5 | externalObjects: {} 6 | serializedVersion: 11 7 | mipmaps: 8 | mipMapMode: 0 9 | enableMipMap: 1 10 | sRGBTexture: 1 11 | linearTexture: 0 12 | fadeOut: 0 13 | borderMipMap: 0 14 | mipMapsPreserveCoverage: 0 15 | alphaTestReferenceValue: 0.5 16 | mipMapFadeDistanceStart: 1 17 | mipMapFadeDistanceEnd: 3 18 | bumpmap: 19 | convertToNormalMap: 0 20 | externalNormalMap: 0 21 | heightScale: 0.25 22 | normalMapFilter: 0 23 | isReadable: 0 24 | streamingMipmaps: 0 25 | streamingMipmapsPriority: 0 26 | vTOnly: 0 27 | grayScaleToAlpha: 0 28 | generateCubemap: 6 29 | cubemapConvolution: 0 30 | seamlessCubemap: 0 31 | textureFormat: 1 32 | maxTextureSize: 2048 33 | textureSettings: 34 | serializedVersion: 2 35 | filterMode: 1 36 | aniso: 1 37 | mipBias: 0 38 | wrapU: 0 39 | wrapV: 0 40 | wrapW: 0 41 | nPOTScale: 1 42 | lightmap: 0 43 | compressionQuality: 50 44 | spriteMode: 0 45 | spriteExtrude: 1 46 | spriteMeshType: 1 47 | alignment: 0 48 | spritePivot: {x: 0.5, y: 0.5} 49 | spritePixelsToUnits: 100 50 | spriteBorder: {x: 0, y: 0, z: 0, w: 0} 51 | spriteGenerateFallbackPhysicsShape: 1 52 | alphaUsage: 1 53 | alphaIsTransparency: 0 54 | spriteTessellationDetail: -1 55 | textureType: 0 56 | textureShape: 1 57 | singleChannelComponent: 0 58 | flipbookRows: 1 59 | flipbookColumns: 1 60 | maxTextureSizeSet: 0 61 | compressionQualitySet: 0 62 | textureFormatSet: 0 63 | ignorePngGamma: 0 64 | applyGammaDecoding: 0 65 | platformSettings: 66 | - serializedVersion: 3 67 | buildTarget: DefaultTexturePlatform 68 | maxTextureSize: 2048 69 | resizeAlgorithm: 0 70 | textureFormat: -1 71 | textureCompression: 1 72 | compressionQuality: 50 73 | crunchedCompression: 0 74 | allowsAlphaSplitting: 0 75 | overridden: 0 76 | androidETC2FallbackOverride: 0 77 | forceMaximumCompressionQuality_BC6H_BC7: 0 78 | spriteSheet: 79 | serializedVersion: 2 80 | sprites: [] 81 | outline: [] 82 | physicsShape: [] 83 | bones: [] 84 | spriteID: 85 | internalID: 0 86 | vertices: [] 87 | indices: 88 | edges: [] 89 | weights: [] 90 | secondaryTextures: [] 91 | spritePackingTag: 92 | pSDRemoveMatte: 0 93 | pSDShowRemoveMatteOption: 0 94 | userData: 95 | assetBundleName: 96 | assetBundleVariant: 97 | --------------------------------------------------------------------------------