Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The ViewHelper shows different Y-axis positions between WebGL and WebGPU renderers. #30729

Open
Child-qjj opened this issue Mar 12, 2025 · 0 comments

Comments

@Child-qjj
Copy link

Description

maybe because of the different coordinate systems in WebGL and WebGPU ?

Can be resolved by add follow codes in ViewHelper.js?

			const x = domElement.offsetWidth - dim;
                         const y = renderer.isWebGPURenderer ? domElement.offsetHeight - dim : 0;

			renderer.clearDepth();

			renderer.getViewport( viewport );
			renderer.setViewport( x, y, dim, dim );

Reproduction steps

  1. use the viewHelper in WebRenderer and WebGPURenderer
  2. the viewHelper in different position

Code

// code goes here

Live example

Screenshots

Image

Version

r.0.174

Device

Desktop

Browser

Chrome

OS

MacOS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant