Update functions to use polymorphic Surface types