# 1080p video downscale to 720p

Source: [https://docs.qualcomm.com/doc/80-88500-3/topic/63_1080p_video_downscale_to_720p.html](https://docs.qualcomm.com/doc/80-88500-3/topic/63_1080p_video_downscale_to_720p.html)

In this use case, a 1080p AVC video stream is decoded to YUV, downscaled to 720p, and then dumped to file after AVC encoding.

1. Run the following command to execute the use case.

        gst-launch-1.0 -e qtiqmmfsrc name=qmmf camera=0 ! video/x-raw\(memory:GBM\),format=NV12,width=1920,height=1080,framerate=30/1 ! queue ! qtic2venc ! queue ! h264parse ! qtic2vdec ! video/x-raw\(memory:GBM\),format=NV12, compression=ubwc ! queue ! qtivtransform ! video/x-raw\(memory:GBM\),format=NV12,compression=ubwc,width=1280,height=720 ! queue ! qtic2venc ! queue ! h264parse ! mp4mux ! queue ! filesink location=/data/output/mux2.mp4Copy to clipboard
2. `h264parse` parses the buffer and `qtic2vdec` decodes the buffer to YUV.
3. `qtic2vdec` shares the compressed (UBWC) YUV buffer to `qtivtransform`.
4. `qtivtransform` downscales the buffer to 720p using hardware acceleration and passes it to `qtic2venc`.
5. `qtic2venc` encodes the buffer to H264 using hardware acceleration and passes it to `filesink`.
6. `filesink` then stores the encoded stream to file.
7. To stop the use case, press CTRL + C, pull the
        recorded content out from device using the following `adb pull` command, and
        then play the content on a host PC. 

        adb pull /data/video.h264Copy to clipboard

**Parent Topic:** [UBWC control use cases](https://docs.qualcomm.com/doc/80-88500-3/topic/61_UBWC_control_use_cases.html)

Last Published: Sep 26, 2023

[Previous Topic
Live preview using in-memory compression with video record](https://docs.qualcomm.com/bundle/publicresource/80-88500-3/topics/62_Live_preview_using_in_memory_compression_with_video_record.md) [Next Topic
Live streaming over RTSP with two H.264 streams](https://docs.qualcomm.com/bundle/publicresource/80-88500-3/topics/64_Live_streaming_over_RTSP_with_two_H264_streams.md)