nal: concatenate and escape row data while building row-start array for header

This way we only need to do a single pass over each slice NAL looking for start
code emulations; and there is one less memcopy. countStartCodeEmulations() and
appendSubstream() methods could be removed.

--HG--
extra : amend_source : e4456f35c44c2f8517205f91b137c52ab5c00508
move lfcuParam to local
move m_bEdgeFilter to local
cleanup unused TComLoopFilter::loopFilterPic
writer: nits
ratecontrol: move validate of CRF params to x265_check_param
ratecontrol: [CHANGES OUTPUT for 10-bit CRF] Remove QP_BD_OFFSET from Ratecontrol

This offset is added inside Quant (setQPforQuant)