Technically it can be both. The drone receives GPS to know its location so it can maintain position in the air, otherwise, if it doesn't have a good signal it may float with the wind as it would not know where it is at, (Generally in ATTI mode) however it does use other sensors to try to see objects on the ground as a second method of holding its location.
If you have a device in your controller with GPS capabilities. The app typically knows your location and allows it places 'you' on the map properly and show the direction you are facing. Additionally you can set your home point to the controllers location. But if you are using a device without GPS, such as a non-cellular version of a tablet, then these options may not be available to you.
So yes, flying under a veranda or in a car, etc will work fine as the most important GPS sensor is on the drone.