cobe
cobe copied to clipboard
Transparent base color
Hello, is it possible to set a transparency level for the base color? Many thnxs!
This is currently not supported, but PRs are welcome!
@shuding, i want to change the baseColor but why it's not working? It's getting wrong color for some times.
`import createGlobe from "https://cdn.skypack.dev/cobe";
let phi = 0;
let canvas = document.getElementById("cobe");
const globe = createGlobe(canvas, {
devicePixelRatio: 1,
width: 500,
height: 500,
phi: 0,
theta: 0,
dark: 0,
diffuse: 1,
scale: 1,
mapSamples: 16000,
mapBrightness: 12,
baseColor: ["0", "170", "255"],
markerColor: ["0", "170", "255"],
glowColor: [1, 1, 1],
backgroundColor: [255, 255, 255],
opacity: 1,
offset: [0, 0],
markers: [],
onRender: (state) => {
// Called on every animation frame.
// `state` will be an empty object, return updated params.
state.phi = phi;
phi += 0.01;
},
});`
is there problem with my codes?