Source Control/TFS Schema compare

I am interested in doing a schema compare between objects in source control (Team Foundation Server) and another server. Is there an option to select from source control? Is there an API where I could use powershell to automate a process for schema compare between objects on a server and on source control/tfs? Thanks!