implemented surfaceEnvironment. has bug of going beyond domain