
Recherche avancée
Médias (1)
-
The Slip - Artworks
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Texte
Autres articles (58)
-
Publier sur MédiaSpip
13 juin 2013Puis-je poster des contenus à partir d’une tablette Ipad ?
Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir -
Encoding and processing into web-friendly formats
13 avril 2011, parMediaSPIP automatically converts uploaded files to internet-compatible formats.
Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
All uploaded files are stored online in their original format, so you can (...) -
Supporting all media types
13 avril 2011, parUnlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)
Sur d’autres sites (6546)
-
uncertain behaviour of xml parser and ffmpeg streaming
8 octobre 2013, par user2775836I am making an ios application to display live streaming from ip camera using ffmpeg libraries.I am also using http api requests and responses.the response is in xml format ,hence i am using xml parser to parse the response.I have two view controllers(first and second).I am initializing the xml parser at view did disappear function of the first view controller also i am calling the function to stop the streaming in view did disappear after xml parsing function.While navigating from first view controller to second view controller the xml parser gets initiated but the parsing response does not get completed .when i come back from second to first view controller and then navigate again to second view controller ,at that time the full response is parsed.Why the response gets parsed second time not first time and why is it parsing half first time.Please help.
The code is as follows :- (void)viewDidDisappear:(BOOL)animated {
[self parsing]; //call to parsing function
[self.h264dec stopDecode]; //call to stop streaming
self.h264dec = nil;
}
parsing function is:
-(void)parsing
{
NSString *urlString = [NSString stringWithFormat:@"http://www.example.com"];
NSURL *url = [NSURL URLWithString:urlString];
NSMutableURLRequest *theRequest = [NSMutableURLRequest requestWithURL:url];
[theRequest addValue: @"application/x-www-form-urlencoded; charset=utf-8" forHTTPHeaderField:@"Content-Type"];
[theRequest setHTTPMethod:@"GET"];
NSURLConnection *connection = [[NSURLConnection alloc] initWithRequest:theRequest delegate:self];
if( connection )
{
mutableData = [[NSMutableData alloc] init];
NSLog(@"connection successful");
}
}
-(void) connection:(NSURLConnection *) connection didReceiveResponse:(NSURLResponse *)response
{
NSLog(@"receive response");
}
-(void) connection:(NSURLConnection *)connection didReceiveData:(NSData *)data
{
[mutableData appendData:data];
NSLog(@"DIDRECEIVE");
NSLog(@"the mutable data is: %@",mutableData);
}
-(void) connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
{
return;
}
-(void)connectionDidFinishLoading:(NSURLConnection *)connection
{
NSLog(@"finish loading");
// You can do your functions here. If your repines is in XML you have to parse the response using NSXMLParser. If your response in JSON you have use SBJSON.
NSXMLParser *parser = [[NSXMLParser alloc] initWithData:mutableData];
[parser setDelegate:self];
[parser parse];
}
- (void)parser:(NSXMLParser *)parser didStartElement:(NSString *)elementName namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qualifiedName attributes:(NSDictionary *)attributeDict
{
if([elementName isEqualToString:@"Response"]){
NSLog(@"item found");
xmlStringFileObject =[[XMLStringFile alloc]init];
}
}
- (void)parser:(NSXMLParser *)parser foundCharacters:(NSString *)string
{
[nodecontent appendString:[string stringByTrimmingCharactersInSet:[NSCharacterSet whitespaceAndNewlineCharacterSet]]];
NSLog(@"node content = %@",nodecontent);
}
//bellow delegate method specify when it encounter end tag of specific that tag
- (void)parser:(NSXMLParser *)parser didEndElement:(NSString *)elementName namespaceURI:(NSString *)namespaceURI qualifiedName:(NSString *)qName
{
//I am saving my nodecontent data inside the property of XMLString File class
if([elementName isEqualToString:@"test"]){
xmlStringFileObject.test=nodecontent;
NSLog(@"test:%@",xmlStringFileObject.test);
}
else if([elementName isEqualToString:@"resolution"]){
xmlStringFileObject.resolution=nodecontent;
NSLog(@"resolution:%@",xmlStringFileObject.resolution);
AppDelegate *app = (AppDelegate*) [[UIApplication sharedApplication]delegate];
app.res = xmlStringFileObject.resolution;
NSLog(@"THE APPDELEGATE RES VALUE IS:%@",app.res);
}
//finally when we reaches the end of tag i am adding data inside the NSMutableArray
if([elementName isEqualToString:@"Response"]){
[rssOutputData addObject:xmlStringFileObject];
xmlStringFileObject = nil;
}
//release the data from mutable string variable
//reallocate the memory to get new content data from file
nodecontent=[[NSMutableString alloc]init];
} -
Decoding H.264 stream from dvr
17 octobre 2013, par Andrew SI have a security DVR that uses h264 streams. I have been trying to get this to work with zoneminder. I have successfully logged into the dvr and recieved some form of data streams. The data stream is dumped to a fifo/pipe, and then zoneminder uses ffmpeg to read this in.
Note : i know very very little about h.264 streams. just enough to be stupid.
The video only updates about every 15 seconds in ZM. I can dump the stream to a file with ffmpeg or avconv (avconv -i /tmp/mypipe cam.mp4) but it is still not right. However, the file created by avconv is WAY WAY better than the one created by ffmpeg.
I've included a link to the wireshark dump (I did change the PW and login info, etc...). From the data, It appears that the dvr is adding a header to the h264 data streams. I understand that the h264 stream starts with a (0x00 00 01 67) or (0x00 00 01 61). Here is an example of the header plus start of stream :
0x33, 0x30, 0x64, 0x63, 0x48, 0x32, 0x36, 0x34,
0x3f, 0x55, 0x00, 0x00, 0x08, 0x00, 0x20, 0x00,
0xa2, 0x7a, 0xea, 0xdc, 0xcf, 0x08, 0x00, 0x00,
0x0d, 0x0a, 0x11, 0x07, 0x13, 0x20, 0x00, 0x00,
0x00, 0x00, 0x00, 0x01, 0x67, 0x42, 0xe0, 0x14,
0xdb, 0x05, 0x87, 0xc4, 0x00, 0x00, 0x00, 0x01,
0x68, 0xce, 0x30, 0xa4, 0x80, 0x00, 0x00, 0x00,
0x01, 0x06, 0xe5, 0x01, 0x51, 0x80, 0x00, 0x00,
0x00, 0x01, 0x65, 0xb8, 0x00, 0x01, 0xa8, 0xac,I can see that there are a few frame indicators in this message. The DVR's header appears to be 32 bytes long in this case, and in some other messages in the dump, it appears to be 24 bytes long. I am striping the header off before I dump the stream to the pipe. (I have verified the output doesn't include the dvr's headers in any way.
What I would like help with is determining what I should be sending to the pipe. should I start with the first h.264 key ? Is there something out of order ? I'm very surprised that ffmpeg is only getting 15 second updates, but avconv is much better (lots of dropped frames, and playback is "sped up".
using ffmpeg to read the pipe produces a file that shows it's codec as : H264 - MPEG-4 AVC (part 10) (avc1) with a Decoded format : Planar 4:2:0 YUV using vlc.
Appreciate any help you can provide !
edit : on Ubuntu 13.04
ffmpeg version : 6:0.8.6-1ubuntu2
avconv 0.8.6-6:0.8.6-1ubuntu2 -
Ffmpeg 2 mp4 combining
17 novembre 2014, par Fatih Uçarclass Program
{
static void Main(string[] args)
{
ProcessStartInfo startInfo = new ProcessStartInfo(@"C:\ffmpeg\bin\ffmpeg.exe");
Process.Start(startInfo);//ffmpeg open and close
startInfo = new ProcessStartInfo(@"C:\ffmpeg\bin\ffmpeg.exe", @"cat C:\1.mp4 C:\2.mp4 | ffmpeg -f mpeg -i - -vcodec copy -acodec copy C:\merged.mp4");
//this close:(
}
}2mp4 combining for windows form application ?
2 things I want to combine video
All I want to combine 2 mp4