First, from the context, this passage describes night time. The Hobbit . I often walk through woods in the dark and the trees are dark against a paler night sky. Doesn’t have to be moonlit for that. Even on a dark night with clouds, and no Moon. At first it might seem completely dark but if you let your eyes dark adapt and don’t use a torch, then you’ll gradually see some shapes and the night sky can seem quite pale at that point, and you may begin to see some details around you. By this time he would already be somewhat dark adapted, it doesn’t take long to reach that point, and astronomers who spend a lot of time in darkness find that they continue to see more and more detail for not just minutes but for hours if you spend that long in darkness.