Finish writing MCP (To be tested)

And fix a bug of centerline mask