public void BrowseForPath(string image) { Debug.Log("yeh select kiya!!!" + image); imagePath = image; ImageRendering ir2 = new ImageRendering(); Debug.Log(imagePath); ir2.onBrowseForOption(); }
public void openPanel() { #if UNITY_EDITOR imagePath = browseForImage(); ImageRendering ir = new ImageRendering(); Debug.Log(imagePath); ir.onBrowseForOption(); #elif UNITY_STANDALONE_WIN imagePath = browseForImage(); ImageRendering ir = new ImageRendering(); Debug.Log(imagePath); ir.onBrowseForOption(); #else AndroidJavaClass jc = new AndroidJavaClass("com.unity3d.player.UnityPlayer"); AndroidJavaObject currentActivity = jc.GetStatic <AndroidJavaObject>("currentActivity"); string[] obj = { "MainCamera", "BrowseForPath" }; currentActivity.Call("selectImage", obj); #endif }