Comments (5)
@kcfresh53 hi ! Are you with Windows or Linux ? Can you share your project as zip in this ticket or share a link (or send it to my email if you want to keep it private) I'll investigate (you shared me CEF logs but my code also make logs (probably not displayed with Windows)) but seems to me the "scene" is not the root cause because in our project https://github.com/stigmee/stigmee the CEF node was on a scene. Maybe in your script you are closing the scene and reopening it and CEF was closed.
from gdcef.
@kcfresh53 I may have understood what you have made wrong: you only need one instance of CEF for the whole project. No more :) You should let consider it as the "engine" and be singleton i.e. the Godot update function is implicitly "pumping" CEF internal messages between CEF forked processes:
gdcef/addons/gdcef/gdcef/src/gdcef.cpp
Line 88 in da447a3
gdcef/addons/gdcef/gdcef/src/gdcef.cpp
Line 187 in da447a3
Therefore, do not confuse CEF with its browser views (aka tabs ... I do not know to name things, I hope the name is correct) that you are allowed to create as many as you want. My code is probably detecting that you are trying to create 2 CEF instances ...
gdcef/addons/gdcef/gdcef/src/gdcef.cpp
Line 106 in da447a3
... and an error message is displayed (readable in the Godot console ?) ...
gdcef/addons/gdcef/demos/3D/GUI.gd
Line 142 in da447a3
... and abort.
gdcef/addons/gdcef/demos/3D/GUI.gd
Line 143 in da447a3
Why do you need one CEF for each of your "Navigat" (ion panel ?) ? When you create a new browser view, it will be created as Godot node as a child of the CEF node. Contrary to Unity, Godot does not display them in the scene graph. Let these "private" nodes in peace : the creation function will return you their node reference, and you can store them as variables in your "Navigat" nodes.
gdcef/addons/gdcef/demos/3D/GUI.gd
Line 147 in da447a3
gdcef/addons/gdcef/demos/3D/GUI.gd
Line 105 in da447a3
Note : For the moment, I never tried to delete browser views there is maybe a crash because CEF and Godot both reference them.
from gdcef.
Thanks for the response, I am on windows and CEF is only used once in the project. The other pages do not hold a web view, the project is an app development base framework with customizable mobile components, multi database support (e.g superbase, firebase, SQL, etc.) and I planned on using the WebView to view native JavaScript components, local html pages, Leaflet JS maps and faster integration of other payment providers in Godot. I plan on the project being open source but its not ready yet so I will just send a project invite.
from gdcef.
Beware CEF is not supported on Android and IOs https://magpcss.org/ceforum/viewtopic.php?f=6&t=18268
from gdcef.
@kcfresh53 I have created a dev-cef branch in your project and added CEF node and 2 texture rectangles inside the 1st and 2nd panel. I added a Main.gd to your main node for the logic. Only the second browser reacts to mouse inputs, you have to add the logic to enable the good browser. You can follow my demos to add more features for your CEF.
It works nicely on my side so we can close this ticket I guess. We can continue talking about your project by email if you want :)
from gdcef.
Related Issues (20)
- License HOT 4
- Windows demo crashing immediately on play HOT 6
- Locale is in French
- Looking for MacOs and/or Godot and/or CEF developer HOT 1
- User-configutable resource directory HOT 9
- Add CI for Windows HOT 2
- New tab links open a new OS window HOT 4
- Merging the last std::cout with GDCEF_ERROR and godot::Godot::print HOT 1
- Add example of JS injection in demo
- Add Godot smoke test HOT 1
- Upload compiled library artifacts as part of CI HOT 1
- Widevine support? HOT 2
- FileNotFoundError on compile HOT 6
- Please add support for Godot-4.0 HOT 9
- Build Error for GDCEF HOT 11
- API: Add save the page as html HOT 1
- Nonexistent function 'initialize' when running demos HOT 6
- Compile the add-on with Godot HOT 18
- No SConstruct file found HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gdcef.