Transcodes the given resource to the new resource type and returns the new resource.
The resource to transcode.