Discrete convexity: Definition, parametrization, and compatibility with continuous convexity