changed shader update to take material