登录
首页 » 视频处理 » textureVIew 显示本地视频

textureVIew 显示本地视频

于 2022-01-25 发布 文件大小:1.31 MB
0 110
下载积分: 2 下载次数: 1

代码说明:

应用背景之前使用surfaceView做视图显示,但是surfaceView无法实现旋转等一些操作,就找到了textureView做视图显示,做的一个简单播放本地视频的例子关键技术public class MainActivity extends Activity implements SurfaceTextureListener, OnBufferingUpdateListener, OnCompletionListener, OnPreparedListener, OnVideoSizeChangedListener{ TextureView textureView; private MediaPlayer mMediaPlayer; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); textureView=(TextureView) findViewById(R.id.textureview); textureView.setSurfaceTextureListener(this); // textureView=new TextureView(this); // textureView.setSurfaceTextureListener(this); // setContentView(textureView); } @Override public void onSurfaceTextureAvailable(SurfaceTexture surface, int width, int height) { System.out.println("onSurfaceTextureAvailab

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • 闻亭的TDS642EVM,即DM642的运动目标检测实验程序,本人已测试通过。...
    闻亭的TDS642EVM,即DM642的运动目标检测实验程序,本人已测试通过。-Wen booths TDS642EVM, DM642 moving target detection experimental procedure, I have the test.
    2022-08-15 23:56:16下载
    积分:1
  • ffmpeg解码
    在学习ffmpeg的过程中发现,目前大多数的资料中的函数都过时,所以照着这些资料的思路将一些旧的函数替换成新的函数。代码的目的是读取一个名为1.flv的文件,并把解码的帧以ppm文件的形式存放。 函数均是最新的(2013年12月19日,32位版本),旧的函数名均已修正。lib与include是从ffmpeg的dev版本中考出来的,建立工程时注意正确设置。dll文件在ffmpeg shared版本中的,我都已拷到工程目录下。我的vs版本是2013,为防止版本不兼容,仅提供cpp文件。 代码流程为:打开文件,获取视频流,获取视频格式,获取解码器,解码帧,存入图片,释放内存。
    2022-04-09 11:43:01下载
    积分:1
  • 使用DirectShow抓屏的Demo程序
    使用DirectShow抓屏的Demo程序-The use of DirectShow screenshots of the Demo program
    2022-03-07 01:11:16下载
    积分:1
  • 网络播放器(实时传送)
    网络播放器(实时传送)
    2022-02-04 04:03:16下载
    积分:1
  • mjpg再5350移植
    mjpg_streamer移植到Ralink5350开发板上的资料,也可以做移植到其他平台的参考。
    2022-02-06 22:28:13下载
    积分:1
  • 小型会议系统
    小型视频会议程序, 简洁凝练,能满足多人同时视频会议,采用rtp协议传递数据包,并提供了画中画功能,是学习视频处理的优良参考程序。 
    2022-01-25 19:18:38下载
    积分:1
  • 能够和很多系统兼容的摄像头源码 A source code that can be compatible with many systems...
    能够和很多系统兼容的摄像头源码 A source code that can be compatible with many systems-And many systems can be compatible camera source A source code that can be compatible with many systems
    2023-05-17 02:15:03下载
    积分:1
  • 文件捕捉的一个小程序,短小精悍,无驱动捕捉。
    视频文件捕捉的一个小程序,短小精悍,无驱动捕捉。-Video files to capture a small procedure, dapper, no drive to capture.
    2022-03-19 12:29:48下载
    积分:1
  • 简单的RTSP Player
    一个简单的rtsp,里面有两个Dll,一个是网络组建 一个是播放组建,同时带有操作说明
    2022-08-06 20:17:03下载
    积分:1
  • Programming a camera through USB camera to camera
    一个摄像头的编程,可以通过USB的摄像头进行摄像-Programming a camera through USB camera to camera
    2022-09-17 02:35:03下载
    积分:1
  • 696518资源总数
  • 106161会员总数
  • 5今日下载