Some camera software may make the fake highest resolution, interpolated, just for reference.
What width , height do you try to set ?
Try to debug code line by line, inspecting what camera device is found and selected and next...
My default example works ok as-is on my laptop, and shows the same resolutions list as on your screenshot, about my built-in camera. So, it's not 1M, just 0.3M.