nir_to_tgsi: Fix image declarations.
We failed to translate the target type, which virgl needs for translation. Also the read_only flag is for consts, shader inputs, and uniforms. The access flag gives you the readonly qualifier.
extracted from !8044 (merged)