Could someone help me?
I have a stage and image and i want to change width and height from input. this is code and it does no work :/ help me.)
var stage = new Kinetic.Stage({ container: 'containerCreator', width: imageWidth, height: imageHeight });
var layer = new Kinetic.Layer();
var imageObj = new Image();
imageObj.onload = function(){
var yoda = new Kinetic.Image({
x: 0,
y: 0,
image: imageObj,
width: imageWidth,
height: imageHeight
});
layer.add(yoda);
layer.add(vrchnyText);
stage.add(layer);
};
imageObj.src = imageSource;
$('#vrchCreator').keyup(function(){
stage.width = $(this).val();
stage.height= $(this).val();
layer.add(yoda);
stage.add(layer);
});