Edge roughness in computer graphics is solved via anti-aliasing.
In Godot, you can set rendering quality at the project level in the project settings screen under Rendering>Quality>Filters>MSAA

This is what a cube looks like at 16x MSAA with all the other settings at default:
