Bug 1524591 Comment 3 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

(In reply to Jim Mathies [:jimm] from comment #2)

> From looking over the docs on this, it isn't clear why we used the browser window as a parent. Looks like chrome creates the parent in the gpu as a hidden popup. So maybe there's a fourth workaround - create the parent and child in the gpu.

Thanks for the detailed information. Current implementation mimics how chromium implements except the followings
-[1] Do not use HiddenPopupWindow as initial parent window.
-[2] Do not call ::SetParent() in UI process

HiddenPopupWindow was created just for initial parent window. The parent window is soon replaced by HWND of Main window in UI Process by calling ::SetParent() like the following sequence.

ChildWindowWin::Initialize()
->GLES2CommandBufferStub::DidCreateAcceleratedSurfaceChildWindow()
->GpuServiceImpl::SendCreatedChildWindow()
->GpuHostProxy::SetChildSurface()
->//IPC
->GpuHostImpl::SetChildSurface()
->RenderingWindowManager::RegisterChild()
->::SetParent(child, parent);

I removed [1] and [2] since, it succeeded to create child window of MainWindow in GPU process. Reviving [1] and [2] seemed to address the problem of Bug 1347710 Comment 20.
(In reply to Jim Mathies [:jimm] from comment #2)

> From looking over the docs on this, it isn't clear why we used the browser window as a parent. Looks like chrome creates the parent in the gpu as a hidden popup. So maybe there's a fourth workaround - create the parent and child in the gpu.

Thanks for the detailed information. Current implementation mimics how chromium implements except the followings
-[1] Do not use HiddenPopupWindow as initial parent window.
-[2] Do not call ::SetParent() in UI process

In chromium, HiddenPopupWindow was created just for initial parent window. The parent window is soon replaced by HWND of Main window in UI Process by calling ::SetParent() like the following sequence.

ChildWindowWin::Initialize()
->GLES2CommandBufferStub::DidCreateAcceleratedSurfaceChildWindow()
->GpuServiceImpl::SendCreatedChildWindow()
->GpuHostProxy::SetChildSurface()
->//IPC
->GpuHostImpl::SetChildSurface()
->RenderingWindowManager::RegisterChild()
->::SetParent(child, parent);

I removed [1] and [2] since, it succeeded to create child window of MainWindow in GPU process. Reviving [1] and [2] seemed to address the problem of Bug 1347710 Comment 20.
(In reply to Jim Mathies [:jimm] from comment #2)

> From looking over the docs on this, it isn't clear why we used the browser window as a parent. Looks like chrome creates the parent in the gpu as a hidden popup. So maybe there's a fourth workaround - create the parent and child in the gpu.

Thanks for the detailed information. Current implementation mimics how chromium implements except the followings
-[1] Do not use HiddenPopupWindow as initial parent window.
-[2] Do not call ::SetParent() in UI process

In chromium, HiddenPopupWindow was created just for initial parent window. The parent window is soon replaced by HWND of Main window in UI Process by calling ::SetParent() in UI process like the following sequence.

ChildWindowWin::Initialize()
->GLES2CommandBufferStub::DidCreateAcceleratedSurfaceChildWindow()
->GpuServiceImpl::SendCreatedChildWindow()
->GpuHostProxy::SetChildSurface()
->//IPC
->GpuHostImpl::SetChildSurface()
->RenderingWindowManager::RegisterChild()
->::SetParent(child, parent);

I removed [1] and [2] since, it succeeded to create child window of MainWindow in GPU process. Reviving [1] and [2] seemed to address the problem of Bug 1347710 Comment 20.
(In reply to Jim Mathies [:jimm] from comment #2)

> From looking over the docs on this, it isn't clear why we used the browser window as a parent. Looks like chrome creates the parent in the gpu as a hidden popup. So maybe there's a fourth workaround - create the parent and child in the gpu.

Thanks for the detailed information. Current implementation mimics how chromium implements except the followings
-[1] Do not use HiddenPopupWindow as initial parent window.
-[2] Do not call ::SetParent() in UI process

In chromium, HiddenPopupWindow was created just for initial parent window. The parent window is soon replaced by HWND of Main window in UI Process by calling ::SetParent() in UI process like the following sequence.

ChildWindowWin::Initialize()
->GLES2CommandBufferStub::DidCreateAcceleratedSurfaceChildWindow()
->GpuServiceImpl::SendCreatedChildWindow()
->GpuHostProxy::SetChildSurface()
->// IPC
->// UI process
->GpuHostImpl::SetChildSurface()
->RenderingWindowManager::RegisterChild()
->::SetParent(child, parent);

I removed [1] and [2] since, it succeeded to create child window of MainWindow in GPU process. Reviving [1] and [2] seemed to address the problem of Bug 1347710 Comment 20.
(In reply to Jim Mathies [:jimm] from comment #2)

> From looking over the docs on this, it isn't clear why we used the browser window as a parent. Looks like chrome creates the parent in the gpu as a hidden popup. So maybe there's a fourth workaround - create the parent and child in the gpu.

Thanks for the detailed information. Current implementation mimics how chromium implements except the followings
-[1] Do not use HiddenPopupWindow as initial parent window.
-[2] Do not call ::SetParent() in UI process

In chromium, HiddenPopupWindow was created just for initial parent window. The parent window is soon replaced by HWND of Main window in UI Process by calling ::SetParent() in UI process like the following sequence.

ChildWindowWin::Initialize()
->GLES2CommandBufferStub::DidCreateAcceleratedSurfaceChildWindow()
->GpuServiceImpl::SendCreatedChildWindow()
->GpuHostProxy::SetChildSurface()
->// IPC
->// In UI process
->GpuHostImpl::SetChildSurface()
->RenderingWindowManager::RegisterChild()
->::SetParent(child, parent);

I removed [1] and [2] since, it succeeded to create child window of MainWindow in GPU process. Reviving [1] and [2] seemed to address the problem of Bug 1347710 Comment 20.
(In reply to Jim Mathies [:jimm] from comment #2)

> From looking over the docs on this, it isn't clear why we used the browser window as a parent. Looks like chrome creates the parent in the gpu as a hidden popup. So maybe there's a fourth workaround - create the parent and child in the gpu.

Thanks for the detailed information. Current implementation mimics how chromium implements except the followings
-[1] Do not use HiddenPopupWindow as initial parent window.
-[2] Do not call ::SetParent() in UI process for setting parent window from HiddenPopupWindow to MaingWindow

In chromium, HiddenPopupWindow was created just for initial parent window. The parent window is soon replaced by HWND of Main window in UI Process by calling ::SetParent() in UI process like the following sequence.

ChildWindowWin::Initialize()
->GLES2CommandBufferStub::DidCreateAcceleratedSurfaceChildWindow()
->GpuServiceImpl::SendCreatedChildWindow()
->GpuHostProxy::SetChildSurface()
->// IPC
->// In UI process
->GpuHostImpl::SetChildSurface()
->RenderingWindowManager::RegisterChild()
->::SetParent(child, parent);

I removed [1] and [2] since, it succeeded to create child window of MainWindow in GPU process. Reviving [1] and [2] seemed to address the problem of Bug 1347710 Comment 20.

Back to Bug 1524591 Comment 3