-
-
Notifications
You must be signed in to change notification settings - Fork 9
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
There is a problem with the mobile browser running this project #4
Comments
I just tried it, found that the recognized gesture doesn't always match the actual gesture I'm doing and sometimes even when it does match, the gesture properties are wrong. This seems weird to me as it works fine on Android. I suspect this has to do with webGL, I found some posts describing similar behavior with WebGL:
The posts are from the Unity forums, but the behaviors are similar, and Unity also uses webGL. I didn't find anything conclusive or directly related to Godot, but most likely the problem is related to webGL and not this project itself. You can try asking this at https://godotforums.org/ or https://godotengine.org/qa/tag/forum. I'm going to leave this issue open for others to know and help if they find anything relevant to this problem. |
I'm getting the same issue with the html5 export using the ios safari browser. single finger drag works well rotating appears to work as expected but the pinch in and out to zoom jumps back to being zoomed even when pulling fingers apart. it will begin zooming out and then snap quickly zoom in while moving fingers apart. |
Hi @ChildLearningClub, thanks for your comment! I think this is an issue with Godot and not with my project, as this works fine on android. After doing some research I think the problem is probably related to this function as it seems to handle touch input in html5/javascript. If you want, you can research further and open an issue on Godot's Github. Perhaps you should try Godot 4.0 first (if you haven't already) to see if this is already fixed in the latest version. Let me know if you find something new. |
@Federico-Ciuffardi thank you for your response. I agree definitely seems to be something to do with the way it’s being translated over. I thought that maybe using the JavaScript API directly might be a good work around, but you are right it really doesn’t address the root of the problem. But honestly I’m just starting off with figuring things out with Godot and programming, so I really don’t know. |
Godot 4.3 Dev 3 added support for single threading so I was able to do a follow up test with Godot 4 on iOS Safari. It appears that the multi-finger-drag and the pinch are conflicting? RPReplay_Final1708833794.mp4Edit: It does however look like the same code that you referenced above was carried over to Godot 4 if that is in fact the cause? Should I open an issue on Godot's GitHub page? |
Actually it appears that it is not an issue of conflicting drag and pinch, but possibly the use of relative? That is probably what you were referring to here. It seems that that the It is either the code in Godot as you mentioned or the way that zoom is calculated here The distance remains stable however as you can see in the video below so maybe we can implement that as the condition to zoom in and out similar to this? RPReplay_Final1708908824.mp4@Federico-Ciuffardi what are your thoughts? |
I asked in the Godot forum as you suggested here is the link. I tested a web export using this code to zoom and it works as it should. I think swapping out the code using the relative function with distance between the points will fix this within the plugin. |
I think the root of the problem is that there is a bug in how Godot implements touch input in the web export, as the problem only seems to occur there. Therefore, I would prefer to keep the current implementation to give more visibility to the root problem. And also because one of the goals of this project is to show the capabilities of GDTIM, such as the pinch relative, which seems to work except for web export. To solve the issue temporarily while the web export issue persists, you can locally replace the |
If you end up replacing the |
That makes sense, if I can figure out how to stitch the two together I will let you know :) |
Have you tried exporting this project as html? I tried it and open it through a mobile browser,found that something is wrong with gesture recognition, but I can't solve it.
This is the html file I exported, you can try to run it.
export.zip
The text was updated successfully, but these errors were encountered: