当前位置:网站首页>迅为i.MX8M开发板yocto系统使用Gstarwmr视频转换
迅为i.MX8M开发板yocto系统使用Gstarwmr视频转换
2022-06-29 03:25:00 【mucheni】
iTOP-iMX8MM 提供了一个视频转换组件: imxvideoconvert_g2d,输入以下命令查看具体的信息。
gst-inspect-1.0 imxvideoconvert_g2d

它支持以下功能:
视频颜色空间转换
视频缩放
视频旋转
注意: 在视频颜色空间转换时, imxvideoconvert_g2d 仅支持其他格式的视频转换为 RGB 格式的视频。
1、 视频颜色空间转换
将 gstreamer 自带的 NV12 格式的视频源转换为 RGB16 格式的视频,输入以下命令:
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12 ! imxvideoconvert_g2d ! \
video/x-raw,format=RGB16 ! waylandsink

将 h264 视频解码后,再使用 imxvideoconvert_g2d 转换成 RGB16 格式的视频,输入以下命令:
gst-launch-1.0 filesrc location=/gstreamer/video/1080p_60fps_h264.mp4 ! qtdemux ! queue \
! h264parse ! vpudec ! imxvideoconvert_g2d ! video/x-raw, format=RGB16, width=1920, \
height=1080 ! filesink location=H264ToRgb16_1080p.rgb16

2、视频缩放
将 gstreamer 自带的 NV12 格式 1280*720 的视频源转换为 RGB16 格式 640*480 的视频,输入以下
命令:
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1280,height=720 ! \
imxvideoconvert_g2d ! video/x-raw, format=RGB16, width=640, height=480 ! waylandsink

3、视频旋转
将 gstreamer 自带的视频源旋转 90 度,输入以下命令:
gst-launch-1.0 videotestsrc ! imxvideoconvert_g2d rotation=1 ! waylandsink

将 gstreamer 自带的视频源旋转 180 度,输入以下命令:
gst-launch-1.0 videotestsrc ! imxvideoconvert_g2d rotation=2 ! waylandsink

更多内容可以专注“迅为电子”公众号
边栏推荐
- [test theory] quality analysis ability
- Logarithmic calculation in reverse order, logarithmic calculation in sequence -- merge sort
- Linear and nonlinear structures
- Yyds dry inventory difference between bazel and gradle tools
- The method of exporting packages of all components from existing PCBs in Altium Designer
- Gartner's "voice of customers" has the highest score, and the user experience has become a major breakthrough for China's database
- 嵌入式开发如何进行源代码保密工作
- 不同的二叉搜索樹[自下而上回溯生成樹+記憶搜索--空間換時間]
- An internal error occurred during: 'Retrieving archetypes:'.
- Problème - Ajouter shellerror: permissions d'instrumentation pour le périphérique: vérifier les règles udev.
猜你喜欢

How to keep source code secret in embedded development

Certification training | streamnational certification training phase 2

19.03 vessel description and simple application examples continued
[email protected]"/>Unable to locate program input point [email protected]

Concise words tell about technical people who must master basic IT knowledge and skills. Part 1

2D human posture estimation deeppose
![The continued movement of Jerry's watch [chapter]](/img/3e/f8b98997320580431a8e7117f4a506.jpg)
The continued movement of Jerry's watch [chapter]

【面试指南】AI算法面试
![二叉树的锯齿形层序遍历[分层遍历方式之一 -> 前序遍历+level]](/img/f6/0df9f2a454cea0a95a5347546a90fb.png)
二叉树的锯齿形层序遍历[分层遍历方式之一 -> 前序遍历+level]

Tortoise does not display a green Icon
随机推荐
Web APIs 高阶函数 丨黑马程序员
二叉树的层序遍历 II[层序遍历方式之一 ->递归遍历 + level]
Différents arbres de recherche binaires [arbre de génération rétrospectif ascendant + recherche de mémoire - - espace - temps]
深度解析“链动2+1”模式的商业逻辑
Etcd教程 — 第六章 Etcd之核心API V3
Faster memcpy alternatives- faster alternative to memcpy?
Map and set use pari as the key value. How to define
Jerry's watch begins to move [chapter]
Logarithmic calculation in reverse order, logarithmic calculation in sequence -- merge sort
Tkinter Huarong Road 4x4 Tutorial 4
Web APIs high order functions - dark horse programmers
Linear and nonlinear structures
2022-2028 global MWIR camera industry research and trend analysis report
Laravel v. about laravel using the pagoda panel to connect to the cloud database (MySQL)
Nvisual helps integrators transform
Digital twin application of smart Park Based on Web GIS aerial photography
Shell script to count files, then remove oldest files
Gartner's "voice of customers" has the highest score, and the user experience has become a major breakthrough for China's database
SVN常用的十个命令
How to keep source code secret in embedded development