def _vrtWrapBand(vrtDataset, sourceBand):
	"""
	Wraps a GDAL raster band in a VRT band.
	"""
	
	# Retrieve the width and height from the source band
	width = sourceBand.XSize
	height = sourceBand.YSize
	
	# Create the new VRT raster band
	vrtDataset.AddBand(sourceBand.DataType)
	vrtBand = vrtDataset.GetRasterBand(vrtDataset.RasterCount)
	
	# Build the XML for the data source
	bandSource = '''<SimpleSource>
		<SourceFilename relativeToVRT="1">{}</SourceFilename>
		<SourceBand>{}</SourceBand>
		<SrcRect xOff="{}" yOff="{}" xSize="{}" ySize="{}"/>
		<DstRect xOff="{}" yOff="{}" xSize="{}" ySize="{}"/>
	</SimpleSource>'''.format(
		sourceBand.GetDataset().GetFileList()[0],
		sourceBand.GetBand(),
		0, 0, width, height,
		0, 0, width, height
	)
	
	# Add the data source to the VRT band
	metadata = {}
	metadata['source_0'] = bandSource
	vrtBand.SetMetadata(metadata, 'vrt_sources')
	return vrtBand