public void PostPhoto(string message, Texture2D texture, Facebook.PostPhotoDelegate callback)
        {
            byte[] bytes     = texture.EncodeToPNG();
            string imagePath = null;

            imagePath = Application.temporaryCachePath + "/PostPhoto.png";
            File.WriteAllBytes(imagePath, bytes);
            int handlerNum = facebookCallback.SetPostPhotoCallback(callback);

            nmg_facebook_postPhoto(message, imagePath, handlerNum);
        }
Exemple #2
0
        public void PostPhoto(string message, Texture2D texture, Facebook.PostPhotoDelegate callback)
        {
            byte[] bytes     = texture.EncodeToPNG();
            string imagePath = null;

            imagePath = Application.persistentDataPath + "/PostPhoto.png";
            File.WriteAllBytes(imagePath, bytes);

            int handlerNum = facebookCallback.SetPostPhotoCallback(callback);

            facebookAndroidClass.CallStatic("nmg_facebook_postPhoto", message, imagePath, handlerNum);
        }