multimedia

How to play sound in Qt5 (Qt4 migration)?

99封情书 提交于 2019-12-10 13:54:08
问题 In Qt4 I used to use QT += multimedia phonon //... #include <Phonon> //... Phonon::MediaObject *mediaObject = Phonon::createPlayer(Phonon::NoCategory, Phonon::MediaSource(QUrl("./assets/audio/window_appear.wav"))); // "\"" + Qdir().absolutePath() + "/audio/click.wav" + "\"" mediaObject->play(); and it all worked fine. But now Phonon is not supported in Qt 5. So I wonder - how can I play media files such as sound in Qt5? Using WebKit? (It is entirely possible but looks kind of bad from many

midiOutOpen on Windows 10 using Microsoft GS Wavetable Synth fails

◇◆丶佛笑我妖孽 提交于 2019-12-10 12:33:31
问题 I have an application that relies on the in built Microsoft GS Wavetable Synth. It has worked flawlessly on Windows XP, Vista, 7, 8 and 8.1. While the first call to midiOutOpen on Windows 10 works, subsequent calls result in error code 1, meaning 'Unspecified error'. The code is simple: result = midiOutOpen(&_midiOutHandle, midiOutputDevice, NULL, 0, CALLBACK_NULL); Any ideas regarding how to resolve this hugely appreciated. 回答1: I see it. Tracing through the machine code, I see the

How to convert pixels to gray scale?

旧城冷巷雨未停 提交于 2019-12-09 17:04:42
问题 Ok, I am using Processing which allows me to access pixels of any image as int[] . What I now want to do is to convert the image to gray-scale. Each pixel has a structure as shown below: ...........PIXEL............ [red | green | blue | alpha] <-8--><--8---><--8--><--8--> Now, what transformations do I need to apply to individual RGB values to make the image gray-scale ?? What I mean is, how much do I add / subtract to make the image gray-scale ? Update I found a few methods here: http://www

C# MP3 Player using winmm.dll

≯℡__Kan透↙ 提交于 2019-12-08 05:57:48
问题 I'm trying to bash together a (very) rough MP3 player during my lunch hour, and so far I've got it to play the files, and I'm working on a way of building a list of filenames to enable random songs, but I think I've just hit a snag. Is there a way of knowing when the currently playing MP3 has finished? An event or some such? As it stands I don't think I'd be able to have playlists etc unless this was possible due to it stopping after every playback. I've attatched the whole source below, feel

C# MP3 Player using winmm.dll

醉酒当歌 提交于 2019-12-07 05:45:29
I'm trying to bash together a (very) rough MP3 player during my lunch hour, and so far I've got it to play the files, and I'm working on a way of building a list of filenames to enable random songs, but I think I've just hit a snag. Is there a way of knowing when the currently playing MP3 has finished? An event or some such? As it stands I don't think I'd be able to have playlists etc unless this was possible due to it stopping after every playback. I've attatched the whole source below, feel free to pick it apart and give me any feedback you may have, cheers. using System; using System.IO;

Looking for a simple MP3 library for C# [closed]

匆匆过客 提交于 2019-12-06 10:11:32
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 4 years ago . I'm writing a larger project and a part of the project is playing MP3 files. Nothing fancy, just playing files from a playlist, start/stop, next/previous (can be done outside the library), fast forward/rewind. I'm looking for a (free) library, or any other method of doing that. Relying on an external player is

Future of SMIL(Synchronized Multimedia Integration Language)?

霸气de小男生 提交于 2019-12-06 08:58:57
问题 SMIL (Synchronized Multimedia Integration Language) got updated last in 2008, does anyone know if there are better protocol to follow when it comes to synchronizing multi-media files? 回答1: SMIL has no natural competitors, so any other solution would rely on scripting. It has support in ePub readers like Azardi as well as most phones with MMS support. The Timed Text, Media Fragments, and Media Ontology specifications address captioning, bookmarking, and indexing audio/video content

memcpy from graphic buffer is slow in Android

早过忘川 提交于 2019-12-05 07:36:16
问题 I want to capture every frame from a video to make some modification before rendering in Android device, such as Nexus 10. As I know, android uses hardware to decode and render the frame in the specific device, so I should get the frame data from GraphicBuffer, and before rendering the data will be YUV format. Also I write a static method in AwesomePlayer.cpp to implement that capture frame data / modify the frame / write it back into GraphicBuffer to render. Here is my demo code static void

Why am I missing the Qt Multimedia functionality?

我只是一个虾纸丫 提交于 2019-12-05 05:21:24
I am new to Qt and I'm creating a simple application which will playback an audio file. I realized that I am lacking the Qt Multimedia API for audio when I wrote: #include <QAudioOutput> ..and I get that there is no such file. I downloaded the latest Qt SDK framework and I can't find a way to add these APIs. I am using Qt creator IDE. IS there a way to get the multimedia functionality working maybe as an add-on or some other way? Thanks. ros Try including it like this: #include <QtMultimedia/QAudioOutput> Ilkka Without more info it's hard to say, but possibly your include paths are just

Android MMS Monitoring

一个人想着一个人 提交于 2019-12-04 21:26:25
I have spent the last several hours trying to research this and understand it, however i've come up empty on every example I tried. Basically my app can send information via MMS to someone else, though the content is in a format that the native inbox doesn't display correctly. Sending the content works fine, however I need to be able to detect the incoming MMS message and open the content in my application to format it correctly. Are there any decent tutorials for this? Of the ones i've found it seems like there's a good amount of information that is missing so I usually end up with errors, or