Please explain your problem properly. "I'm missing bytes" is not something that can be solved. What data do you expect, and what do you see?
Bitmap.Save() will return the data according to the specified format, which in all cases contains more than just the pixel data (headers describing width and height, color / palette data, and so on). If you just want an array of pixel data, you'd better look at Bimap.LockBits():
Bitmap bmp = new Bitmap("c:\\fakePhoto.jpg");
// Lock the bitmap's bits.
Rectangle rect = new Rectangle(0, 0, bmp.Width, bmp.Height);
System.Drawing.Imaging.BitmapData bmpData = bmp.LockBits(rect, System.Drawing.Imaging.ImageLockMode.ReadWrite, bmp.PixelFormat);
// Get the address of the first line.
IntPtr ptr = bmpData.Scan0;
// Declare an array to hold the bytes of the bitmap.
int bytes = Math.Abs(bmpData.Stride) * bmp.Height;
byte[] rgbValues = new byte[bytes];
// Copy the RGB values into the array.
System.Runtime.InteropServices.Marshal.Copy(ptr, rgbValues, 0, bytes);
Now the rgbValues array contains all pixels from the source bitmap, using three bytes per pixel. I don't know why you want an array of shorts, but you must be able to figure that out from here.
512 x 512 x 4 = 1048576so where is the missing bytes?