Fix build for 3d.