Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to recovery the LXDE desktop video output after running a mpp_sample?
#1
Currently all Mpp_sample show unpleasant results, that when you start to run any sample, you have no way to terminate it and back to desktop because when each sample create vi it transfors the desktop video layer to an outter layer 8 and then close the layer 8. It 's so confused why allwinner do that. 
I do some experiments to try:
1.  insert a line to pthread of display: signal(SIGINT,destroy_vo) .  this SIGINT can capture the ESC key, and terminate the process.
2. resize the VO create size to 640*480

then it works, the 640*480 window stop to run, while the shell shows still active and can input commands.
But,but, the  area of 640*480 window can not be recylcle. I donot find a way to solve this issue.
Does anyone notice this question? How to solve?
Reply
#2
Login via ssh on a remote PC, restart lightdm service should work.

$ sudo systemctl restart lightdm.service
Reply
#3
(10-19-2018, 01:09 AM)csjamesdeng Wrote: Login via ssh on a remote PC, restart lightdm service should work.

$ sudo systemctl restart lightdm.service

Unfortunately, I follow your suggestion and run lightdm.service, the LXDE desktop do restart, while the dead corp windows still keep there and not disappear.
it seems lightdm.service can not get the control from video layer. Any other method?
Reply
#4
(10-20-2018, 04:29 AM)arglues Wrote:
(10-19-2018, 01:09 AM)csjamesdeng Wrote: Login via ssh on a remote PC, restart lightdm service should work.

$ sudo systemctl restart lightdm.service

Unfortunately, I follow your suggestion and run lightdm.service, the LXDE desktop do restart, while the dead corp windows still keep there and not disappear.
it seems lightdm.service can not get the control from video layer. Any other method?
Dear arglues,
    Firtstly, I still suggest you to compile and run the mpp_sample through login via ssh on a remote PC.

    Secondly, I would like to show you the architecture of the Display Engine (called DE) in V5 and why the desktop of X11 can not get the control of the video layer.

    The architecture of DE :
        

    In fact, we call the resources of the DE hardware as hardware layers(called hwLayer). And you can indicate it easily through the HLAY(i,j) in MPP system.

    The layer you called "layer 8" means the  No.2 channel,  No.0 layer in DE, and it is a UI Layer.And it is the hwLayer that the X11 desktop using fbdev as its backend running on. Closing it is due to it is not the hwLayer created by MPP, maybe it will bring some unknown error while mpp_sample running. Get it?

    When the MPP_sample with vo function runs, it will create a new Video-Layer type hwLayer (maybe HLAY(0/1, 0/1/2/3)) to display the video, and this new hwLayer is not belong to the X11, so you cannot control it through X11.

    And if you want to see the desktop again when you exit the sample, you can follow these steps:
    1. Deletes the following code when creating or destroying vo, and this will keep the desktop on the screen:
        AW_MPI_VO_AddOutsideVideoLayer(stContext.mUILayer);
        AW_MPI_VO_CloseVideoLayer(stContext.mUILayer);

    2. Set the priority (the priority is between 0 to 15) of the new Video-Layer type hwLayer larger than the desktop's hwLayer (priority 0) like 11, by using MPP  API AW_MPI_VO_SetVideoLayerPriority after you created the vi-hwlayer by using AW_MPI_VO_EnableVideoLayer. 
    And the higher priority means the upper position of the layers, this is the same concept of Z-Order of layers in Android.  

    3.Make sure you exit the sample in the right way. And this means that you run the "destroy class" MPP APIs to close all the Video Layer type hwlayers you have created.

    I hope it can help you.
Powered by Given @ Lindenis  Big Grin
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)