|
|
|
|
|
|
//#define NATIVE_CODE_FOR_CMD_CONVERT_TEXTURE
|
|
|
|
|
|
|
|
using UnityEngine; |
|
|
|
using System.Collections.Generic; |
|
|
|
using UnityEngine.Rendering; |
|
|
|
|
|
|
|
|
|
|
if (mismatch) |
|
|
|
{ |
|
|
|
#if NATIVE_CODE_FOR_CMD_CONVERT_TEXTURE
|
|
|
|
} |
|
|
|
#else
|
|
|
|
UnityEngine.Graphics.ConvertTexture(texture, 0, m_Cache, sliceIndex); |
|
|
|
#endif
|
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
cmd.CopyTexture(texture, 0, m_Cache, sliceIndex); |
|
|
|
|
|
|
{ |
|
|
|
for (int f = 0; f < 6; f++) |
|
|
|
{ |
|
|
|
#if NATIVE_CODE_FOR_CMD_CONVERT_TEXTURE
|
|
|
|
#else
|
|
|
|
UnityEngine.Graphics.ConvertTexture(texture, f, m_Cache, 6 * sliceIndex + f); |
|
|
|
#endif
|
|
|
|
} |
|
|
|
} |
|
|
|
else |
|
|
|