Generally, you can file an outland application while you are in Canada and it doesn't affect your chances.
However, you must maintain legal status in Canada (e.g. visitor on a visa-exempt passport or visitor visa or work permit or study permit or implied status ...)