简体   繁体   中英

Camera/LCD resolution scaling

Thanks in advance.

I am trying to interface a 480x640 camera with a 480x272 lcd (through an FPGA) while preserving as much data as possible and maintaining a clear image. Is this possible? If so, is this a scaling issue and are there any relevant algorithms you can direct me towards?

There are several image resizing techniques out there (just google). Some of the fancier ones will require thought vis-a-vis implementation in hardware and likely require a reasonable pipeline and one or two hardware multipliers (though you could theoretically pipeline this too). Are you planning on resizing video in real-time or just a single still?

The easiest/dirtiest is just subsampling. In your case you need to shrink the vertical of your image by at least a factor of 640/272 = 2.35. Since the aspect ratio of the display and the camera are different you won't be able to maintain a full display and the aspect ratio of the original image. Of course you can't really subsample by a non integer number. What you can do instead is either a combination of interpolation and sub-sampling or just round the 2.35 to 2 or 4 and sub-sample in both dimensions. Obviously if you go to 2 you'll end up cropping a bit and if you go to 4 then you won't fill the entirety of the vertical dimension. Subsampling is nice because it's trivial to implement in hardware. On the other hand it's not the best algorithm for a nice image result. My suggestion would be to start with subsampling (you can easily simulate in matlab or something similar) and see if it's good enough for you. If so go for it. Otherwise keep exploring in the SW world and think about a HW implementation of whatever algorithm seems interesting to you.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM