Hello Hannah,
How can i make make wall thicker and instead of color name (Cesium.Color.RED) i have 8 digit kml color code which i need to pass and create.
KML color example -
Hello Hannah,
How can i make make wall thicker and instead of color name (Cesium.Color.RED) i have 8 digit kml color code which i need to pass and create.
KML color example -
Hello,
Sorry, it is no possible to make a WallGeometry thicker.
Instead, consider using a CorridorGeomery. Here is an example:
var viewer = new Cesium.Viewer(‘cesiumContainer’);
var blueCorridor = viewer.entities.add({
corridor : {
positions : Cesium.Cartesian3.fromDegreesArray([
-120.0, 60.0,
-90.0, 60.0
]),
extrudedHeight : 500000.0,
width : 200.0,
cornerType: Cesium.CornerType.BEVELED,
material : Cesium.Color.BLUE.withAlpha(0.5),
outline : true,
outlineColor : Cesium.Color.BLUE
}
});
viewer.zoomTo(viewer.entities);
``
Hope this helps!
-Hannah
Hi Hannah,
Thanks for reply i will switch to example which you gave me.
How can i use 8 digit color code ?
I have 8 digit KML color code which i need to pass and create wall.
KML color example -
Check out code in KmlDataSource which parses KML colors: https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Source/DataSources/KmlDataSource.js#L448
Is there a reason you aren’t just loading your KML via KmlDataSource?
Hi Matthew,
I am loading KML via KmlDataSource.
Let me tell you little bit more in detail.
KML which is i am using is actually flight data.
When flight is flying it have several events like beam switches, log off, log in, bad beams, good beams etc, i have around 20 events which is coming and connecting via satellite when flight is on the air.
Everything is good until i plot KML using KmlDataSource as i have data in KML.
I am loading several flights data at time so I need to find and create wall or some object which can show events. For that i am finding positions (for example - Bad beam switch) and create wall so that users know where that events occurred among flight routes. I have color already in KML and same color code i have to use to tell events.
I have done everything but since color code are 8 digits and i don't know how to use them...
Thanks for your help Matthew.
Hi Hannah,
Looks like AGSatTrack project is using wall https://cesiumjs.org/demos.html
see the green part and it looks thicker...
CorridorGeomery - i will check it out.
Thanks
I created solution using documentation and it worked for me.
// 1. Dynamic color code i.e name - AQUA
// 2. Worked if color code is given in 6 digit, straight.
//3. Last one woks for me as i have 8 digit. In fact this is hex color and i had to add 0X in the beginning.
color: new Cesium.ColorGeometryInstanceAttribute.fromColor(Cesium.Color[event_color_type])
color: new Cesium.ColorGeometryInstanceAttribute.fromColor(Cesium.Color.fromCssColorString('#F164AB'))
color: new Cesium.ColorGeometryInstanceAttribute.fromColor(Cesium.Color.fromRgba(0xE6B463FF))
Thanks Matthew and Hannah.
I am sorry for asking stupid question
Glad to hear you got it working!
And your question was not stupid =) we’re here to help!
-Hannah