Giter VIP home page Giter VIP logo

Comments (3)

dcapeletti avatar dcapeletti commented on June 12, 2024

I followed the trace of the javascript code in the browser and when it reaches the break point shown in the image, the error is launched. However, in the console I can see all the values of the variables that reach this function. Attached screenshot.

chrome_2018-10-18_16-11-09

In this image I show when the error is captured with the information in the console.

chrome_2018-10-18_16-17-52

scene._renderError.raiseEvent(scene, error); displays the error in the console:

Cesium.js:237541 An error occurred while rendering.  Rendering has stopped.
undefined
TypeError: window[functionName] is not a function
TypeError: window[functionName] is not a function
    at selectedObjectCallback (Shader.js:36548:22)
    at MagoManager.selectedObjectNotice (Shader.js:13472:4)
    at MagoManager.startRender (Shader.js:7356:11)
    at MagoManager.start (Shader.js:5768:8)
    at executeCommands (http://localhost:8080/src/engine/cesium/Cesium.js:226607:35)
    at executeCommandsInViewport (http://localhost:8080/src/engine/cesium/Cesium.js:226966:9)
    at updateAndExecuteCommands (http://localhost:8080/src/engine/cesium/Cesium.js:226814:13)
    at render (http://localhost:8080/src/engine/cesium/Cesium.js:227350:9)
    at tryAndCatchError (http://localhost:8080/src/engine/cesium/Cesium.js:227368:13)
    at Scene.render (http://localhost:8080/src/engine/cesium/Cesium.js:227409:13)

Thanks

from mago3djs.

cheonjeongdae avatar cheonjeongdae commented on June 12, 2024

I used Google Translator.

Callbacks are available in mago3D.
Define the function name to be called with callback in the policy-cesium.json file.
You can create a function in an html file.

See the example below.
The callback name and function name in the json file must be the same.

---- mago3djs source ----
policy-cesium.json
..... skip ......
"geo_callback_enable": "true",
"geo_callback_apiresult": "showApiResult",
"geo_callback_dataInfo": "showDataInfo",
"geo_callback_selectedobject": "showSelectedObject",
"geo_callback_moveddata": "showMovedData",
"geo_callback_insertissue": "showInsertIssueLayer",
"geo_callback_clickposition": "showClickPosition",

showApiResult: result of api call
showDataInfo: data information display
.... skip .....
showClickPosition: Display click information

cesium.html
2101 line
function showClickPosition(position) {
.... skip ....
}

http://www.mago3d.com/homepage/demo.do
If you test the page by placing a breakpoint in Chrome Debugger mode
You can check.
github has data upload restriction, so test data can not be uploaded.

from mago3djs.

dcapeletti avatar dcapeletti commented on June 12, 2024

Hello, thank you very much for your reply, it has been very helpful. Problem solved.

Greetings

from mago3djs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.