Is whether your penis is slightly curved or straight genetic?
It is rare for a man to have a perfectly straight penis, which is fine because women don’t have perfectly straight vaginas.
The penis is composed of three chambers that hold blood. Two are on top, and one is on the bottom in the center. They function much like a three-legged stool. Any slight imperfections are countered by the other chambers. But imperfections do occur from a variety of things, such as small variations while the penis is growing. The chambers have quite a bit of internal webbing. These may not grow perfectly to create an absolutely straight penis. Also, life happens, and there can be damage due to a blow to the penis shaft. The body can heal itself, but it may leave some scar tissue that makes a point in the penis shaft not as flexible or not holding as much pressure at a point in one of the chambers. The result is a slight bend.
Bends that are less than 20 degrees are considered to be normal.