I am using Media Foundation's IMFCapturePhotoSink to take photo from USB camera. I want to store the image in JPEG format.
I am creating Media Type object this way:
MFCreateMediaType(&pPhotoMediaType);
pPhotoMediaType->SetGUID(MF_MT_MAJOR_TYPE, MFMediaType_Image);
pPhotoMediaType->SetGUID(MF_MT_SUBTYPE, GUID_ContainerFormatJpeg);
Then I am using this Media Type object to configure the sink:
m_pPhotoSink>AddStream((DWORD)MF_CAPTURE_ENGINE_PREFERRED_SOURCE_STREAM_FOR_PHOTO, pPhotoMediaType, NULL, &dwSinkStreamIndex)
Now I am wondering if is possible to setup JPEG compresion parameters, e.g. copression level, so as I get the JPEG image directly in the right format.
Related
Using the shortcode audio in Wordrepss [audio src="some-file.mp3"] (this one returns an audio player),
I'm trying to add some params after the file extension: [audio src="some-file.mp3?param1=some-value¶m2=somo-value-two"] etc, but I can see that the shortcode do not retuns the player, this one returns an link to the audio.
Were you able to achieve this somehow?
Thanks.
I currently have an API route in nodeJS generating images from given inputs and then creating and returning a GIF from these images. I'm using gifencoder and canvas to do these operations.
I need to generate a mp4 video instead of a GIF for this route, so I've looked at different solutions, but none suited me:
Converting the GIF to an mp4 with an ffmpeg, seems a little "heavy" and ffmepg need an image path on input to perform this.
Using the image data from canvas to directly feed the videoshow module, less heavy, but it still need images path.
I'd like to not save temporary images for this operation and having a straightforward process like :
"Informations > ImageData > Video".
Do you think it is doable ?
Can I use TTML to create cue that link thumbnail image file coordinates to a range of time the thumbnail represent.
I would like to use TTML to create the cue reference of the thumbnail sprite image created for a duration of the video.
I am aware that this can be done using webvvt, but wanted to check whether this can be done for TTML.
Regards
I was wondering if someone had already tried to make his own simple DASH player(and maybe has some examples/source codes) but without using dash.js repository on GITHUB , and if possible has any insights and tips on how to start with the creation/writing process?
Take a look at Building a simple MPEG-DASH streaming player:
Like described on this site following this steps should give you an idea:
Define an HTML5 video element in the HTML section of a page.
Create a MediaSource object in JavaScript.
Create a virtual URL using createObjectURL with the MediaSource object as the source.
Assign the virtual URL to the video element's src property.
Create a SourceBuffer using addSourceBuffer, with the mime type of the video you're adding.
Get the video initialization segment from the media file online and add it to the SourceBuffer with appendBuffer.
Get the segments of video data from the media file, append them to the SourceBuffer with appendBuffer.
Call the play method on the video element.
Repeat step 7 until done.
Clean up.
I am looking for playing flv files using J2ME. Is there any possibility for doing so? Is there any other way to play youtube videos through J2ME?
Extract the v parameter from an youTube url, lets call it VIDEO_ID.
Open http://gdata.youtube.com/feeds/mobile/videos/VIDEO_ID. The content is in xml format.
Parse the xml to find media:content tags.
Open the url attribute of a media:content tag with Manager.createPlayer(url). The protocol is rtsp.