Search found 20 matches

by ragbagger
Thu Jan 10, 2019 1:46 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 2329

Re: mjpeg video code

yes. Interesting. And it does work pretty well. Also, where did you get the skeleton for the mjpeg headers. I scoured the internet to find a source for a mjpeg header when initially thinking of creating a video with the jpeg files and came up with nothing. So very very curious to how/where you got t...
by ragbagger
Wed Jan 09, 2019 9:33 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 2329

Re: mjpeg video code

update: I was able to get video working. As usual thanks a ton for your replies. Apologies for not reading your reply with more attention before :)
by ragbagger
Wed Jan 09, 2019 9:04 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 2329

Re: mjpeg video code

wait.... I just re- read your reply a few times. Are you saying the bpp = jpeg file size when bpp> 4? I couldn't get that from the code, but ill take your word for it. Must have missed it.
by ragbagger
Wed Jan 09, 2019 3:53 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 2329

Re: mjpeg video code

right.....but the length that is given to the write data method is "out.bpp + pad"

write_data(fp, out.pixels, out.bpp + pad);


out.bpp + pad = 2+4 = 6

I'm assuming bpp is 2 bytes for RGB565.
Shouldn't the length be some kilobytes in size? My jpeg image size is around 10KB.
by ragbagger
Wed Jan 09, 2019 1:58 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 2329

Re: mjpeg video code

haha... 3 years is a long time. So I appreciate the explanation. Still do not understand one thing though.... If that line is just adding the padding for a multiple of 4, where are you actually writing in the frame data. I do not see any line for that in the jpeg_add_frame function. I would assume t...
by ragbagger
Tue Jan 08, 2019 9:51 pm
Forum: Technical Discussion
Topic: mjpeg video code
Replies: 9
Views: 2329

mjpeg video code

Hi guys I have a question about adding a frame your mjpeg code. Specifically from line 99 in function void mjpeg_add_frame(FIL *fp, uint32_t *frames, uint32_t *bytes, image_t *img, int quality) I am confused about the line write_data(fp, img->pixels, img->bpp + pad); // reading past okay". Hoping yo...
by ragbagger
Wed Jan 02, 2019 2:37 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

Re: jpeg compression algorithm

So only difference between an H7 and F7 when it comes to pushing the 8x8 macroblocks is the processor speed. 200MHz vs 400MHz.
Awesome! I'm definitely going to order myself an H7 board.

Thanks for all the answers. Appreciate it.
by ragbagger
Fri Dec 21, 2018 1:45 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

Re: jpeg compression algorithm

yes. good point. the HW is optimized for video playback but not streaming video from camera.
So 20fps for 640x480 is not too shabby? The video should be smooth enough right?
Also why did you guys pick the H7 image sensor from On Semi over the older OV7725?
by ragbagger
Thu Dec 20, 2018 12:58 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

Re: jpeg compression algorithm

Interesting. I was just reading the app note AN4996 and I attached a snapshot of the encoding parameters to this post. They specify 4ms for a 640x480 conversion with an H7 and F7. But mention that the RGB to YCbCr conversion would take 58ms. Now if you get the data in YcbCr format itself which the O...
by ragbagger
Wed Dec 19, 2018 6:11 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

Re: jpeg compression algorithm

I remember the stm32f767 also having the jpeg encoder but the CPU had to feed it the 8x8 macro blocks. Did they fix that in the H7series? If so, that is cool. Performing it in the hardware would be quite fast. How long would it take to compress a 640x480 image in hw by the H7? I gotta read the docs :)
by ragbagger
Wed Dec 19, 2018 2:01 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

Re: jpeg compression algorithm

Update: thanks to both your suggestions, I am now able to get the jpeg compression time for a 320x240 image to around 30ms. I had to enable the DCache and also introduce 2x2 jpeg subsampling to get there. But the quality does degrade a bit from no subsampling (1x1) which I guess is the trade off. So...
by ragbagger
Wed Dec 12, 2018 1:28 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

Re: jpeg compression algorithm

Thanks for input. I will check these. I noticed that I only enabled the Icache and not the Dcache in my program. So need to figure how to do that without causing any inconsistencies in the RAM. I tried for quality level of 70% and 60%. Also, the YUV LUT accessing is before the DCT conversion. I thin...
by ragbagger
Mon Dec 10, 2018 10:18 pm
Forum: Technical Discussion
Topic: jpeg compression algorithm
Replies: 16
Views: 5483

jpeg compression algorithm

Hi guys So I'm trying to implement the jpeg compression algorithm on the openMV board for my own personal project. Its mostly the same code that you have in your jpeg.c file. I ported most of it but I can't seem to get a good conversion time like you guys have and I'm lost for ideas. I have a 320x24...
by ragbagger
Thu Dec 06, 2018 10:19 pm
Forum: Technical Discussion
Topic: Bayer output for OV7725
Replies: 9
Views: 1756

Re: Bayer output for OV7725

hmmm... so you guys are going from raw bayer to jpg directly? When you de-mosiac, you are adding the all three RGB values to each pixel. So 24bit/pixel

So are you just converting each 8x8 macro blocks to jpeg before moving on to the next macro block? Am I in the right direction here?
by ragbagger
Thu Dec 06, 2018 7:58 pm
Forum: Technical Discussion
Topic: Bayer output for OV7725
Replies: 9
Views: 1756

Re: Bayer output for OV7725

have a follow up question here. When we de-mosiac a 640x480 bayer image (size of 307KB) to RGB565 or RGB888 or YUV, its size would increase to more than 512KB (size of SRAM). So I feel it does not seem to be possible to do this de-mosiacing within the F7 itself. Am I wrong here. How do you guys do i...
by ragbagger
Tue Nov 27, 2018 12:00 pm
Forum: Technical Discussion
Topic: Bayer output for OV7725
Replies: 9
Views: 1756

Re: Bayer output for OV7725

wow! holy cow! thanks for the lightning fast reply!!!!!
by ragbagger
Tue Nov 27, 2018 11:54 am
Forum: Technical Discussion
Topic: Bayer output for OV7725
Replies: 9
Views: 1756

Re: Bayer output for OV7725

Hi Ibrahim
Quick follow up question. Do you have a link for the algorithm you use for the conversion of Bayer to RGB/YUV image? Im trying to learn the theory of the conversion and then work with the code. Right now the code is a bit overwhelming for me.
-Thanks
by ragbagger
Mon Nov 26, 2018 9:15 pm
Forum: Technical Discussion
Topic: Bayer output for OV7725
Replies: 9
Views: 1756

Re: Bayer output for OV7725

Thank a ton for the quick reply! :)
by ragbagger
Mon Nov 26, 2018 4:23 pm
Forum: Technical Discussion
Topic: Bayer output for OV7725
Replies: 9
Views: 1756

Bayer output for OV7725

Hi Guys Whats the difference between the Bayer RAW and Bayer processed RAW on the OV7725 sensor? For getting a 640x480 image, you guys mentioned in a previous discussion that because the SRAM is too small to store the RGB, you use the Bayer RAW output from the sensor and then de-bayer it. So have a ...
by ragbagger
Wed Aug 09, 2017 5:48 pm
Forum: Technical Discussion
Topic: Power saving mode
Replies: 14
Views: 4934

Re: Power saving mode

Hi Im interested in this thread. Im kind of curious which low power modes is enabled here when I compare this with the STM32F7 data sheet. The standby mode is the lowest power consumption mode. I would like to come out of this mode using a HW interrupt. But it looks like PA0 and PC13 are no connects...

Go to advanced search