Commit 8b4a0c33 authored by shujianhe's avatar shujianhe

1 FFmepg 系列so 生成视频可能需要用的库

2 回放场景一些资源和脚本
  2.1 replayeScene.unity
  2.2 imageGradationView.cs 实现纵向渐变色
  2.3 RoundedRectangle.cs 圆角矩形单独脚本
  2.4 rebackListItem.cs 回放下边每个单元格view脚本
3 其他修改
parent 7e08d726
fileFormatVersion: 2
guid: f2ecd7a0e0eead542999710d3149cbdf
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 2e976aaabf3c0fa47a62a58346f0c8c1
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 2a4bfbbbe10f2ad4b856dd5f3445e38e
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: eaf2cbbc76bc8e54fa6030e7ade2fec9
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: fdf482f41a8513e4290374b714e6e34f
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 42cf0bd33b9dbb547aaf33e526609c55
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 072b8872a47cf75479a8ba5e50d4e554
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 9ad10205a885d4848a56500662628a76
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 2d07d95e432306249aecc5f042828853
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARM64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: e3e7628fa20c3c24188f293dd49b35bd
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 484ba8004350c3d429f874be82ee0f34
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: e00888dc590bdd14fa2343f5f4f0e095
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: c29a9f97659fbfb46aebb5a057e83a92
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: c90c1d2e0a5e30b4694049ee0c0ec594
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 8f8a7956040f66e4fb5066eaf5db6cef
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 300f54feb4f64e143b9f825e9bb90890
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 08b1d2a8d60618941991148c3c96d4ac
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: ARMv7
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 32d5bea92e9309e4c825bd51ccd123e7
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: d46490b617ccf6a46913f82c28b529a0
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: f5cdff91b3052cb4ea259519187b22d3
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 85a51992f902e504eaf82b0465c0a32f
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 5262f3fd26ce7204cb0121327e7fc3ee
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: a336b4932b8898b44802eb3b9965ae92
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 77eb24d3165313e4e929db69cb98e320
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: fbb2d7073d22cdd49837105ee62624d8
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: d93b081d68c6a2a46b06467704ff23a5
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 822a53b00b4628f40a29828d2bf8d332
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: e3f64a604d4950045aabe2e4f28695a1
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 0e262d3e1dffba5418044c77bc4711f7
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: f44278b9fb0bca74baa50764d12d589c
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 9f5154561f0c5764ea8a2931e2b54718
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: fd91d30ceddce3a48824320ecbf8fe11
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: cbe76b029d8a64d4baa45c12d68fdc78
PluginImporter:
externalObjects: {}
serializedVersion: 2
iconMap: {}
executionOrder: {}
defineConstraints: []
isPreloaded: 0
isOverridable: 0
isExplicitlyReferenced: 0
validateReferences: 1
platformData:
- first:
Android: Android
second:
enabled: 1
settings:
CPU: x86_64
- first:
Any:
second:
enabled: 0
settings: {}
- first:
Editor: Editor
second:
enabled: 0
settings:
DefaultValueInitialized: true
userData:
assetBundleName:
assetBundleVariant:
fileFormatVersion: 2
guid: 033f05a04a2b9114695e706b06a5142d
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 12
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
flipGreenChannel: 0
isReadable: 1
streamingMipmaps: 0
streamingMipmapsPriority: 0
vTOnly: 0
ignoreMipmapLimit: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: 1
aniso: 1
mipBias: 0
wrapU: 1
wrapV: 1
wrapW: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 1
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 8
textureShape: 1
singleChannelComponent: 0
flipbookRows: 1
flipbookColumns: 1
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
ignorePngGamma: 0
applyGammaDecoding: 0
swizzle: 50462976
cookieLightType: 0
platformSettings:
- serializedVersion: 3
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: 4
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Server
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
- serializedVersion: 3
buildTarget: Android
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
ignorePlatformSupport: 0
androidETC2FallbackOverride: 0
forceMaximumCompressionQuality_BC6H_BC7: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID: 5e97eb03825dee720800000000000000
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
nameFileIdTable: {}
mipmapLimitGroupName:
pSDRemoveMatte: 0
userData:
assetBundleName:
assetBundleVariant:
%YAML 1.1
%TAG !u! tag:unity3d.com,2011:
--- !u!1 &4697020134824317878
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 2937145161122389622}
- component: {fileID: 5559813884590556731}
- component: {fileID: 866991545107153783}
m_Layer: 0
m_Name: value
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &2937145161122389622
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4697020134824317878}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1.02, y: 1.02, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 8686242135328704408}
m_RootOrder: -1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 164, y: 164}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &5559813884590556731
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4697020134824317878}
m_CullTransparentMesh: 1
--- !u!114 &866991545107153783
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 4697020134824317878}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 0}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!1 &8380187509682476985
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 8686242135328704408}
- component: {fileID: 2826311056452163961}
- component: {fileID: 8120092103548944842}
- component: {fileID: 835790342653870209}
- component: {fileID: 8150993739938574315}
- component: {fileID: 5068841195549745823}
m_Layer: 0
m_Name: rebackListCell
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!224 &8686242135328704408
RectTransform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8380187509682476985}
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children:
- {fileID: 2937145161122389622}
m_Father: {fileID: 0}
m_RootOrder: -1
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
m_AnchorMin: {x: 0.5, y: 0.5}
m_AnchorMax: {x: 0.5, y: 0.5}
m_AnchoredPosition: {x: 0, y: 0}
m_SizeDelta: {x: 164, y: 164}
m_Pivot: {x: 0.5, y: 0.5}
--- !u!222 &2826311056452163961
CanvasRenderer:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8380187509682476985}
m_CullTransparentMesh: 1
--- !u!114 &8120092103548944842
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8380187509682476985}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: fe87c0e1cc204ed48ad3b37840f39efc, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Material: {fileID: 0}
m_Color: {r: 1, g: 1, b: 1, a: 1}
m_RaycastTarget: 1
m_RaycastPadding: {x: 0, y: 0, z: 0, w: 0}
m_Maskable: 1
m_OnCullStateChanged:
m_PersistentCalls:
m_Calls: []
m_Sprite: {fileID: 21300000, guid: 033f05a04a2b9114695e706b06a5142d, type: 3}
m_Type: 0
m_PreserveAspect: 0
m_FillCenter: 1
m_FillMethod: 4
m_FillAmount: 1
m_FillClockwise: 1
m_FillOrigin: 0
m_UseSpriteMesh: 0
m_PixelsPerUnitMultiplier: 1
--- !u!114 &835790342653870209
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8380187509682476985}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 3312d7739989d2b4e91e6319e9a96d76, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Padding: {x: 0, y: 0, z: 0, w: 0}
m_Softness: {x: 0, y: 0}
--- !u!114 &8150993739938574315
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8380187509682476985}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 6994091b4d264ce449ba0404579ea9e0, type: 3}
m_Name:
m_EditorClassIdentifier:
value: {fileID: 4697020134824317878}
showColorValue: {r: 0.5647059, g: 0.26666668, b: 0.8862746, a: 1}
imageid:
listId: -1
--- !u!114 &5068841195549745823
MonoBehaviour:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 8380187509682476985}
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 4e29b1a8efbd4b44bb3f3716e73f07ff, type: 3}
m_Name:
m_EditorClassIdentifier:
m_Navigation:
m_Mode: 3
m_WrapAround: 0
m_SelectOnUp: {fileID: 0}
m_SelectOnDown: {fileID: 0}
m_SelectOnLeft: {fileID: 0}
m_SelectOnRight: {fileID: 0}
m_Transition: 0
m_Colors:
m_NormalColor: {r: 1, g: 1, b: 1, a: 1}
m_HighlightedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_PressedColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 1}
m_SelectedColor: {r: 0.9607843, g: 0.9607843, b: 0.9607843, a: 1}
m_DisabledColor: {r: 0.78431374, g: 0.78431374, b: 0.78431374, a: 0.5019608}
m_ColorMultiplier: 1
m_FadeDuration: 0.1
m_SpriteState:
m_HighlightedSprite: {fileID: 0}
m_PressedSprite: {fileID: 0}
m_SelectedSprite: {fileID: 0}
m_DisabledSprite: {fileID: 0}
m_AnimationTriggers:
m_NormalTrigger: Normal
m_HighlightedTrigger: Highlighted
m_PressedTrigger: Pressed
m_SelectedTrigger: Selected
m_DisabledTrigger: Disabled
m_Interactable: 1
m_TargetGraphic: {fileID: 8120092103548944842}
m_OnClick:
m_PersistentCalls:
m_Calls:
- m_Target: {fileID: 8150993739938574315}
m_TargetAssemblyTypeName: rebackListItem, Assembly-CSharp
m_MethodName: onClickHandler
m_Mode: 1
m_Arguments:
m_ObjectArgument: {fileID: 0}
m_ObjectArgumentAssemblyTypeName: UnityEngine.Object, UnityEngine
m_IntArgument: 0
m_FloatArgument: 0
m_StringArgument:
m_BoolArgument: 0
m_CallState: 2
fileFormatVersion: 2
guid: 550266744ff61be4bb06e09bd412b2fa
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:
This diff is collapsed.
...@@ -102,6 +102,7 @@ public class GameScenUserInfo ...@@ -102,6 +102,7 @@ public class GameScenUserInfo
Dictionary<short, bool> existIds = new Dictionary<short, bool>(); Dictionary<short, bool> existIds = new Dictionary<short, bool>();
foreach (var item in areaInfoUseData) foreach (var item in areaInfoUseData)
{ {
if(existIds.ContainsKey(item.id) == false)
existIds.Add(item.id, true); existIds.Add(item.id, true);
} }
for (int i = 0; i < ids.Count(); i++) for (int i = 0; i < ids.Count(); i++)
......
...@@ -48,7 +48,7 @@ public class gameSceneLogic : MonoBehaviour, IEventHandler ...@@ -48,7 +48,7 @@ public class gameSceneLogic : MonoBehaviour, IEventHandler
dtime = DateTime.Now; dtime = DateTime.Now;
if (utilsTools.ContainsKeyGDataByKey("urlRoot") == false) if (utilsTools.ContainsKeyGDataByKey("urlRoot") == false)
{ {
utilsTools.setGDataByKey("urlRoot", "http://8.218.187.222:19897");// "http://8.218.187.222:19897"); utilsTools.setGDataByKey("urlRoot", "http://8.218.187.222:19897");
} }
//Application.SetStackTraceLogType(LogType.Log, StackTraceLogType.None); //Application.SetStackTraceLogType(LogType.Log, StackTraceLogType.None);
...@@ -564,12 +564,12 @@ public class gameSceneLogic : MonoBehaviour, IEventHandler ...@@ -564,12 +564,12 @@ public class gameSceneLogic : MonoBehaviour, IEventHandler
public void onCloseGameSceneEvent(List<UnityEngine.Object> uobjects, List<System.Object> objects) public void onCloseGameSceneEvent(List<UnityEngine.Object> uobjects, List<System.Object> objects)
{ {
Debug.Log("准备关闭"); Debug.Log("准备关闭");
utilsTools.setGDataByKey("NativeTempData", "main");
utilsTools.sendEvent("CloseScenePrve"); utilsTools.sendEvent("CloseScenePrve");
utilsTools.addTimer_Update(gameObject, "close", (String name) => utilsTools.addTimer_Update(gameObject, "close", (String name) =>
{ {
Debug.Log("关闭"); Debug.Log("关闭");
gameShowView.GetComponent<mainGameView>().onClear(); gameShowView.GetComponent<mainGameView>().onClear();
utilsTools.setGDataByKey("NativeTempData", "main");
SceneManager.LoadScene("Scenes/MainGame"); SceneManager.LoadScene("Scenes/MainGame");
return false; return false;
}, 40); }, 40);
......
...@@ -38,12 +38,12 @@ public class gameUserInfos : MonoBehaviour, IEventHandler ...@@ -38,12 +38,12 @@ public class gameUserInfos : MonoBehaviour, IEventHandler
} }
utilsTools.setGDataByKey("imgId", jsonData.sid.ToString()); utilsTools.setGDataByKey("imgId", jsonData.sid.ToString());
utilsTools.setGameScenUserInfo(jsonData.id, jsonData.getLineUrl(), jsonData.getColorUrl(), jsonData.getJsonUrl(), jsonData.file); utilsTools.setGameScenUserInfo(jsonData.id, jsonData.getLineUrl(), jsonData.getColorUrl(), jsonData.getJsonUrl(), jsonData.file);
startId(jsonData.id,jsonData);
utilsTools.httpGET(this, "{0}/app/v1/game/ts/imgSchedule?zygt=hzwz&tgtk=1&imgId={1}&uid={2}", true, (string id, string url, bool isSuccess, System.Object data) => utilsTools.httpGET(this, "{0}/app/v1/game/ts/imgSchedule?zygt=hzwz&tgtk=1&imgId={1}&uid={2}", true, (string id, string url, bool isSuccess, System.Object data) =>
{ {
if(isSuccess) if(isSuccess)
{ {
HistoryClick historyClick = JsonUtility.FromJson<HistoryClick>(data as string); HistoryClick historyClick = JsonUtility.FromJson<HistoryClick>(data as string);
utilsTools.sendEvent("updateSchedules");
if (historyClick == null) return 0; if (historyClick == null) return 0;
string history = historyClick.getHistory(); string history = historyClick.getHistory();
gameScenUserInfo.setShowAreaids(history); gameScenUserInfo.setShowAreaids(history);
...@@ -54,6 +54,13 @@ public class gameUserInfos : MonoBehaviour, IEventHandler ...@@ -54,6 +54,13 @@ public class gameUserInfos : MonoBehaviour, IEventHandler
return 1; return 1;
} }
},utilsTools.getGDataByKey<String>("urlRoot",""),jsonData.sid,utilsTools.getGDataByKey<String>("uid","123456")); },utilsTools.getGDataByKey<String>("urlRoot",""),jsonData.sid,utilsTools.getGDataByKey<String>("uid","123456"));
//让上边的获取进度url先走,防止界面已经显示但是进度网络波动出现无法显示老的值
utilsTools.addTimer_Update(gameObject, "wait5fps", (String n) =>
{
startId(jsonData.id, jsonData);
return false;
}, 5);
} }
return false; return false;
}, 2); }, 2);
...@@ -157,6 +164,9 @@ public class gameUserInfos : MonoBehaviour, IEventHandler ...@@ -157,6 +164,9 @@ public class gameUserInfos : MonoBehaviour, IEventHandler
int schedule = 0; int schedule = 0;
if (schedule1 < 1.00001) if (schedule1 < 1.00001)
{ {
if (allAreaSize < 1)
schedule = 0;
else
schedule = 1; schedule = 1;
} }
else if (schedule1 > 98.999999991) else if (schedule1 > 98.999999991)
......
...@@ -17,11 +17,12 @@ public class Native : MonoBehaviour ...@@ -17,11 +17,12 @@ public class Native : MonoBehaviour
{ {
string param = utilsTools.getGDataByKey<string>("NativeTempData", "splash"); string param = utilsTools.getGDataByKey<string>("NativeTempData", "splash");
showHostMainWindow(param); showHostMainWindow(param);
utilsTools.addTimer_Sec(gameObject, "dsfds", (String name) => //utilsTools.addTimer_Sec(gameObject, "dsfds", (String name) =>
{ //{
jumpGame(""); // utilsTools.setGDataByKey("NativeTempData", "test");
return false; // jumpGame("");
}, 1); // return false;
//}, 1);
Debug.Log("UnityStart"); Debug.Log("UnityStart");
} }
private void OnEnable() private void OnEnable()
......
using System;
using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting;
using UnityEngine;
using UnityEngine.UI;
public class RoundedRectangle : MonoBehaviour
{
public Color color = new Color(1f, 1f, 1f,1f);
public int r = 20;
private bool isInit = false;
private GameScenUserInfo gameScenUserInfo = null;
void Start()
{
initMember();
}
public void initMember()
{
if(isInit == false)
{
isInit = true;
RectTransform rectTransform = GetComponent<RectTransform>();
Texture2D texture2D = new Texture2D((int)rectTransform.rect.width, (int)rectTransform.rect.height, TextureFormat.RGBA32, false);
Image image = GetComponent<Image>();
if (image == null)
{
image = gameObject.AddComponent<Image>();
}
Color[] allColor = new Color[texture2D.width * texture2D.height];
for (int x = 0; x < texture2D.width; x++)
{
for (int y = 0; y < texture2D.height; y++)
{
int offset = y * texture2D.width + x;
allColor[offset] = color;
}
}
utilsTools.checkResetYuanJiao(allColor, texture2D.width, texture2D.height, r);
texture2D.SetPixels(allColor);
texture2D.Apply();
image.sprite = Sprite.Create(texture2D, new Rect(0, 0, texture2D.width, texture2D.height), new Vector2(0.5f, 0.5f));
}
}
public void resetSize(Vector2 size)
{
isInit = false;
Image image = GetComponent<Image>();
Destroy(image.sprite);
RectTransform rectTransform = GetComponent<RectTransform>();
rectTransform.sizeDelta = new Vector2(size.x, size.y);
initMember();
}
// Update is called once per frame
void Update()
{
initMember();
}
}
fileFormatVersion: 2
guid: 928e9020a18ea86408d69b795f43462b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting;
using UnityEngine;
using UnityEngine.UI;
public class imageGradationView : MonoBehaviour
{
public Color color1 = Color.black;
public Color color2 = Color.white;
// Start is called before the first frame update
private Color[] allColor = null;
private Texture2D texture2D = null;
private int angle = 90;//仅支持90# 0 左到右 180 右到左 90 上到下 270 下到上,其他方向暂时不支持
void Start()
{
initMember();
}
void initMember()
{
if(allColor != null)
{
return;
}
RectTransform rectTransform = GetComponent<RectTransform>();
texture2D = new Texture2D((int)rectTransform.rect.width,(int)rectTransform.rect.height,TextureFormat.RGBA32,false);
Image image = GetComponent<Image>();
if(image == null)
{
image = gameObject.AddComponent<Image>();
}
image.sprite = image.sprite = Sprite.Create(texture2D, new Rect(0, 0, texture2D.width, texture2D.height), new Vector2(0.5f, 0.5f));
allColor = new Color[texture2D.width * texture2D.height]; //texture2D.GetPixels();
updateImageView();
texture2D.SetPixels(allColor);
texture2D.Apply();
}
void updateImageView()
{
if (angle.Equals(90))
{
float height = texture2D.height;
float[] diffValue = { (color1.r - color2.r)/height, (color1.g - color2.g) / height , (color1.b - color2.b) / height , (color1.a - color2.a) / height };
for (int y = 0; y < texture2D.height; y++)
{
Color lineColor = new Color(color2.r + diffValue[0] * y, color2.g + diffValue[1] * y, color2.b + diffValue[2] * y, color2.a + diffValue[3] * y);
for(int x = 0;x < texture2D.width; x++)
{
int idx = y * texture2D.width + x;
allColor[idx] = lineColor;
}
}
}
}
// Update is called once per frame
void Update()
{
initMember();
}
}
fileFormatVersion: 2
guid: d612bbffc9c2c60499a56dc091ec528c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
...@@ -35,9 +35,9 @@ public class mainGameView : MonoBehaviour ...@@ -35,9 +35,9 @@ public class mainGameView : MonoBehaviour
private bool thumbnailIsChange = false; private bool thumbnailIsChange = false;
private string[] initDigitMatrixs = { "", "","" }; private string[] initDigitMatrixs = { "", "","" };
protected Dictionary<short, short> aid2selectOrderIdx = new Dictionary<short, short>(); protected Dictionary<short, short> aid2selectOrderIdx = new Dictionary<short, short>();
private GameScenUserInfo gameScenUseInfo = null; protected GameScenUserInfo gameScenUseInfo = null;
//x,y aid 当前帧向量 起点终点 等宽度计算扩散 //x,y aid 当前帧向量 起点终点 等宽度计算扩散
private List<AreaAnimationDiffuse> showAreaAnimationDatas = new List<AreaAnimationDiffuse>(); protected List<AreaAnimationDiffuse> showAreaAnimationDatas = new List<AreaAnimationDiffuse>();
protected Dictionary<short, GroupByAreaPtInfos> groupPtInfos = new Dictionary<short, GroupByAreaPtInfos>(); protected Dictionary<short, GroupByAreaPtInfos> groupPtInfos = new Dictionary<short, GroupByAreaPtInfos>();
protected Dictionary<short, GroupByAreaPtInfos> groupPtInfos_All = new Dictionary<short, GroupByAreaPtInfos>();//不管是否涂色都会记录 protected Dictionary<short, GroupByAreaPtInfos> groupPtInfos_All = new Dictionary<short, GroupByAreaPtInfos>();//不管是否涂色都会记录
protected short bianlun = -1; protected short bianlun = -1;
...@@ -982,7 +982,7 @@ public class mainGameView : MonoBehaviour ...@@ -982,7 +982,7 @@ public class mainGameView : MonoBehaviour
} }
return ret; return ret;
} }
void onShowAreaByNoAnimation(short aid) protected virtual void onShowAreaByNoAnimation(short aid)
{ {
int cout = GroupByAreaPtInfos.mapAllDatas[aid].Count; int cout = GroupByAreaPtInfos.mapAllDatas[aid].Count;
var pts = GroupByAreaPtInfos.mapAllDatas[aid]; var pts = GroupByAreaPtInfos.mapAllDatas[aid];
...@@ -993,7 +993,7 @@ public class mainGameView : MonoBehaviour ...@@ -993,7 +993,7 @@ public class mainGameView : MonoBehaviour
{ {
int value = pts[i]; int value = pts[i];
short x = (short)(value % gameidJsondata.width); short x = (short)(value % gameidJsondata.width);
short y = (short)(value / gameidJsondata.width); short y = (short)(value / gameidJsondata.height);
digitMatrix.Data[x, y] = fullShow; digitMatrix.Data[x, y] = fullShow;
line[value].a = 0; line[value].a = 0;
low[value].a = 0; low[value].a = 0;
...@@ -1120,7 +1120,7 @@ public class mainGameView : MonoBehaviour ...@@ -1120,7 +1120,7 @@ public class mainGameView : MonoBehaviour
{ {
TaskManages.getInstance().updateTask(this); TaskManages.getInstance().updateTask(this);
} }
void onShowAnimationHandler() protected virtual void onShowAnimationHandler()
{ {
if(showAreaAnimationDatas.Count > 0) if(showAreaAnimationDatas.Count > 0)
...@@ -1226,7 +1226,7 @@ public class mainGameView : MonoBehaviour ...@@ -1226,7 +1226,7 @@ public class mainGameView : MonoBehaviour
} }
} }
} }
void drawThumbnailByAid(List<short> aids) protected virtual void drawThumbnailByAid(List<short> aids)
{ {
if (false) if (false)
{ {
......
using System.Collections;
using System.Collections.Generic;
using Unity.VisualScripting;
using UnityEngine;
using UnityEngine.UI;
public class rebackListItem : MonoBehaviour
{
//public Texture2D StyleImage;
public GameObject value;
private static Color[] allColors = null;
private static int width = 0;
private static int height = 0;
bool isInit = false;
private bool valueIsFirst = true;
public Color showColorValue = Color.white;
public string imageid = "";
public int listId = -1;
// Start is called before the first frame update
void Start()
{
initMember();
}
void initMember()
{
if(isInit == false)
{
isInit = true;
if(allColors == null)
{
Texture2D texture2D = GetComponent<Image>().sprite.texture;
allColors = texture2D.GetPixels();
width = texture2D.width;
height = texture2D.height;
}
string path = utilsTools.getWritableByPath("gameData/cc_4mMEugNomv_ytuQ_pictureColorThn4.jpg");
utilsTools.loadLocalImage(this, path, (string id, string url, bool isSuccess, System.Object data) =>
{
if (isSuccess)
{
Texture2D texture2D = data as Texture2D;
setData(texture2D);
}
return 0;
});
}
}
public void setData(Texture2D texture2d)
{
Image image = value.GetComponent<Image>();
if(image != null)
{
if(valueIsFirst == false)
{
Destroy(image.sprite);
}
valueIsFirst = false;
int width1 = texture2d.width;
int height1 = texture2d.height;
if(width1 < width)
{
float bet = (width / (float)width1);
var temp = utilsTools.ScaleTexture(texture2d, width, (int)(height1 * bet));
Destroy(texture2d);
setData(temp);
return;
}
int startY = height1 / 2 - height / 2;
if(width1.Equals(height1) == false)
{
startY = height1 - height - height1 / 10;
}
Color[] nowTextureColors = texture2d.GetPixels(width1 / 2 - width / 2, startY, width, height);
Texture2D texture2d1 = new Texture2D(width, height,TextureFormat.RGBA32,false);
Color[] nowText001 = texture2d1.GetPixels();
Color delColor = new Color(0, 0, 0, 0);
//ë?
for (int x1 = 0; x1 < width; x1++)
{
for (int y1 = 0; y1 < height; y1++)
{
int idx = y1 * width + x1;
Color color = allColors[idx];
bool isDel = false;
if(color.Equals(showColorValue) == false || color.a.Equals(0))
{
isDel = true;
}
else if(color.a > 0.2f)
{
if(x1 > 0 && x1 < (width - 1))
{
if(y1 > 0 && y1 < (height - 1))
{
Color color1 = allColors[y1 * width + x1 + 1];
if (color1.Equals(showColorValue) == false || color1.a.Equals(0)) isDel = true;
color1 = allColors[y1 * width + x1 - 1];
if (color1.Equals(showColorValue) == false || color1.a.Equals(0)) isDel = true;
color1 = allColors[y1 * width + width + x1 ];
if (color1.Equals(showColorValue) == false || color1.a.Equals(0)) isDel = true;
color1 = allColors[y1 * width - width + x1];
if (color1.Equals(showColorValue) == false || color1.a.Equals(0)) isDel = true;
}
}
}
if(isDel == true)
{
nowText001[idx] = delColor;
}
else
{
Color color1 = nowTextureColors[idx];
color1.a = 1f;
nowText001[idx] = color1;
}
}
}
Destroy(texture2d);
texture2d1.SetPixels(nowText001);
image.sprite = Sprite.Create(texture2d1, new Rect(0, 0, texture2d1.width, texture2d1.height), new Vector2(0.5f, 0.5f));
texture2d1.Apply();
}
}
public void onClickHandler()
{
//string path = utilsTools.getWritableByPath("gameData/cc_4mMEugNomv_ytuQ_pictureColorThn4.jpg");
//utilsTools.loadLocalImage(this, path, (string id, string url, bool isSuccess, System.Object data) =>
//{
// if (isSuccess)
// {
// Texture2D texture2D = data as Texture2D;
// setData(texture2D);
// }
// return 0;
//});
utilsTools.sendEventObjectParams("rebackListItemClick", imageid, listId);
}
// Update is called once per frame
void Update()
{
}
}
fileFormatVersion: 2
guid: 6994091b4d264ce449ba0404579ea9e0
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:
...@@ -107,19 +107,26 @@ public class colorItem : MonoBehaviour ...@@ -107,19 +107,26 @@ public class colorItem : MonoBehaviour
float s; float s;
float v; float v;
Color.RGBToHSV(useColor, out h, out s, out v); Color.RGBToHSV(useColor, out h, out s, out v);
if (v > 0.6) v = v * 100;
s = s * 100;
if(v < 75)
{ {
v = v - 0.5f; v = v + 20;
} }
else if(v < 0.45f) else
{ {
v = v + 0.5f; v = v - 4;
if(s < 75)
{
s = s + 20;
} }
else else
{ {
v = v - v / 3; s = s - 10;
}
} }
s = s / 100f;
v = v / 100f;
Color color1 = Color.HSVToRGB(h, s, v); Color color1 = Color.HSVToRGB(h, s, v);
effectImg.color2 = color1; effectImg.color2 = color1;
effectImg.color1 = useColor; effectImg.color1 = useColor;
......
...@@ -2,6 +2,8 @@ using System.IO; ...@@ -2,6 +2,8 @@ using System.IO;
using System.Collections; using System.Collections;
using UnityEngine; using UnityEngine;
using ICSharpCode.SharpZipLib.Zip; using ICSharpCode.SharpZipLib.Zip;
using UnityEngine.Networking;
public static class ZipUtility public static class ZipUtility
{ {
#region ZipCallback #region ZipCallback
...@@ -304,4 +306,47 @@ public static class ZipUtility ...@@ -304,4 +306,47 @@ public static class ZipUtility
_zipCallback.OnPostZip(entry); _zipCallback.OnPostZip(entry);
return true; return true;
} }
//如果本地存在zip就解压否则下载后解压
public static void unzipFileUrl(string url,string zippath,string outpath,MonoBehaviour monoBehaviour, NotifyBoolParam notifyBoolParam,string pass = "")
{
if(utilsTools.IsExistIO(zippath) == false)
{
monoBehaviour.StartCoroutine(LoadAndBytesUnzipWithWeb(url, zippath, (bool isOk) =>
{
if (isOk == false)
{
notifyBoolParam(false);
}else
{
if(pass.Equals(""))
ZipUtility.UnzipFile(zippath, outpath);
else
ZipUtility.UnzipFile(zippath, outpath, pass);
}
}));
}
}
static public IEnumerator LoadAndBytesUnzipWithWeb(string url, string exportPath, NotifyBoolParam back)
{
Debug.Log("exportPath : " + exportPath);
using (UnityWebRequest uwr = UnityWebRequest.Get(url))
{
yield return uwr.SendWebRequest();
if (uwr.isHttpError == true || uwr.isNetworkError == true)
{
Debug.Log("www.error : " + uwr.error);
back(false);
}
else if (uwr.isDone == true)
{
var data = uwr.downloadHandler.data;
File.WriteAllBytes(exportPath, data);
back(true);
}
}
}
} }
...@@ -41,6 +41,15 @@ public class Vector2Short ...@@ -41,6 +41,15 @@ public class Vector2Short
{ {
public short x; public short x;
public short y; public short y;
public float fx
{
get { float x1 = x;return x1; }
}
public float fy
{
get { float y1 = y; return y1; }
}
public Vector2Short(short x, short y) public Vector2Short(short x, short y)
{ {
this.x = x; this.x = x;
......
...@@ -266,31 +266,69 @@ public class utilsTools ...@@ -266,31 +266,69 @@ public class utilsTools
} }
return cout; return cout;
} }
public static int checkResetYuanJiao(Color[] colors, int width, int height,int minR) { public static void TextureJpg2Png(Texture2D jpgTexture, out Texture2D pngTexture2d,int width = -1,int height = -1)
{
if (width < 0) width = jpgTexture.width;
if(height < 0) height = jpgTexture.height;
pngTexture2d = new Texture2D(width,height, TextureFormat.RGBA32, false);
Color[] allColorJpg = jpgTexture.GetPixels();
Color[] allColorPng = new Color[width * height];
for (int i = 0; i < width; i++)
{
int x1 = (int)(((float)i / (float)width) * jpgTexture.width);
for (int j = 0; j < height; j++)
{
int idx = j * width + i;
int y1 = (int)(((float)j / (float)height) * jpgTexture.height);
Color color = allColorJpg[y1 * jpgTexture.width + x1];
color.a = 1f;
allColorPng[idx] = color;
}
}
pngTexture2d.SetPixels(allColorPng);
return;
}
public static int checkResetYuanJiao(Color[] colors, int width, int height,int minR,int offsetX = 0,int offsetY = 0) {
//检查四个角落是否透明 //检查四个角落是否透明
int rFang = minR * minR; int rFang = minR * minR;
int count = 0; int count = 0;
int x = 0; int x = 0;
int y = 0; int y = 0;
int idx = 0; int idx = 0;
for (int i = 0; i < offsetX; i++)
{
for(int j = 0; j < height; j++)
{
colors[j * width + i].a = 0;
colors[j * width + width - i - 1].a = 0;
}
}
for (int i = 0;i < width; i++)
{
for(int j = 0; j < offsetY; j++)
{
colors[j * width + i].a = 0;
colors[(height - j - 1) * width + i].a = 0;
}
}
for (int i = 0;i < minR; i++) for (int i = 0;i < minR; i++)
{ {
int iFang = (minR - i) * (minR - i); int iFang = (minR - i) * (minR - i);
for(int j = 0;j < minR; j++) for(int j = 0;j < minR; j++)
{ {
if(iFang + (minR - j) * (minR - j) > rFang)//超出⚪范围 if(iFang + (minR - j) * (minR - j) > rFang)//超出⚪范围
{ {
x = i; x = i + offsetX;
y = j; y = j + offsetY;
idx = y * width + x; idx = y * width + x;
if(colors[idx].a != 0) if(colors[idx].a != 0)
{ {
colors[idx].a = 0; colors[idx].a = 0;
count++; count++;
} }
x = width - i-1; x = width - i-1 - offsetX;
y = height - j-1; y = height - j-1 - offsetY;
idx = y * width + x; idx = y * width + x;
if (colors[idx].a != 0) if (colors[idx].a != 0)
{ {
...@@ -298,8 +336,8 @@ public class utilsTools ...@@ -298,8 +336,8 @@ public class utilsTools
count++; count++;
} }
x = i; x = i + offsetX;
y = height - j-1; y = height - j - 1 - offsetY;
idx = y * width + x; idx = y * width + x;
if (colors[idx].a != 0) if (colors[idx].a != 0)
{ {
...@@ -307,8 +345,8 @@ public class utilsTools ...@@ -307,8 +345,8 @@ public class utilsTools
count++; count++;
} }
x = width - i-1; x = width - i-1 - offsetX;
y = j; y = j + offsetY;
idx = y * width + x; idx = y * width + x;
if (colors[idx].a != 0) if (colors[idx].a != 0)
{ {
...@@ -378,14 +416,18 @@ public class utilsTools ...@@ -378,14 +416,18 @@ public class utilsTools
} }
netProxy.GET(urlFormat, isText, back, objects); netProxy.GET(urlFormat, isText, back, objects);
} }
public static void loadLocalImage(MonoBehaviour monoBehaviour,Image image,string locapath, LoadImageInfo back = null) public static void loadLocalImage(MonoBehaviour monoBehaviour,string locapath, onUrlBackHandler back = null)
{ {
nodeNetProxy netProxy = monoBehaviour.GetComponent<nodeNetProxy>(); nodeNetProxy netProxy = monoBehaviour.GetComponent<nodeNetProxy>();
if (netProxy == null) if (netProxy == null)
{ {
netProxy = monoBehaviour.gameObject.AddComponent<nodeNetProxy>(); netProxy = monoBehaviour.gameObject.AddComponent<nodeNetProxy>();
} }
netProxy.DOWNIMG("", locapath, (string id, string url, bool isSuccess, System.Object data) => { netProxy.DOWNIMG("", locapath, back);
}
public static void loadLocalImage(MonoBehaviour monoBehaviour,Image image,string locapath, LoadImageInfo back = null)
{
loadLocalImage(monoBehaviour,locapath, (string id, string url, bool isSuccess, System.Object data) => {
if(isSuccess == false) if(isSuccess == false)
{ {
if(back != null) if(back != null)
...@@ -597,7 +639,7 @@ public class utilsTools ...@@ -597,7 +639,7 @@ public class utilsTools
{ {
Color newColor = source.GetPixelBilinear((float)j / (float)result.width, (float)i / (float)result.height); Color newColor = source.GetPixelBilinear((float)j / (float)result.width, (float)i / (float)result.height);
//result.SetPixel(j, i, newColor); //result.SetPixel(j, i, newColor);
colors[i * targetWidth + i] = newColor; colors[i * targetWidth + j] = newColor;
} }
} }
result.SetPixels(0, 0, targetWidth, targetHeight, colors); result.SetPixels(0, 0, targetWidth, targetHeight, colors);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment