Search Unity

[DISCONTINUED] uWebKit - Chromium WebView for Unity 5

Discussion in 'Assets and Asset Store' started by uWebKit.com, Aug 1, 2013.

  1. Dynamoid-Megan

    Dynamoid-Megan

    Joined:
    Apr 16, 2015
    Posts:
    72
    How do you read cookies from your session after authentication in web browser view? I am trying to keep a cookie to know I'm still logged in, but unsure how to go about it. The web view allows twitter, facebook, and google log in authentication to a main site.
     
  2. 3agle

    3agle

    Joined:
    Jul 9, 2012
    Posts:
    508
    Hi there, I'm just evaluating the demo version and have come across 2 issues I'm hoping can be resolved.

    Firstly, when I try to build to standalone I get an error:

    Code (csharp):
    1. PathTooLongException: Path is too long. Path: Temp/StagingArea/Data\StreamingAssets\uWebKit\Mac\x86\UWKProcess.app\Contents\Frameworks\QtMultimedia.framework\Resources
    Secondly, I can't seem to clear the cache of a page, every time I navigate to it, the old version displays. Is there a way to clear the cache, or to disable caching?
     
  3. 3agle

    3agle

    Joined:
    Jul 9, 2012
    Posts:
    508
    I've managed to work around the caching issue for now by manually deleting the cache before loading the page.
    I've used the following to do this:

    Code (csharp):
    1.  
    2. if (System.IO.Directory.Exists(Application.persistentDataPath + "/cache"))
    3.         {
    4.             System.IO.Directory.Delete(Application.persistentDataPath + "/cache", true);
    5.         }
    6.  
    While this works it's not ideal, being able to disable the cache in the first place would be better.
     
  4. dansav

    dansav

    Joined:
    Sep 22, 2005
    Posts:
    453
    Uwebkit is quite amazing but I'm having trouble communicating simply from javascript to unity. I want to send a string to a unity function from javascript. I am working in unityscript and found the javascript example to be confusing and am having trouble porting it to unity javascript. Do I have to go through onJSMessage. It seems roundabout to have to filter the message and then send it somewhere rather than sending it directly to a unity function.

    javascript from javascriptexample.html
    <input type='button' value="Send JS Message" onclick='UWK.sendMessage("UnityMessage", { "messageCount": messageCount++})' /><br>

    unity c# from javascriptexample.cs
    void onJSMessage(UWKWebView view, string message, string json, Dictionary<string, object> values) { if (message == "UnityMessage") { messageReceived = "Message Received:\n" + json; }
    }

    If that's the only choice how do I convert this to unity's javascript and send the message to my own delegate function.
    I've had a frustrating couple of hours trying to port this with no success.

    function myJSMessageReceived(view:UWKWebView,message:String,json:String,values:System.Collections.Generic.Dictionary.<String, Object>){
    }

    view.JSMessageReceived+=myJSMessageReceived;

    Assets/cgi.js(44,23): BCE0051: Operator '+' cannot be used with a left hand side of type 'function(UWKWebView, String, String, System.Collections.Generic.Dictionary.<String, Object>): void' and a right hand side of type 'function(UWKWebView, String, String, System.Collections.Generic.Dictionary.<String, Object>): void'.

    Otherwise uwebkit seems to work great.
     
  5. TEvashkevich

    TEvashkevich

    Joined:
    May 14, 2015
    Posts:
    9
    Quick question about UWK, been playing around in it and I got half of my OAuth 2.0 test done in it (which is farther than I've gotten with anything else)
    But now I'm getting hung up on doing a Get request with UWK. I just plainly put, have no idea how to do one.

    I'm doing the OAuth 2.0 for the Fitbit API and have been able to direct to the url to either accept/deny. When you accept I can now strip out the token to be used to get data but can't figure out how to do it...If you have any ideas it'd be super helpful as there isn't much info on the net on how to do these in Unity...and let alone correctly.
     
  6. Poccomaxa

    Poccomaxa

    Joined:
    May 7, 2013
    Posts:
    2
    UWKPlugin.UWK_PostUnityKeyEvent does not accept unicode characters correctly. I've added some logs and it seems that when i pass a "а" key (it's russian letter, character code 1072 or 0x430) - it outputs 0 in input field inside web site. It is stated that unicode is supported. Am I doing something wrong? Is there a workaround?
     
  7. romlel

    romlel

    Joined:
    Aug 28, 2013
    Posts:
    1
    Hello all

    We just bought the uWebKit plugin for a use on Desktop AR applications on Windows.
    Unfortunately, we require forced OpenGL mode because of other plugins we use, and uWebKit seems to only allow OpenGL when we use a Mac. Windows works only in DX9/11 mode.

    This is quite annoying, given the fact that the github page claims that the system has "High performance Direct3D9/11 and OpenGL renderers" and that was one of my point of interest before the purchase. In fact it has Windows and Mac renderers, DirectX and OpenGL being respectively only the compatible means to provide them.

    I asked one of my coders to try to modify uWebKit OpenGL renderer to make it compatible with Windows removing some of the OS X dependencies; even at a performance cost ; but that seems quite complicated.

    Would it be possible for the uWebKit team to have a look and provide a small update covering this ? As uWebKit is the best (and almost only) WebKit integration in Unity for desktops, it seems a must-have to cover both Unity's render targets in Windows : DirectX and OpenGL.

    Thanks for your help :)
    Best regards
     
  8. Dynamoid-Megan

    Dynamoid-Megan

    Joined:
    Apr 16, 2015
    Posts:
    72
    @uWebKit.com
    Does anyone know how to expose the auth token the webview browser gets from logging in to sites via Twitter or G+?
    I need to send the authtoken back to my server, but I can't find it.
     
  9. peterNod

    peterNod

    Joined:
    Sep 17, 2014
    Posts:
    1
    How would I go about detecting if there is an input field active within the UWKWebView and currently accepting text input? I thought it might be IMEActive but its always false even when there is a cursor blinking on an input field such as the google search line.

    My use case here is I'm working on a keyboard designed for VR. I only want it to be active when there is input to type in.
     
  10. Garreler_Matjes

    Garreler_Matjes

    Joined:
    Nov 12, 2012
    Posts:
    25
    Hi,

    does the uWebKit2 support sounds on webpages?
    There allways appears the searching indicator or it is happening just nothing.
     
  11. col000r

    col000r

    Joined:
    Mar 27, 2008
    Posts:
    662
    Is there no way to make MipMapping work with uWebKit? If it's integrated into a nice scene it is really a sore spot - everything else is nice and smooth as you move around, but uWebKit is flickering like crazy in high-contrast areas. :(
     
  12. Vinubha88

    Vinubha88

    Joined:
    Mar 25, 2015
    Posts:
    1
    Can we open pdf files in a web browser using uWebKit? I have provided the url to the pdf file, but it doesn't seem to work.
     
  13. mindgrub_rkoch

    mindgrub_rkoch

    Joined:
    Jul 31, 2015
    Posts:
    1
    I am having issues when building my Unity project for Windows and Mac while using uWebKit2. When I build the Unity project, I get errors stating "Unable to remove deployment path". Can anyone help me with this issue?

    To add more to this, I built a version for Mac and a version for Windows. The Windows version seems to run fine. The Mac version does not display the WebGUI, and instead does nothing. The error message seems to show up for both builds.
     
    Last edited: Aug 1, 2015
  14. Ran_Intendu

    Ran_Intendu

    Joined:
    Jan 20, 2015
    Posts:
    2
  15. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    @Ran_Intendu This is a known issue, will be looking into it soon

    @Poccomaxa This has been fixed (I believe for your company?), please send me a message if you are still needing this

    @peterNod The IME is for using Unity's IME input mode for chinese, etc. You may have to use some JS to detect input happening on the page

    @Garreler_Matjes There is limited support for sound in the ogg format

    @Vinubha88 PDF viewing is not supported

    @col000r There is a cross process GPU resource uses to efficiently pass the rendered web page to the Unity process. It isn't possible to enable mipmapping on these resources (and mipmaps would need to be recalculated per frame)

    @mindgrub_rkoch Please download the latest unity package, there was an updated needed for Unity 5.1+ http://uwebkit.com/download/

    -uWebKit Team
    http://www.uwebkit.com
     
  16. jwall

    jwall

    Joined:
    Oct 4, 2013
    Posts:
    2
    Hey uWebKit,

    We're getting the following error when using the EvaluateJavascript call:
    NullReferenceException: Object reference not set to an instance of an object
    UWKWebView+<EvaluateJavascript>c__AnonStorey2.<>m__0 (UInt32 id, System.String value) (at Assets/uWebKit/UWKWebView.cs:457)
    UWKCore.Update () (at Assets/uWebKit/Internal/UWKCore.cs:98)
    It doesn't happen every time. I have created a sample project that reproduces this issue.
    • Create a new project.
    • Add the uWebKit unitypackage.
    • Create a new scene.
    • Drag WebGUI, UWKWebView, and WebView(attached to this post) scripts onto a GameObject in the scene.
    • Assign the UWKWebView component to the WebView field in WebView.cs
    • Press play.
    The screen will load up and display the Webpage and then loop the following:
    • EvaluateJavascript
    • Wait for response
    After running for a while it will reproduce this error.
     

    Attached Files:

  17. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi uWebKit,

    We are currently getting a crash on windows 10 using the examples that come with the uWebKit package. On some PC’s it crashes 100% of the time, on other PC’s it only crashes if the exe and data folder are renamed, or if it is run through steam. We have so far been unable to determine what is different between the PCs, however out of 5 PCs recently upgraded to windows 10 only 1 of them works most of the time and we are unsure why and have not yet found a work around for this issue.

    Attached is a screenshot of the error that is occurring.

    Steps to reproduce:
    1. Download the latest unity package from ‘http://uwebkit.com/download/’
    2. Create a build called “Test” with all the scene files attached
    3. Launch the application on a Windows 10 PC
    4. Observe crash when the web view loads

    Alternative 1 (If the first one works):
    5. Download the latest unity package from ‘http://uwebkit.com/download/’
    6. Create a build called “Test” with all scene files attached
    7. Rename Test.exe to asdf.exe and Test_Data to asdf_Data
    8. Launch the application on a Windows 10 PC
    9. Observe crash when the web view loads

    Alternative 2 (If Alternative 1 works):
    1. Download the latest unity package from ‘http://uwebkit.com/download/’
    2. Find a game in your steam library
    3. Navigate to the folder on your pc
    4. Delete all files in the game’s folder
    5. Create a build called the same thing as the game you just deleted
    6. Copy the build to the game folder
    7. Launch the application from steam on a Windows 10 PC
    8. Observe crash when the web view loads

    Other information:
    • Build is generated from a Unity3D Pro 5.1.1f1
    • We have tested this on Windows 10 Home and Pro with the same result (the one pc where it did work most of the time was the PC that has Unity3D Pro 5.1.1f1 installed and Visual Studio 2013 and Visual Studio 2010)
    • This has been tested and reproduced on other Windows 10 PCs with and without Unity3D and visual studio installed
    • We have tested installing different versions of the C++ runtime redist and no improvement was observed
    • No errors of note are found via DebugView or log file
    • This crash has been observed once on a Windows 7 PC so may not be exclusive to Window 10 but is much more reproducible on Windows 10
     

    Attached Files:

    Last edited: Aug 21, 2015
  18. beachrunnerfred

    beachrunnerfred

    Joined:
    Apr 26, 2013
    Posts:
    11
    Last edited: Aug 23, 2015
  19. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    @jwall: I have reproduced the issue and believe it has something to do with the callback function being moved in memory. I don't have a fix yet

    @Kstoker: I am unable to reproduce the issue on Windows 10 on a standalone deployment from Unity 5.1.2f1, there may be issues when modifying the deployment that Unity produces. uWebKit has no dependencies on any external MSVC runtimes, it is statically linked to them. You should be able to verify this using a Dependency Walker: http://www.dependencywalker.com/

    @beachrunnerfred: uWebKit supports the webm codec (YouTube) as it is under a permissive license. Unfortunately, the LAVFilter codecs are under the GPL and there are also patent issues with them.

    - Josh
    http://www.uWebKit.com
     
  20. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hello Josh/uWebKit,

    We have attempted upgrading to Unity 5.1.3f1 but are still seeing the same issue.

    Our normal build doesn't modify the output of the files, we discovered the rename case when attempting to diagnose what the issue might be.

    The most common cause of the issue we have found is running it through steam. Have you tested the steps in "Alternative 2" and have you tested across a few non developer Windows 10 PCs (as at least one of our machines appears to be working most of the time but the rest would cause the crash)?

    Are we able to get the pdb files for your library so we can attempt to get a better callstack?

    From an export of the example project that comes with the plugin and simply running it (not through steam) on one of the PC's that is having this issue we were able to attach a debugger and get the following callstack. It looks like it is getting an unhandled exception when trying to create some file. I have highlighted the section which is causing the exception:
    user32.dll!_NtUserWaitMessage@0 () Unknown
    user32.dll!_DialogBox2@16 () Unknown
    user32.dll!_InternalDialogBox@24 () Unknown
    user32.dll!_SoftModalMessageBox@4 () Unknown
    user32.dll!_MessageBoxWorker@4 () Unknown
    user32.dll!_MessageBoxTimeoutW@24 () Unknown
    user32.dll!_MessageBoxTimeoutA@24 () Unknown
    user32.dll!_MessageBoxExA@20 () Unknown
    user32.dll!_MessageBoxA@16 () Unknown
    xinput1_3.dll!___crtMessageBoxA () Unknown
    xinput1_3.dll!__NMSG_WRITE () Unknown
    xinput1_3.dll!_abort () Unknown
    xinput1_3.dll!__CxxUnhandledExceptionFilter(struct _EXCEPTION_POINTERS *) Unknown
    KernelBase.dll!_UnhandledExceptionFilter@4 () Unknown
    ntdll.dll!__RtlUserThreadStart() Unknown
    ntdll.dll!@_EH4_CallFilterFunc@8 () Unknown
    ntdll.dll!__except_handler4_common () Unknown
    ntdll.dll!__except_handler4 () Unknown
    ntdll.dll!ExecuteHandler2@20 () Unknown
    ntdll.dll!ExecuteHandler@20 () Unknown
    ntdll.dll!_KiUserExceptionDispatcher@8 () Unknown
    KernelBase.dll!_RaiseException@16 () Unknown
    UWKPlugin.dll!5e833eee() Unknown
    [Frames below may be incorrect and/or missing, no symbols loaded for UWKPlugin.dll]
    UWKPlugin.dll!5e7b375a() Unknown
    UWKPlugin.dll!5e7b7bdf() Unknown
    KernelBase.dll!_BaseSetLastNTError@4 () Unknown
    KernelBase.dll!_CreateFileInternal@24 () Unknown
    KernelBase.dll!_CreateFileA@28 () Unknown
    ffffffff() Unknown
    UWKPlugin.dll!5e7a5e0e() Unknown
    UWKPlugin.dll!5e84e67f() Unknown
    UWKPlugin.dll!5e834b71() Unknown
    UWKPlugin.dll!5e7a51b8() Unknown

    uWebKitExample.exe!007fe628() Unknown
    049fe571() Unknown
    mono.dll!10001e35() Unknown
    mono.dll!10001ddd() Unknown
    mono.dll!100f068f() Unknown
    mono.dll!1005d872() Unknown
    uWebKitExample.exe!002447fe() Unknown
    uWebKitExample.exe!002f79aa() Unknown
    uWebKitExample.exe!002f77a5() Unknown
    uWebKitExample.exe!00233a8a() Unknown
    uWebKitExample.exe!002355b8() Unknown
    uWebKitExample.exe!00213bc1() Unknown
    uWebKitExample.exe!002bd29b() Unknown
    uWebKitExample.exe!00362041() Unknown
    uWebKitExample.exe!00363d65() Unknown
    uWebKitExample.exe!006b4c68() Unknown
    uWebKitExample.exe!006f08d8() Unknown
    kernel32.dll!74e13744() Unknown
    ntdll.dll!__RtlUserThreadStart() Unknown
    ntdll.dll!__RtlUserThreadStart@8 () Unknown
     
    Last edited: Aug 25, 2015
  21. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    Hello,

    Thanks for the callstack, I'll upload a version with some additional logging on file creation. There is a process database and shared memory for synchronization. I'll also see about including debug info.

    - Josh
    http://www.uwebkit.com
     
  22. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    Thanks for looking in to this. When you have the build available can you post me the details on where to get it from and where to find the logs? Is it going to be normal unity logging or will it output to window debug logging (DebugView)?

    Cheers,
    Kevin
     
  23. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    Hello Kevin,

    1) Download a debug x64 UWKPlugin.dll + pdb

    http://www.uwebkit.com/static/downloads/uwebkit/UWKPlugin_DEBUG.zip

    2) Do a 64 bit deployment of your project and once deployed, overwrite the UWKPlugin.dll in the plugins folder of the deployment with the debug version from the zip

    3) Clone the uWebKit Source Code from GitHub to C:\Dev\uwebkit so the debugger can find the source files



    4) Install windbg using the Windows SDK, open a command shell, and from the folder containing your deployment exe, run windbg THE_NAME_OF_YOUR.exe, press F5 to start the player and make sure to select windowed mode

    5) If you get a crash, you should have full callstack, source code, and locals



    - Josh
    http://www.uwebkit.com
     
  24. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    We have been able to replicate the issue with windbg attached and then with visual studio attached. The crash is happening in UWKServer::Initialise(...). In both windbg and visual studio it appears to be happening when creating Poco::Mutex(), however when attaching with visual studio we were presented with a warning that the dll was built with a different version of the source code.

    Looking at the disassembly the code doesn't seem to be accurate to what it happening, it appears to be attempting to read from the 'rax' register which is definitely null.

    I have attached screenshots of the windbg and visual studio. Is your version of uwk_server.cpp different to that on uWebKit github page?

    Cheers,
    Kevin
     

    Attached Files:

    Last edited: Sep 1, 2015
  25. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Further investigation, it seems these three lines do not match code:
    00007FFCFD4D2F1C mov qword ptr [x],0
    00007FFCFD4D2F25 mov rax,qword ptr [x]
    00007FFCFD4D2F2A mov dword ptr [rax],0

    It looks like you have sent us the build with this in it (which looks very much like the code in your screenshot):
    int* x = 0;
    *x = 0;
     
  26. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
  27. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    So the real crash appears to be when creating a file called 'DefaultCompany_WebKitTest_uwk_message_queue_plugin_databuffer_1'. I have attached screenshots of the issues in multiple places.

    The most interesting thing is on the pc where the issue occurs, the unity process attempts to access that file, then the UWKProcess then the unity process again then throws the exception. On the pc which doesn't get the crash it only accesses it once.

    We attempted deleting that file but the issue remained, we have also turned off windows defender (as it was also accessing the file) and it didn't make any difference.

    Files attached:
    • crash1.png
      • This is where it is throwing the exception, the m_handle variable is currently NULL but 'err' is 0
    • crash2.png
      • This is further up the stack at the point where it calls out to create the file
    • crash3.png
      • This shows all the access to the file and the 3 callstacks for each access
      • The red hand drawn numbers on each of the callstacks show the order on which they occured starting from top/first access (1) to bottom/last access (3)
    • WorkingPCAccess.png
      • This shows the access to the file on the pc that isn't having the issue.
     

    Attached Files:

  28. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    Ok, so what is happening is the UWKProcess.exe is having an issue and is exiting. This causes the plugin to attempt to restart the process. This is why you are seeing the file accesses, normally this works, however if UWKProcess can't start at all this could a problem.

    One thing to try is to get the child process debugging tool and to see if it is possible to catch a rough UWKProccess.exe callstack, if it is crashing.

    https://visualstudiogallery.msdn.microsoft.com/a1141bff-463f-465f-9b6d-d29b7b503d7a

    - Josh
    http://www.uwebkit.com
     
  29. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    Are you able to attach the pdb files for UWKProcess.exe?
     
  30. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
  31. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    It looks like the UWKProcess.exe is missing in that zip file. Are you able to send us the debug version UWKProcess.exe and pdb? Also if you could send through the pdb for Qt5Network.dll as that is where the exception seems to be occurring.

    I have attached a screenshot of the callstack on the UWKProcess crash on the release exe.

    Cheers,
    Kevin
     

    Attached Files:

  32. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
  33. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    It appears to be crashing inside QTNetworkAccessManager constructor. see attached screenshot for more info.

    We have a minidump which we could send you as well but the file is too big for this forum, do you have an ftp server or similar which we could upload it to?

    Cheers,
    Kevin
     

    Attached Files:

  34. licensing

    licensing

    Joined:
    Dec 9, 2014
    Posts:
    5
    I'm looking at this with Kevin - it actually seems we're not getting or VS is not catching exception in UWKProcess.exe, but only in parent process. When I then look at current state of UWKProcess, it was in a state from last screenshot, but that changes - I saw it initialise dx11. So ignore last screenshot, it's not a crash.

    Would you be able to give us UWKProcess.exe and pdb with a fake crash like you did yesterday (int *x = 0; *x = 0) to test if we can capture these. It's possible there is no exception in this process at all and it just exists normally, or that we cannot capture it.
     
  35. licensing

    licensing

    Joined:
    Dec 9, 2014
    Posts:
    5
    I suspect Visual Studio is not catching the exception. I see this in log, but VS doesn't stop
    Exception thrown at 0x00007FFDA93EA1C8 (KernelBase.dll) in UWKProcess.exe: 0x000006A6: The binding handle is invalid.

    but then it stops on this
    Exception thrown at 0x00007FFDA93EA1C8 in uWebKitExample2.exe: Microsoft C++ exception: boost::interprocess::interprocess_exception at memory location 0x000000000062DBC0.
    Unhandled exception at 0x00007FFDA93EA1C8 in uWebKitExample2.exe: Microsoft C++ exception: boost::interprocess::interprocess_exception at memory location 0x000000000062DBC0.

    it seems that perhaps the exception in UWKProcess is handled.
     
  36. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    Hey guys,

    It might make some sense at this point for you to be able to compile your own binaries so we aren't passing stuff through a keyhole. Do you have access to VS 2010? Compiling is really easy once you have a few things installed.

    - Josh
     
  37. licensing

    licensing

    Joined:
    Dec 9, 2014
    Posts:
    5
    We've got VS 2012 and 2015 - would any of these work? By the way, should we move to skype or email?
     
  38. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    Hello,

    uWebKit currently requires VS2010 to compile. I will work on getting it compiling with VS2015 and report back with instructions.

    - Josh
    http://www.uwebkit.com/
     
  39. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    VS2015 is a huge can of worms, so must remain on VS2010 for the time being.

    I will provide a full set binaries that should provide additional debugging information as well as a UWKProcess that forces a crash.

    Every compile where settings are changed requires a complete recompile of WebKit, JSCore, etc. So can take upwards of 2 hours. I'll provide download information for the debug package once it is available.

    - Josh
    http://www.uwebkit.com/
     
  40. licensing

    licensing

    Joined:
    Dec 9, 2014
    Posts:
    5
    Thanks Josh .. we look forward to it.
    I found VS2010 on our network as well if needed, I can install it.
     
  41. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
  42. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    How would we go about building the source code ourselves?
     
  43. licensing

    licensing

    Joined:
    Dec 9, 2014
    Posts:
    5
    When I used original UWKProcess.exe, it would not capture any exception in it and crash in main app.
    When I used UWKProcess.exe which should force crash, I get null access exception in it - see attached screenshot. Is this where you added a null memory write?

    If that's the case, it seems original UWKProcess.exe doesn't cause any exceptions. We might need to step through the code to see why it exists. Or add some logging to see what it gets to. As Kevin asked - can be build UWKProcess.exe ourselves to debug it?

    -Martin
     

    Attached Files:

  44. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
  45. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    We seem to be failing to build Qt with this error:
    Qt5Bootstrap.lib(qbytearray.obj) : error LNK2001: unresolved external symbol uncompress
    Qt5Bootstrap.lib(qbytearray.obj) : error LNK2001: unresolved external symbol compress2
    ..\..\..\bin\moc.exe : fatal error LNKjom: D:\uWebKit-master\uWebKitNative\temp\build32\qt-src\qtbase\src\tools\moc\Makefile.Release [..\..\..\bin\moc.exe] Error 1120
    1120: 2 unresolved externals

    It seems there are multiple ways to fix this (from a quick Google search). Just to ensure that we are both building it the same way, how did you go about solving this build error?

    Cheers,
    Kevin
     
  46. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    It appears you are using the 32 bit compiler chain, make sure to open a VS2010 64 bit command console. Unity 5's 64 bit editor will not run 32 bit plugins.

    I do not get those linker errors which appear to be related to zlib, which is configured to use the included static libs:

    https://github.com/uWebKit/uWebKit/blob/master/uWebKitNative/Rakefile#L115

    Are you building with VS2010, my guess is that another compiler is being used, otherwise there may be a competing zlib header somewhere on the system's include path

    - Josh
     
    Last edited: Sep 7, 2015
  47. NicoVar

    NicoVar

    Joined:
    Sep 21, 2012
    Posts:
    40
    Hi,

    A couple of questions:

    1) Is there a way to reset/clear history?

    2) Is there a way to block certain links from being activated? If the link sends a new target I can work around it with the "NewViewRequested" delegate, but how can block the URLChanged delegate from loading a new page? It seems to be called when there's nothing else I can do. In general practice, these methods must return a bool where TRUE means to go ahead and allow the operation... is there something similar?

    Thanks.
     
    Last edited: Sep 7, 2015
  48. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    We were able to get it to build successfully (had to comment out the check for process architecture and force it to x64 as it couldn't detect the architecture correctly).

    So it turns out the issue is due to a case sensitive check in
    bool UWKProcessUtils::CompareExecutablePaths(const std::string& path1, const std::string& path2)

    For the pc's that were having the issue it turns out it was comparing these two locations:
    C:\Program Files (x86)\Steam\SteamApps\common\GameName\GameName_Data\StreamingAssets\uWebKit\Windows\x86_64\UWKProcess.exe
    C:/Program Files (x86)/Steam/steamapps/common/GameName/GameName_Data/StreamingAssets/uWebKit/Windows/x86_64/UWKProcess.exe

    For some reason on some pc's when launching the game via steam the plugin or the process add the wrong capitalising on the 'steamapps' folder. To fix this issue we changed:
    if ( path1 != path2 )

    to:

    if ( tolower(path1) != tolower(path2) )


    Are you able to make the same change and send us a new full build (including mac/windows etc)?

    Cheers,
    Kevin
     
  49. uWebKit.com

    uWebKit.com

    Joined:
    Feb 16, 2013
    Posts:
    119
    @NicoVar: History is not stored beyond the current session, cookies can be cleared. URLChangedDelegate would need to catch the link click and take action based on it. Other than controlling the page content, there isn't a way of stopping a link from being clicked on

    @Kstoker: You can download a package with Win32/Win64/Mac32/Mac64 here:

    http://www.uwebkit.com/static/downloads/uwebkit/uWebKit2_20p8.unitypackage

    This package also fixes an issue with unicode text input. Please let me know if this works for you and we will replace the default download.

    - Josh
    http://www.uwebkit.com
     
  50. Kstoker

    Kstoker

    Joined:
    Oct 9, 2013
    Posts:
    15
    Hi Josh,

    That build seems to be working for us, thank you.

    We did find two other issues that you might be interested in, we were not too concerned with them, but thought I should mention them in-case you wanted to look into it.

    Cheers,
    Kevin

    Other noted issues:
    Network Drive
    When running the game from a mapped network drive, the compare in "UWKProcessUtils::CompareExecutablePaths" fails because the plugin detects the path as the mapped network drive and the UWKProcess.exe detects the full network path.

    E.g.
    webRenderProcessPath:
    X:/!/LocalBuilduWebKit/uWebKitExample2_Data/StreamingAssets/uWebKit/Windows/x86_64/UWKProcess.exe
    path:
    \\psf\Home\!\LocalBuilduWebKit\uWebKitExample2_Data\StreamingAssets\uWebKit\Windows\x86_64\UWKProcess.exe

    As most users won't be running from a network drive this is not a high priority issue.

    Renamed Exe/_Data Folder Issues:
    The other issue where we renamed the exe and _data folder is caused because the old UWKProcess.exe is still listed in the sqllite database and causes it to fail in the "UWKProcessUtils::CompareExecutablePaths" function. After waiting for the timeout, the game works correctly again. This is also not a huge issue as most users wont be renaming the exe or data, but could be an issue if they moved where the game is located.
     
unityunity