Since this is more likely to be a device-specific question, rather than a Marshmallow question, I'll move it to the S5 mini forum.
Is the display set to Automatic Brightness? Of course, that should make the screen brighter in bright sunlight, rather than dimmer, but I'm wondering if something with the ambient light sensor is malfunctioning.