Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/java/344.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Java Worldwind表面形状和战术符号的渲染顺序_Java_Arcgis_Layer_Worldwind - Fatal编程技术网

Java Worldwind表面形状和战术符号的渲染顺序

Java Worldwind表面形状和战术符号的渲染顺序,java,arcgis,layer,worldwind,Java,Arcgis,Layer,Worldwind,基本上,我希望默认情况下在战术符号的顶部渲染曲面形状。下面是在Worldwind示例中重新创建的问题 public class TestApp extends ApplicationTemplate { public static class AppFrame extends ApplicationTemplate.AppFrame { public AppFrame() { // Symbol RenderableLayer symbolLayer

基本上,我希望默认情况下在战术符号的顶部渲染曲面形状。下面是在Worldwind示例中重新创建的问题

public class TestApp extends ApplicationTemplate {

public static class AppFrame extends ApplicationTemplate.AppFrame {

    public AppFrame() {

        // Symbol
        RenderableLayer symbolLayer = new RenderableLayer();

        TacticalSymbol symbol = new MilStd2525TacticalSymbol("suzp-----------", Position.fromDegrees(0.0, 0.0));
        symbol.setAltitudeMode(WorldWind.CLAMP_TO_GROUND);
        symbol.setShowLocation(false);
        symbolLayer.addRenderable(symbol);

        // Shape
        RenderableLayer shapeLayer = new RenderableLayer();
        SurfaceCircle circle = new SurfaceCircle(Position.fromDegrees(0.0, 0.0), 100e4);
        shapeLayer.addRenderable(circle);

        getWwd().getModel().getLayers().add(symbolLayer);
        getWwd().getModel().getLayers().add(shapeLayer);
    }
}
public static void main(String[] args) {
    start("World Wind Testing", AppFrame.class);
}
}

无论我以何种顺序添加层,战术符号始终渲染在曲面形状的顶部。我假设这是因为形状的渲染方式不同:

图层按图层列表中定义的顺序显示。(但图层中的三维形状按从远到近的顺序显示)


我有一种预感,我可以通过扩展战术符号、实现OrderedRenderable接口和重写makeOrderedRenderable()来解决这个问题方法,但我不确定应该进行哪些具体更改,以在不破坏其他层的情况下实现所需的功能。

我想你没有想到这一点?不幸的是,没有。这仍然是一个问题。我认为你的问题类似于(不完全相同):请参阅我的答案。我希望这对你有用。