<div dir="auto"><div dir="auto">Hi pq,</div><div dir="auto"><br></div><div>Thanks for your help. Tonight I tried again with no luck, as weston_output has no disable signal, I was trying to defer output creation until all the heads are connected, it didn't work, the rest of the compositor functionalities seems to work, it answers vt_switching and keybindings. Just there was no actual output. </div><div dir="auto"><br></div><div dir="auto">I digged a bit into weston_output _enable, it does iterate through all heads in 'pick_crtc'. If I understand correctly, we need to create crtc for every heads.</div><div dir="auto"><br></div><div dir="auto">While this didn't work, I felt back to create additional output for new heads. However vI found an interesting bug(it's a weird one). If I try to connect to new monitors where Weston is running, the new monitor did light up but how image freezed (rest still working, vt_switching, etc). But If I try to move the cursor while connecting to new monitors, my image would not freeze. The same behavior exits both in Weston and my compositor (which based on libweston). I tried on sway, it didn't have the same issue. I wish I could provide more info but in this situation, I really don't know how to debug.</div><div dir="auto"><br></div><div dir="auto">Thanks,</div><div dir="auto">Sichem<br><br><div class="gmail_quote" dir="auto"><div dir="ltr" class="gmail_attr">Le jeu. 12 sept. 2019 03 h 50, Pekka Paalanen <<a href="mailto:ppaalanen@gmail.com">ppaalanen@gmail.com</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Wed, 11 Sep 2019 23:58:07 -0400<br>
Sichem Zhou <<a href="mailto:sichem.zh@gmail.com" target="_blank" rel="noreferrer">sichem.zh@gmail.com</a>> wrote:<br>
<br>
> Hi wayland devs,<br>
> <br>
> I am trying to run multiple monitors in clone mode, which requires one<br>
> output to drive multiple heads. While I can create output for every head<br>
> and attach them with no problem (defaultly new output comes on the right).<br>
> I can't quite get clone mode to work properly.<br>
> <br>
> Here is steps I do right now:<br>
> In the head_changed_listener:<br>
> 1. Find output in the list,<br>
> 2. If we don't have one, create_with_head.<br>
> 3. If we found one, break, attach and disable the output.<br>
> 4.set_mode(current).<br>
> 5.set_scale(1).<br>
> 6.set_transformation(normal).<br>
> 7.enable_output.<br>
> <br>
> I got black screen once new monitor attached. Any steps I am missing from<br>
> here? Thanks<br>
<br>
Hi,<br>
<br>
the shared-crtc clone mode which you are trying to set up completely<br>
depends on hardware support. If you happen to choose two heads that the<br>
hardware does not support cloning, you don't get any error back during<br>
configuration (this could be regarded as a bug in libweston).<br>
<br>
I had the idea that you should get back some signal about the output<br>
being forcefully disabled (weston_output::destroy_signal and<br>
weston_compositor::output_destroyed_signal) once it tries to update the<br>
first time, but now I'm not sure if I implemented that.</blockquote></div></div><div dir="auto"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
This inconvenience is because we haven't implemented testing the<br>
configuration during weston_output_enable(). It is tricky to implement,<br>
because we would need the renderer to produce a framebuffer before we<br>
can test. It will also depend on atomic modesetting in the kernel.<br>
<br>
We really should handle KMS failures better and do the testing at<br>
configuration stage, but it hasn't been a development priority yet.<br>
Sorry.<br>
<br>
<br>
Thanks,<br>
pq<br>
</blockquote></div></div></div>