getparamfromfrm2pix
Get frame format parameters
Description
[
returns
video format parameters from a activePixelsPerLine
,activeLines
,numPixelsPerFrame
]
= getparamfromfrm2pix(frm2pix
)visionhdl.FrameToPixels
System object™.
Examples
Configure Pixel Stream Format
When you choose a standard video format for visionhdl.FrameToPixels
, the object computes the frame dimensions. To access these values, call the getparamfromfrm2pix
function.
frm2pix = visionhdl.FrameToPixels(... 'NumComponents',1,... 'VideoFormat','240p'); [activePixels,activeLines,numPixelsPerFrame] = getparamfromfrm2pix(frm2pix)
activePixels = 320
activeLines = 240
numPixelsPerFrame = 130248
Note that numPixelsPerFrame
includes both active and inactive regions of the frame.
Input Arguments
frm2pix
— Video serializer
visionhdl.FrameToPixels
System object
The visionhdl.FrameToPixels
object converts
framed video to a stream of pixel values and control signals. It contains
useful parameters regarding the video format.
Output Arguments
activePixelsPerLine
— Number of pixels in a horizontal line of the active video frame
positive integer
Number of pixels in a horizontal line of the active video frame, returned as a positive integer.
For custom video formats, this value corresponds to the ActivePixelsPerLine
property
of the frm2pix
object.
activeLines
— Number of horizontal lines in the active video frame
positive integer
Number of horizontal lines in the active video frame, returned as a positive integer.
For custom video formats, this value corresponds to the ActiveVideoLines
property
of the frm2pix
object.
numPixelsPerFrame
— Number of active and inactive pixels in the video frame
positive integer
Number of active and inactive pixels in the video frame, returned as a positive integer.
For custom video formats, this value corresponds to the product
of the TotalVideoLines
and TotalPixelsPerLine
properties
of the frm2pix
object.
Version History
Introduced in R2015a
MATLAB 命令
您点击的链接对应于以下 MATLAB 命令:
请在 MATLAB 命令行窗口中直接输入以执行命令。Web 浏览器不支持 MATLAB 命令。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)