video-processing

Alternative to ffmpeg for iOS

纵饮孤独 提交于 2019-12-04 08:03:43
问题 I've been trying to implement ffmpeg in my ios app several weeks. And now I can play several avi files, but other files like a flv, wma, mp4... play slow. I have spent much time with ffmpeg and opengl and I don't find solution. I'm looking other alternatives to play this files on ios device. Someone know other libraries, frameworks, ... that I can use to play this files. No matter if they have business licenses. Very thanks, Edited: Init Shader: shader = [[GLShader alloc] initWithFileName:@

OpenCV doesn't save the video

坚强是说给别人听的谎言 提交于 2019-12-04 07:51:45
I'm using the following code to read a video from file, apply the canny edge algorithm and write the modified video to a file. The code compiles and runs perfectly. But, the video is not written! I'm utterly confused. Please tell me what the error is. The file is not created at all! OS: Ubuntu 12.10 Code for writing to the output file Opening the output file bool setOutput(const std::string &filename, int codec=0, double framerate=0.0, bool isColor=true) { outputFile= filename; extension.clear(); if (framerate==0.0) framerate= getFrameRate(); // same as input char c[4]; // use same codec as

Python OpenCV 2.4 writes half-complete PNG video frames

醉酒当歌 提交于 2019-12-04 04:17:46
问题 I just installed OpenCV 2.4 from source on Ubuntu 12.04. I'm trying to use a Python script to write the first frame of a video to a PNG image, but I'm getting some bizarre results. Here's the code: import numpy as np import cv import cv2 import sys video = cv.CaptureFromFile(sys.argv[1]) frame = cv.QueryFrame(video) proxy = cv.CreateImage(cv.GetSize(frame), 8, 1) cv.CvtColor(frame, proxy, cv.CV_BGR2GRAY) a = np.asarray(cv.GetMat(proxy)) cv2.imwrite('image.png', a) Problem is, the image comes

why DCT transform is preferred over other transforms in video/image compression

谁说胖子不能爱 提交于 2019-12-04 01:12:37
I went through how DCT (discrete cosine transform) is used in image and video compression standards. But why DCT only is preferred over other transforms like dft or dst? Because cos(0) is 1, the first (0th) coefficient of DCT-II is the mean of the values being transformed. This makes the first coefficient of each 8x8 block represent the average tone of its constituent pixels, which is obviously a good start. Subsequent coefficients add increasing levels of detail, starting with sweeping gradients and continuing into increasingly fiddly patterns, and it just so happens that the first few

Android Strip Audio From Video

耗尽温柔 提交于 2019-12-04 01:03:39
问题 In my program, it gets MP4 video in, and I want it to output a MP3 (without any server-side stuff.) Since Android (and my app) needs to run on many different hardware configurations, this means I probably cannot use FFMPEG. I know this may be very battery and processing power intensive, especially for a mobile phone, but I need this option for my users. I cannot find any native libraries for Java that don't use FFMPEG. 回答1: I see little problem with FFMPEG, since apparently it runs on 11

How to read time from recorded surveillance camera video?

♀尐吖头ヾ 提交于 2019-12-03 19:15:13
问题 I have a problem where I have to read the time of recording from the video recorded by a surveillance camera. The time shows up on the top-left area of the video. Below is a link to screen grab of the area which shows the time. Also, the digit color(white/black) keeps changing during the duration of the video. http://i55.tinypic.com/2j5gca8.png Please guide me in the direction to approach this problem. I am a Java programmer so would prefer an approach through Java. EDIT: Thanks unhillbilly

How to create videos from images with php?

青春壹個敷衍的年華 提交于 2019-12-03 18:25:57
问题 Let's say I have 10 images and I want to combine those images in a video like a slideshow. For example I want to show each image for 5 seconds and then continue with next image for another 5 seconds. If it's possible, it will be perfect to include music and some descriptive text too. Is there a sample code for this may be with ffmpeg library ? 回答1: My first thought was to shell out to the ffmpeg command with something like this. Creating a Video from Images ffmpeg can be used to stitch

Play video on the android recorded from the iPhone

人盡茶涼 提交于 2019-12-03 17:20:01
问题 I am writing video based social app for iOS and android(WinPhone is under waiting). I recorded video in mov format using AVFoundation framework on the iPhone and uploaded it to the server. It can be downloaded and played on the iPhone client. But on the android device, downloaded video can not be played since it's format is not supported on the android. What is the best solution of the video record and play for supporting multiple mobile devices platforms? 回答1: Blog post @Why Apple Is Winning

h264 packetization mode for FUA

空扰寡人 提交于 2019-12-03 16:44:28
We have got into couple of interop issues where, The video mode that is required by couple of endpoints in market are little different and only understands H.264 packetization modes (FUA type) (i.e) FU -A NAL unit type.(while others do not play the video on receiving a fu-a nal type payload) Does anyone know what is this FUA type of packetization mode? How is it different from packetization modes 0,1,2 as defined in RFC3984? Is the video encoder/decoder supports it, how can it be appropriately signalled in SIP SDP session wherein the attributes do not get changed even when traversing through

OpenCV grouping white pixels

时光总嘲笑我的痴心妄想 提交于 2019-12-03 13:45:43
I've done the hard work, turning my iSight camera on my MacBook into an infrared camera, converted it, set the threshold etc.. and now have an image that looks something like this: alt text My problem is now; I need to know how many blobs are on my image by grouping the white pixels. I don't want to use cvBlob / cvBlobsLib , I'd rather just use what is already in OpenCV. I can loop through the pixels and group them by checking for (thresholded) touching white pixels, but I'm guessing there is probably a really easy way of doing this from OpenCV? I'm guessing I can't use cvFindContours as this