Module ivit_i.io.display
Classes
class Displayer (cv: bool = False, rtsp: bool = False, height: Optional[int] = None, width: Optional[int] = None, fps: Optional[int] = None, name: str = 'test', server: str = 'rtsp://127.0.0.1:8554', platform: str = 'intel', pool_maximum: int = 1)
-
iVIT Displayer a easy way to handle display, you can display opencv window and send rtsp at the same time.
Args
cv
:bool
, optional- need display cv window. Defaults to False.
rtsp
:bool
, optional- need send rtsp stream. Defaults to False.
height
:Union[int, None]
, optional- for rtsp user, setup output stream height. Defaults to None.
width
:Union[int, None]
, optional- for rtsp user, setup output stream width. Defaults to None.
fps
:Union[int, None]
, optional- for rtsp user, setup output stream fps. Defaults to None.
name
:str
, optional- setup window name or rtsp name. Defaults to "test".
server
:_type_
, optional- setup simple-rtsp-server ip and address. Defaults to "rtsp://127.0.0.1:8554".
platform
:str
, optional- setup platform to get optimize gstreamer pipeline for rtsp. Defaults to 'intel'.
Methods
def get_displayer(self, key: Literal['CV', 'RTSP']) ‑> Optional[ivit_i.io.display.Wrapper]
-
Get displayer by name
Args
key (Literal["CV", "RTSP"]): description
Returns
Union[Wrapper, None]
- Return Target Displayer
def get_press_key(self) ‑> int
-
Get the key press ( ASCII Number ) from CV Displayer
def get_rtsp_url(self) ‑> str
-
Get RTSP URL
Raises
KeyError
- not set up rtsp displayer
Returns
str
- the rtsp url
def get_support_type(self) ‑> List[str]
-
Return support displayer type
Returns
List[ str ]
- a list include support type name
def release(self) ‑> None
-
Release all displayer
def show(self, frame: numpy.ndarray) ‑> None
-
Display image via each displayer with async way