Is there a straightforward way to generalize the answer here to how to transform the points within a square to a polygon to n-dimensional cubes and polygons? Specifically, given a convex region $\mathcal{C}\in\mathbb{R}^n$, bounded by hyperplanes on all sides, is there a one-to-one mapping between this region and the hypercube $[0,1]^n$?
A region I'm thinking of would be something like $$ \mathcal{C}:\{(x,y,z)\in\mathbb{R}^3\big|\; 0\leq x\leq2, -1\leq y \leq 3, -3\leq z \leq -1, \\ -1\leq 2x-y+z, 0\leq x+y\leq 3 \}. $$
Any convex body, $C$ in $\Bbb{R}^n$ is homeomorphic to $[0, 1]^n$. To see this, pick a point $p$ in the interior of $C$ and choose $\alpha > 0$ small enough such that $D = p + \alpha[0, 1]^n$ is contained in the interior of $C$. Then design a radial projection $f : C \to D$ that maps a point $c$ on the boundary of $C$ to the point $c_0$ where the line segment $[p, c]$ meets the boundary of $D$ and maps $p + \lambda (c - p)$ to $p + \lambda (c_0 - p)$ for $0 \le \lambda < 1$. Composing $f$ with the obvious affine homeomorphism from $D$ to $[0, 1]^n$ gives the homeomorphism you are asking for.