Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
y_scale.del_domain([], this.model_id + "_y");
}
}
}
}
ImageGLModel.serializers = Object.assign({}, bqplot.MarkModel.serializers,
{ x: serialize.array_or_json,
y: serialize.array_or_json,
image: { deserialize: (obj, manager) => {
let state = {buffer: obj.value, dtype: obj.dtype, shape: obj.shape};
return jupyter_dataserializers.JSONToArray(state);
}}});
class ImageGLView extends bqplot.Mark {
render() {
var base_render_promise = super.render();
window.last_image = this;
this.image_plane = new THREE.PlaneBufferGeometry( 1.0, 1.0 );
this.image_material = new THREE.ShaderMaterial( {
uniforms: {
image: { type: 't', value: null },
// the domain of the image pixel data (for intensity only, for rgb this is ignored)
// these 3 uniforms map one to one to the colorscale
colormap: { type: 't', value: null },
color_min: {type: 'f', value: 0.0},
color_max: {type: 'f', value: 1.0},
// the type of scale (linear/log) for x/y will be substituted in the shader
// map from domain