I assume that it is because QuickTime is using your GPU to decode the h.264 but VLC isn't.
There is support for hardware accelerated h.264 decoding in VLC; you just need to enable it. I think the option is in Input and Codecs tab in the preferences.
You might have hardware acceleration in the Input/Codecs menu disabled.
Try VLC 3.0.0 nightly builds using VideoToolbox or activate GPU decoding.
Maybe QuickTime knows how to leverage hardware decoding?