Using smart pointer for scene