1. An apparatus, comprising: a block processing pipeline implemented in a video encoder circuit and configured to process blocks of pixels from video frames; wherein the block processing pipeline comprises a block input component; wherein, for each of a plurality of blocks of pixels from a video frame, the block input component is configured to: receive input data representing the block of pixels; compute gradient values for the block of pixels in two or more directions; compute one or more histograms representing statistics derived from the gradient values for the block of pixels; determine a likelihood that the block of pixels represents a portion of the video frame that contains text, wherein to determine the likelihood that the block of pixels represents a portion of the video frame that contains text, the block input component is configured to determine a presence or absence of a dominant gradient direction in the block of pixels, dependent on the one or more computed histograms; and determine one or more parameter values for encoding the block of pixels, dependent on the likelihood that the block of pixels represents a portion of the video frame that contains text.