\(\left(2+x\right)\left(x^2-4\right)-\left(x-2\right)\left(x^2+2x+4\right)=\left(x+2\right)^2\left(x-2\right)-\left(x-2\right)\left(x^2+2x+4\right)=\left(x-2\right)\left[\left(x+2\right)^2-x^2-2x-4\right]=\left(x-2\right)\left(x^2+4x+4-x^2-2x-4\right)=\left(x-2\right)2x=2x^2-4x\)
\(\left(x+2\right)\left(x^2-4\right)-\left(x-2\right)\left(x^2+2x+4\right)\)
\(=x^3-4x+2x^2-8-x^3+8\)
\(=2x^2-4x\)