Skip to content

Need help with web view content #694

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
TunTin opened this issue Jun 1, 2021 · 74 comments
Open

Need help with web view content #694

TunTin opened this issue Jun 1, 2021 · 74 comments

Comments

@TunTin
Copy link

TunTin commented Jun 1, 2021

Currently I have 1 problem: I need to add an image to the content of the web view so that when zooming the web view, that image is also zoomed, please help me, thanks
Zoomed
Normal

@KojiNakamaru
Copy link
Member

It seems rather an issue about html and not webview. How do you add an image to your content?

@TunTin
Copy link
Author

TunTin commented Jun 2, 2021

I use WebView just to load an SVG file that exists in the Local Device.
I have a PDNoteNode class that inherits from the UIImageView class (this is the Image I want to add to the WebView): see Img_1.png.
Img_1

In the PDViewNote class that inherits from the WKWebView class I have a property of type UIView named contentView: see Img_2.png.
Img_2

In the constructor of the PDViewNote class I will have the contentView property point to the scrollView.subviews.firstObject of the PDViewNote (which is also the WKWebView): see Img_3.png.
Img_3

As a result, when I add Image (which is PDNoteNode) to contentView, My Image will have the same effect as SVG file, when I zoom WKWebView, SVG file and Dark's Image are zoomed along: see Img_4.png.
Img_4

Can you help me to do the same with WebView on Unity?, thanks.

@KojiNakamaru
Copy link
Member

Is your implementation based on this plugin? It seems different one.

Also, if you need to place small images over the svg, I think it is better to add them as html elements. Then you won't need to worry about zooming. For example, thhe sample app of this plugin with the following diff shows a small image at (20, 30) as below.

diff --git a/sample/Assets/Scripts/SampleWebView.cs b/sample/Assets/Scripts/SampleWebView.cs
index d4fd613..05a1bd6 100644
--- a/sample/Assets/Scripts/SampleWebView.cs
+++ b/sample/Assets/Scripts/SampleWebView.cs
@@ -108,6 +108,7 @@ public class SampleWebView : MonoBehaviour
                     "};");
 #endif
                 webViewObject.EvaluateJS(@"Unity.call('ua=' + navigator.userAgent)");
+                webViewObject.EvaluateJS(@"PutSmallImage(20, 30)");
             },
             //transparent: false,
             //zoom: true,
diff --git a/sample/Assets/StreamingAssets/sample.js b/sample/Assets/StreamingAssets/sample.js
index 8dc3fc4..1892ac2 100644
--- a/sample/Assets/StreamingAssets/sample.js
+++ b/sample/Assets/StreamingAssets/sample.js
@@ -9,4 +9,15 @@ window.addEventListener(
                 msg.textContent = '(NOTE: the background color was changed by sample.js, for checking whether the external js code works)';
             },
             3000);
+        window.PutSmallImage = function(x, y) {
+            Unity.call("here");
+            var img = document.createElement('img');
+            img.src = "sample.jpg";
+            img.width = 32;
+            img.height = 32;
+            img.style.position = "absolute";
+            img.style.left = x + "px";
+            img.style.top = y + "px";
+            document.body.appendChild(img);
+        };
     });

image

@TunTin
Copy link
Author

TunTin commented Jun 3, 2021

Thank you very much for your solution, but can you tell me more if I use your plan, can I move that thumbnail to another location or delete it because my application is written in Objective-C iOS has those functions, thank you very much

@KojiNakamaru
Copy link
Member

If you use unity-webview, you can utilize EvaluateJS() to evaluate any javascript code, so that you can dynamically add/move/delete images. If you don't utilize unity-webview and implement your app with objc, you can utilize https://developer.apple.com/documentation/webkit/wkwebview/1415017-evaluatejavascript?language=objc .

@TunTin
Copy link
Author

TunTin commented Jun 3, 2021

Great, I will try your solution and give feedback later, many thanks

@TunTin
Copy link
Author

TunTin commented Jun 3, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jun 16, 2021

Currently I have 1 problem as follows: I need to catch click event on WebView with code like below, please see image below but I can't do it, do you have any solution to help me , thank you

image

@KojiNakamaru
Copy link
Member

This plugin just overlays native webviews over unity's rendering view, so any click on webviews cannot be directly detected by unity (cf. NOTE described at https://github.com/gree/unity-webview/tree/ed0ceef5a366b1185da49ef4ec50088b2a3516e2#unity-webview ). Therefore, you should receive click events with javascript and send information of them to the unity side with Unity.call(). The following might be helpful:

#693 (comment)

@TunTin
Copy link
Author

TunTin commented Jun 17, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jun 18, 2021

I catch click event on WebView as follows:
image
I catch Unity.call('clicked') as follows:
image
My Clicked function is as follows:
image
But when I click on WebView my Clicked function is not run, and how I get the click coordinates, is it the evt parameter of function(evt), Can you help me to solve it, thanks

@KojiNakamaru
Copy link
Member

Maybe you did something wrong. The following change for the sample app works correctly. Please also refer https://www.w3schools.com/jsref/obj_mouseevent.asp about events.

diff --git a/sample/Assets/Scripts/SampleWebView.cs b/sample/Assets/Scripts/SampleWebView.cs
index e8aa466..bec989c 100644
--- a/sample/Assets/Scripts/SampleWebView.cs
+++ b/sample/Assets/Scripts/SampleWebView.cs
@@ -108,6 +108,12 @@ public class SampleWebView : MonoBehaviour
                     "};");
 #endif
                 webViewObject.EvaluateJS(@"Unity.call('ua=' + navigator.userAgent)");
+                webViewObject.EvaluateJS(@"document.addEventListener(
+                                             'click',
+                                             function(evt) {
+                                               Unity.call(evt.offsetX + ',' + evt.offsetY);
+                                             },
+                                             false);");
             },
             //transparent: false,
             //zoom: true,

@TunTin
Copy link
Author

TunTin commented Jun 21, 2021

I followed your suggestions and now I am having 2 problems:
1: If I use WebView to display an HTML file like the image below, I have succeeded in adding a small image to the position I click on the WebView but when I use WebView to display an SVG file like the image below, things are not like that.
Screenshot_1
Screenshot_2

2: I don't understand why but I can only use the available image file sample.jpg to display thumbnails on WebView but when using an image I manually add to the Project like Note_Solid.png, the thumbnail cannot be displayed. OK.
sample
Note_Solid

All of my code is in SampleWebView.cs and I will send you below along with all the Assets I use for You to test.
Assets.zip

Hope You can suggest me a solution, thanks

@KojiNakamaru
Copy link
Member

The sample app won't load a svg file directly. The following part extracts jpg/js/html files from StreamingAssets and loads the html file by LoadURL().

var exts = new string[]{
".jpg",
".js",
".html" // should be last
};
foreach (var ext in exts) {
var url = Url.Replace(".html", ext);
var src = System.IO.Path.Combine(Application.streamingAssetsPath, url);
var dst = System.IO.Path.Combine(Application.persistentDataPath, url);
byte[] result = null;
if (src.Contains("://")) { // for Android
#if UNITY_2018_4_OR_NEWER
// NOTE: a more complete code that utilizes UnityWebRequest can be found in https://github.com/gree/unity-webview/commit/2a07e82f760a8495aa3a77a23453f384869caba7#diff-4379160fa4c2a287f414c07eb10ee36d
var unityWebRequest = UnityWebRequest.Get(src);
yield return unityWebRequest.SendWebRequest();
result = unityWebRequest.downloadHandler.data;
#else
var www = new WWW(src);
yield return www;
result = www.bytes;
#endif
} else {
result = System.IO.File.ReadAllBytes(src);
}
System.IO.File.WriteAllBytes(dst, result);
if (ext == ".html") {
webViewObject.LoadURL("file://" + dst.Replace(" ", "%20"));
break;
}
}

An easy solution would be to rename your svg file to sample.svg and embed it in sample.html. If you utilize the sample app as is, you also need to add ".svg" to exts. Similarly about 2 you can rename your png file to sampe.png and add ".png" to exts.

@TunTin
Copy link
Author

TunTin commented Jun 22, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jun 22, 2021

The above problem I will solve according to your suggestion, many thanks.
Currently I have another problem that I have a Scene I call it DialogScene which will display a list of SVG files for the user to choose from but
every time I use LoadScene function to load DialogScene, DialogScene is always hidden under WebView, Do you have any solution to help me, thanks

@KojiNakamaru
Copy link
Member

You cannot overlay any unity rendering over webviews, as discussed in #694 (comment) . You could realize such a list of UI in javascript/html or hide the webview while a user is picking a svg.

@TunTin
Copy link
Author

TunTin commented Jun 22, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jun 23, 2021

The above problems I have solved according to your advice and very successful, thank you very much and now I have 1 more problem that needs your suggestion, my application has 1 StatusBar with Height = 60px is on top and WebView will display below it, when initializing WebView I have set TopMargin = 60px but on devices with different screen sizes TopMargin of WebView is showing different, please see image under. Can you suggest me the solution to solve this problem, thanks
image

@KojiNakamaru
Copy link
Member

Your status bar might be scaled depending on the screen resolution. SetMargin() sets margins in device pixel units, so if you specify the top margin 60, the status bar's height should always be 60 in device pixel units. If you realize the status bar as a uGUI image, its rect transform should be as below:

image

@TunTin
Copy link
Author

TunTin commented Jun 23, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jul 9, 2021

Currently I have a problem in calling a function that passes a string parameter from C# to JS and vice versa:
C# I call up the JS like this:
WebVwObj.EvaluateJS(string.Format(@"AddBackgroundForViewNote('{0}', '{1}')",
"Title",
"Value"));
JS I have a function like this:
window.AddBackgroundForViewNote = function(id, url) {
// Unity.call('Anh.NT: AddBackgroundForViewNote - id = ' + id + ', url = ' + url);
var BackgroundViewNote = document.createElement('img');
BackgroundViewNote.id = id;
BackgroundViewNote.src = url;
BackgroundViewNote.style.position = "absolute";
document.body.appendChild(BackgroundViewNote);
};
And the unfortunate thing is that on Android it runs OK but not on iOS, Can you suggest a solution for me, thanks

@KojiNakamaru
Copy link
Member

Unity.call() is natively defined for Android but not for iOS. For iOS, it is defined in the ld: callback:

ld: (msg) =>
{
Debug.Log(string.Format("CallOnLoaded[{0}]", msg));
#if UNITY_EDITOR_OSX || (!UNITY_ANDROID && !UNITY_WEBPLAYER && !UNITY_WEBGL)
// NOTE: depending on the situation, you might prefer
// the 'iframe' approach.
// cf. https://github.com/gree/unity-webview/issues/189
#if true
webViewObject.EvaluateJS(@"
if (window && window.webkit && window.webkit.messageHandlers && window.webkit.messageHandlers.unityControl) {
window.Unity = {
call: function(msg) {
window.webkit.messageHandlers.unityControl.postMessage(msg);
}
}
} else {
window.Unity = {
call: function(msg) {
window.location = 'unity:' + msg;
}
}
}
");

If you can edit the html, you can define Unity.call() in the html:

<html>
  <head>
    ...
    <script>
      if (window && window.webkit && window.webkit.messageHandlers && window.webkit.messageHandlers.unityControl) {
          window.Unity = {
              call: function(msg) {
                  window.webkit.messageHandlers.unityControl.postMessage(msg);
              }
          }
      } else {
          window.Unity = {
              call: function(msg) {
                  window.location = 'unity:' + msg;
              }
          }
      }
    </script>
    ...
  </head>
  ...
</html>

then you don't need to define it in the ld: callback.

@TunTin
Copy link
Author

TunTin commented Jul 12, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jul 13, 2021

Thank you very much for the suggestion but sorry to bother you again because I have checked and found that Unity.call is still running OK on iOS, as evidenced when I click on the WebView on iOS I called Unity.call and transmit Click coordinates from HTML + JS to Unity + C# as Log below I copied from XCode:
2021-07-13 19:25:19.182611+0700 PlazaDeux2021UnityVer[3217:1220003] Received event Anh.NT: OnPointerClick|357|326
Anh.NT: CallFromJS[Anh.NT: OnPointerClick|357|326]
EditVC:b__107_0(String)
System.Action`1:Invoke(T)

Above all, my problem right now is that I can call back and forth between HTML + JS and Unity + C# if there is no String data in the parameter list, but if so, my code will just run. on Android but not on iOS and here is how I code, please refer below and give me your opinion, thanks
Unity + C# code:
WebVwObj.EvaluateJS(string.Format(@"AddBackgroundForViewNote('{0}', '{1}')",
"ID for Obj",
"Image for Obj"));

HTML + JS code: trong đó _id + _url là 2 tham số kiểu String
window.AddBackgroundForViewNote = function (_id, _url) {
var BackgroundViewNote = document.createElement('img');
BackgroundViewNote.id = _id;
BackgroundViewNote.src = _url;
BackgroundViewNote.style.position = "absolute";
document.body.appendChild(BackgroundViewNote);
};

I will attach to you the HTML + JS file I use for your convenience Debug
ViewNote.zip

@KojiNakamaru
Copy link
Member

For the sample app, I put your ViewNote.html and ViewNote.js under StreamingAssets and copied sample.jpg to ViewNote.jpg:

image

set Url to ViewNote.html:

image

and changed SampleWebView.cs:

diff --git a/sample/Assets/Scripts/SampleWebView.cs b/sample/Assets/Scripts/SampleWebView.cs
index e8aa466..46a62e8 100644
--- a/sample/Assets/Scripts/SampleWebView.cs
+++ b/sample/Assets/Scripts/SampleWebView.cs
@@ -30,6 +30,7 @@ public class SampleWebView : MonoBehaviour
     public string Url;
     public Text status;
     WebViewObject webViewObject;
+    int id;
 
     IEnumerator Start()
     {
@@ -40,6 +41,15 @@ public class SampleWebView : MonoBehaviour
                 Debug.Log(string.Format("CallFromJS[{0}]", msg));
                 status.text = msg;
                 status.GetComponent<Animation>().Play();
+                if (msg.StartsWith("Anh.NT: OnPointerClick"))
+                {
+                    var pos = msg.Replace("Anh.NT: OnPointerClick|", "").Split('|');
+                    Debug.Log(string.Format(@"({0}, {1})", pos[0], pos[1]));
+                    var nid = "note" + id++;
+                    webViewObject.EvaluateJS(string.Format(@"AddBackgroundForViewNote('{0}', '{1}')", nid, "ViewNote.jpg"));
+                    webViewObject.EvaluateJS(string.Format(@"document.getElementById('{0}').style.left='{1}px'", nid, pos[0]));
+                    webViewObject.EvaluateJS(string.Format(@"document.getElementById('{0}').style.top='{1}px'", nid, pos[1]));
+                }
             },
             err: (msg) =>
             {

With this modified sample app, I can tap on iPhone screen to add ViewNote.jpg:

sc

@TunTin
Copy link
Author

TunTin commented Jul 14, 2021 via email

@TunTin
Copy link
Author

TunTin commented Jul 14, 2021

Thanks for help. I tried on Sample Project same as You and yes My Code is ok on both Android and iOS but when I try again on My own Project everything is same, on Android OK but iOS not and I detect Out of all the lines of code that I write in Unity + C# to call HTML + JS, I would like to ask you if there is any special setup required for Project to be able to call HTML + JS from Unity + C# , thank you!

@KojiNakamaru
Copy link
Member

There is no special setup to invoke EvalulateJS() (unity+c# -> html+js). You should track down the issue step by step and figure out which part doesn't work. If Unity.call() (html+js -> unity+c#) seems not working, you may miss its definition, which I discussed before: #694 (comment) .

@TunTin
Copy link
Author

TunTin commented Jul 14, 2021 via email

@TunTin
Copy link
Author

TunTin commented Sep 9, 2021

Many thanks, I will continue to try on your Sample Project and will depend on the results that may have to ask You for further assistance.

@KojiNakamaru
Copy link
Member

Here is a minimum sample.html which demonstrates how to drag an image.

<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>Unity WebView</title>
    <style>
      * {
          -webkit-user-select: none;
      }
    </style>
    <script>
      window.addEventListener(
          'load',
          function() {
              var img = document.querySelector('img');
              var x0;
              var y0;
              var r0;
             img.addEventListener(
                  'touchstart',
                  function(event) {
                      event.preventDefault();
                      var t = event.touches[0];
                      x0 = t.pageX;
                      y0 = t.pageY;
                      r0 = event.target.getBoundingClientRect();
                  },
                  false);
             img.addEventListener(
                  'touchmove',
                  function(event) {
                      event.preventDefault();
                      var t = event.touches[0];
                      var x1 = t.pageX;
                      var y1 = t.pageY;
                      event.target.style.left = (r0.x + x1 - x0) + 'px';
                      event.target.style.top = (r0.y + y1 - y0) + 'px';
                  },
                  false);
             img.addEventListener(
                  'touchend',
                  function(event) {
                      event.preventDefault();
                  },
                  false);
          },
          false);
    </script>
  </head>
  <body>
    <img src="sample.jpg" style="position: absolute;" />
  </body>
</html>

@TunTin
Copy link
Author

TunTin commented Sep 10, 2021 via email

@TunTin
Copy link
Author

TunTin commented Sep 11, 2021

I think the black square is the Drag/Drop function available on WKWebView, when I hold down an img tag, it will immediately appear a black square with the same avatar as the img tag and when I move my finger, the black square will appear. scroll like the image below so I want to ask you if you have any way to disable Drag/Drop function on WKWebView? Thank you.

ViewPanel

@KojiNakamaru
Copy link
Member

KojiNakamaru commented Sep 12, 2021

Did you try the sample.html described in #694 (comment) ? It shows no black square when you drag the image.

iOS WKWebView itself doesn't have any drag-specific function which displays such a black square. As noted before, it should be caused by your javascript, javascript libraries you utilize, and/or html/css.

@TunTin
Copy link
Author

TunTin commented Sep 14, 2021

I tried on Your Sample Project and when I Run the Sample.html file on Safari, I tap and hold on the img tag (src = SVG file) the thing in the red circled area like the image below appears and I think when running on iOS it it's Black Square but when I run it on iOS, img tag can't load SVG file like when I open Sample.html file on Safari, Can you tell me where am I missing, I don't edit much Sample Project Yours except disabling wkAllowsLinkPreview on WKWebView and Selectable on HTML like what We discussed above.

Screen Shot 2021-09-13 at 4 33 34 PM

@TunTin
Copy link
Author

TunTin commented Sep 14, 2021

On iOS it looks like this:

1

@KojiNakamaru
Copy link
Member

Please try the sample app as is except sample/Assets/StreamingAssets/sample.html which should be replaced with the one described in #694 (comment) .

@TunTin
Copy link
Author

TunTin commented Sep 15, 2021

When I comment Your Drag/Drop code and long press on img the default Drag/Drop function on WKWebView will be activated like the picture You see below, so can you help me to bypass the Drag/Drop function default on WKWebView? Thank you.

ViewPanel
image

@KojiNakamaru
Copy link
Member

It happens only on PC and is not related to WKWebView on iOS. You can also find various information on the net, such as https://stackoverflow.com/questions/704564/disable-drag-and-drop-on-html-elements .

@TunTin
Copy link
Author

TunTin commented Sep 17, 2021

I used event.preventDefault() in touchstart() event and it worked, thanks for your quick support.

@TunTin
Copy link
Author

TunTin commented Sep 19, 2021 via email

@TunTin
Copy link
Author

TunTin commented Nov 5, 2021

I need to hide horizontal and vertical scrollbar on WebView, in both Android and iOS platforms, Can you give me a solution? Thank you.

@KojiNakamaru
Copy link
Member

As there was no convenient way for hiding scrollbars, I added SetScrollbarsVisibility(bool visibility) in #750 and updated binaries. Could you please try the latest?

@TunTin
Copy link
Author

TunTin commented Nov 8, 2021 via email

@TunTin
Copy link
Author

TunTin commented Nov 15, 2021

Your above solution works great, thanks. Now I have another problem that I need your help with, I need to disable scrolling on WebView, is there any way to solve it?

@KojiNakamaru
Copy link
Member

Adding the following should prevent scrolling.

      body {
          overflow: hidden;
          position: fixed;
          width: 100%;
      }

The following is a complete demo based on #694 (comment) .

<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>Unity WebView</title>
    <style>
      * {
          -webkit-user-select: none;
      }
      body {
          overflow: hidden;
          position: fixed;
          width: 100%;
      }
    </style>
    <script>
      window.addEventListener(
          'load',
          function() {
              var img = document.querySelector('img');
              var x0;
              var y0;
              var r0;
             img.addEventListener(
                  'touchstart',
                  function(event) {
                      event.preventDefault();
                      var t = event.touches[0];
                      x0 = t.pageX;
                      y0 = t.pageY;
                      r0 = event.target.getBoundingClientRect();
                  },
                  false);
             img.addEventListener(
                  'touchmove',
                  function(event) {
                      event.preventDefault();
                      var t = event.touches[0];
                      var x1 = t.pageX;
                      var y1 = t.pageY;
                      event.target.style.left = (r0.x + x1 - x0) + 'px';
                      event.target.style.top = (r0.y + y1 - y0) + 'px';
                  },
                  false);
             img.addEventListener(
                  'touchend',
                  function(event) {
                      event.preventDefault();
                  },
                  false);
          },
          false);
    </script>
  </head>
  <body>
    <img src="sample.jpg" style="position: absolute;" />
  </body>
</html>

@TunTin
Copy link
Author

TunTin commented Nov 15, 2021

I have 1 problem asked you a long time ago and You told me there is no way to solve it, that is I want to display a scene on top of WebView but I can't because WebView is always on top but when I use Input Field on Unity and check off the [Hide Mobile Input] property, when I focus on it, the keyboard will appear as shown below with [Mobile Input] the part I circled in red and I understand that it is a UI created by Unity and it is showing above the WebView, do you know how to make [Mobile Input] do that?
Screenshot_2021-11-15-14-36-26-733_com DefaultCompany PlazaDeux_2021_Unity_Ver

@KojiNakamaru
Copy link
Member

As described in https://docs.unity3d.com/Packages/[email protected]/manual/script-InputField.html,

|Hide Mobile Input (iOS only) ||Hides the native input field attached to the onscreen keyboard on mobile devices. Note that this only works on iOS devices.| | | | |

It is the native input field attached to the onscreen keyboard. It is not directly displayed by uGUI.

@TunTin
Copy link
Author

TunTin commented Nov 15, 2021

But the photo above I took on an Android device?

@KojiNakamaru
Copy link
Member

Turning "Hide Mobile Input" on is only allowed for iOS. The state of "Hide Mobile Input" turned off is default for both platforms and you said you turned it off.

@TunTin
Copy link
Author

TunTin commented Nov 15, 2021

Turn on Hide Mobile Input on Android device:
1636969642491

@KojiNakamaru
Copy link
Member

Okay, although its behavior differs from the description on the manual and recently it might also be supported for Android.
But then, what is your question? The part you circled in red is the native input field attached to the onscreen keyboard. This point doesn't change.

@TunTin
Copy link
Author

TunTin commented Nov 16, 2021

My problem is still I can't display anything on WebView (eg Scene, UI Element: Panel, Button, ...) and I see [Mobile Input] display on WebView so I want to ask Do you know how [Mobile Input] can do that?

@KojiNakamaru
Copy link
Member

This is done by OS's software keyboard function, so it is called "native" input field. As the software keyboard is over webview, the native input field, which is the part of the software keyboard, is also over webview. It is not rendered by Unity.

@TunTin
Copy link
Author

TunTin commented Nov 16, 2021

I found your article [https://github.com//issues/587] and I thought it would solve my problem, but when I check on [Render Over Native UI] in [Player Setting] the WebView can't be displayed anymore? Can you help me to solve this issue?

@KojiNakamaru
Copy link
Member

As noted in #584, a user cannot interact with webview. It is basically useless.

@TunTin
Copy link
Author

TunTin commented Nov 17, 2021

Can you help me Screen Shot WebView? Using Unity's Screen Shot function can't Screen Shot WebView?

@KojiNakamaru
Copy link
Member

Unity's ScreenCapture.CaptureScreenshot() captures only unity's rendering view. In Asset Store, there might be an asset that allows to capture the whole screen.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants