The function call to start render primitives

Hello all,

After pushing the geometries into primitives, where is the function call to start render the primitives?



Hi Steven,

Have you added the primitives to the list of primitives for rendering?

var primitive = new Primitive(/* … */);


Also are you using the Cesium viewer? or are you planning on creating a custom render loop?



Hi Dan,

Thanks for the reply.

Yes, I did, and the code I wrote worked just fine. I am using cesiumwidget instead of viewer.

I want to study how are the primitives are rendered in Cesium, but I couldn’t find the actually function call to draw these primitives on the globe. Would you please point me the place where the rendering process started?



在 2014年2月18日星期二UTC-8下午2时55分07秒,Daniel Bagnell写道:

The core rendering logic is in Scene.js. The functions you should look at are initializeFrame, which only updates animations and the camera, and render, which updates the primitives, finds potentially visible primitives, updates the frustums and finally draws them. I would suggest opening the developer tools in Chrome or Firefox, setting a breakpoint on line 926 of Scene.js and stepping through updatePrimitives, createPotentiallyVisibleSet and executeCommands.