本文整理汇总了C#中UnityEngine.Texture.GetNativeTextureID方法的典型用法代码示例。如果您正苦于以下问题:C# Texture.GetNativeTextureID方法的具体用法?C# Texture.GetNativeTextureID怎么用?C# Texture.GetNativeTextureID使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类UnityEngine.Texture
的用法示例。
在下文中一共展示了Texture.GetNativeTextureID方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: WriteOnTexture
public static void WriteOnTexture(Texture textureToWrite, string text, string fontName, DFTAlignment alignment, int fontSize, int width, int height)
{
if(width==0||height==0||fontSize==0)
{
Debug.Log("Please check arguments.");
}
else
{
_writeOnGLTexture(textureToWrite.GetNativeTextureID(),text,fontName,(int)alignment,fontSize,width,height);
}
}
示例2: ReplaceTexture
public bool ReplaceTexture(long movieId, String textureName, Texture texture)
{
int texId;
int rt_with = texture.width;
int rt_height = texture.height;
#if (UNITY_4_0) || (UNITY_4_1)
#if UNITY_IPHONE
texId = texture.GetNativeTextureID();
#else
IntPtr texPtr = texture.GetNativeTexturePtr();
texId = (int)(texPtr);
#endif
#else
texId = texture.GetNativeTextureID();
#endif
return SF_ReplaceTexture(movieId, textureName, texId, rt_with, rt_height);
}