Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Question WebGL build randomly missing partial texts

Discussion in 'Web' started by xeniaeo, Feb 28, 2021.

  1. xeniaeo

    xeniaeo

    Joined:
    Jan 28, 2018
    Posts:
    3
    Hi, I'm using Unity 2019.4.18f1 to develop for WebGL. In my project, I have to read multiple different texts from database and display them during runtime. And I also need to include both Chinese and English characters. However, sometimes in the build (browser is Chrome), there's randomly missing partial texts (like below), but sometimes everything's alright and nothing went missing. (In the editor, it never went wrong.)

    randomly_missing_text.JPG
    (Both languages have missing texts.)

    I noticed that when there're texts missing, the web console will print multiple warning "[.WebGL-000001E7A6E5EF40] GL_INVALID_VALUE: Offset overflows texture dimensions." at the same time. But I can't figure out what this message means.

    If anyone has any idea about this, I'd really appreciate any hint or possible direction to solve this......my initial guess is this may be related to runtime memory restriction by WebGL or browser but still have no idea on how to solve this. Thanks in advance!

    Edit: On Firefox, I get this warning "WebGL warning: texSubImage: Offset+size must be <= the size of the existing specified image.". I've tried to remove the msjh font asset and only use the default Arial font asset, and only use English characters, but I still run into this issue.
     
    Last edited: Mar 2, 2021
  2. xeniaeo

    xeniaeo

    Joined:
    Jan 28, 2018
    Posts:
    3
    I've managed to make the warnings go away by setting the RectTransform of my Vertical Scroll View from -200 to 0, and most of the random text missing issue go away. Some still exist and I suspect that to be related to another web console warning "WebGL: INVALID_VALUE: tex(Sub)Image2D: video visible size is empty". After I disable my VideoPlayer in the scene, the texts don't go missing anymore.
     
    Last edited: Mar 3, 2021
  3. nnhhaadd

    nnhhaadd

    Joined:
    Sep 7, 2015
    Posts:
    11
    I'm working with Unity2023.2 and still have this problem on WebGL. Do we have a solution for this yet?
     
  4. unityruba

    unityruba

    Unity Technologies

    Joined:
    Nov 6, 2020
    Posts:
    278
    Please open a bug report with a project repro and send me a link to it so I can bring it up in our bug triage meeting. This is the fastest way for us to investigate these issues.
     
  5. sumpfkraut

    sumpfkraut

    Joined:
    Jan 18, 2013
    Posts:
    242
    I also missed some text (all text on different text components). Only in WebGL builds.
    I solved it by deleting the "library" folder and the existing build. Then do a "clean build".
     
  6. nxtboyIII

    nxtboyIII

    Joined:
    Jun 4, 2015
    Posts:
    281
    This is happening to me too, ever since adding VideoPlayer, some texts are not showing some characters
     
  7. nxtboyIII

    nxtboyIII

    Joined:
    Jun 4, 2015
    Posts:
    281
    Tried this and didn't solve it for me
     
  8. unityruba

    unityruba

    Unity Technologies

    Joined:
    Nov 6, 2020
    Posts:
    278
    @nxtboyIII can I get you to open a bug report for us to have a project that shows this issue, please?