OPENGL on CUDA

What’s the difference between using opengl simply by using cpp files and by using only .cu files. In other words, by using the cpp compiler or by using CUDA

Both suppose to run on the gpu, rigth??