How to render a entity with ellipse on my custom second globe(maybe the moon)

I have add a feature to cesiumjs, to build two globe objet in one viewer, for example the second globe mybe the moon.
Now I want to draw a ellipse entity on the moon,but the entity always be clamped to first globe object. How can I draw the ellipse entity(maybe a polygon or other) to the moon ground?

Do I have to modify the shader of the globe? Or other shaders?

Waiting for your solution, Thanks!!!

Hi @tzraeq ,
Thanks for your post and for being part of the Cesium community.

Do you mind sharing a little more details about your use case and maybe some sample code? Better yet, could you create an example in our sandcastle tool https://sandcastle.cesium.com/ that reproduces the behavior you are seeing?

Hopefully with some specific examples of your code we can get to the root cause of the behavior you are seeing.

Thank you,
Luke

I had added an octa property to viewer.scene, and upload my project to gofile.
After building the project, you can use the octa like this:

const depth = 15000.0;
const {x, y, z} = Ellipsoid.WGS84.radii;
const ellipsoid = new Ellipsoid(x - depth, y - depth, z - depth);
const octa = new Globe(ellipsoid);
octa.baseColor = Color.fromCssColorString("#333333");

const viewer = new Viewer(viewerRef.value, {
    octa,
    baseLayer: layerFrom(options.baseLayer),
    animation: false, 
    infoBox: false, 
    selectionIndicator: false, 
    sceneModePicker: false, 
    baseLayerPicker: false, 
    navigationHelpButton: false,
    shouldAnimate: true, 
    timeline: false, 
    geocoder: false, 
    homeButton: false, 
    fullscreenButton: false,
    skyAtmosphere: false,
    orderIndependentTranslucency: false
});

const scene = viewer.scene;
const globe = scene.globe;

globe.depthTestAgainstTerrain = true;

scene.screenSpaceCameraController.enableCollisionDetection = false;
const alpha = 0.6;
globe.translucency.enabled = true;
globe.translucency.frontFaceAlphaByDistance = new NearFarScalar(
    0,
    alpha,
    10000,
    1.0
);
globe.translucency.backFaceAlpha = 0.0;

globe.undergroundColor = null;

Now I want to draw a ellipse entity on view.scene.octa,but the entity always be clamped to view.scene.globe object. How can I?

Thanks for your reply!