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

feat(web): support HBAO #569

Merged
merged 6 commits into from
Jul 12, 2023
Merged

feat(web): support HBAO #569

merged 6 commits into from
Jul 12, 2023

Conversation

keiya01
Copy link
Member

@keiya01 keiya01 commented Jul 11, 2023

Overview

Ported https://github.com/takram-design-engineering/plateau-view/tree/main/libs/cesium-hbao

Default AmbientOcclusion
Screenshot 2023-07-11 at 17 19 06 Screenshot 2023-07-11 at 17 01 45

What I've done

  • Added the following APIs
type SceneProperty = {
  // ...
  ambientOcclusion?: {
    enabled?: boolean;
    quality?: "low" | "medium" | "high" | "extreme";
    intensity?: number; // default: 100
    ambientOcclusionOnly?: boolean; // For debug
  };
  // ...
};

What I haven't done

How I tested

const tilesetId = reearth.layers.add({
  type: "simple",
  data: {
    type: "3dtiles",
    url: "https://assets.cms.plateau.reearth.io/assets/4f/702958-5009-4d6b-a2e0-157c7e573eb2/13100_tokyo23-ku_2022_3dtiles%20_1_1_op_bldg_13101_chiyoda-ku_lod2_no_texture/tileset.json",
  },
  "3dtiles": {
      pbr: false
  }
});
setTimeout(()=>{
  reearth.camera.flyTo(tilesetId);
  reearth.scene.overrideProperty({
      ambientOcclusion: {
          enabled: true,
          quality: "medium",
      }
  });
}, 10);

Which point I want you to review particularly

Memo

@keiya01 keiya01 self-assigned this Jul 11, 2023
@netlify
Copy link

netlify bot commented Jul 11, 2023

Deploy Preview for reearth-web ready!

Name Link
🔨 Latest commit 6e515f9
🔍 Latest deploy log https://app.netlify.com/sites/reearth-web/deploys/64adf46a5e10d60008fc7260
😎 Deploy Preview https://deploy-preview-569--reearth-web.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@github-actions github-actions bot added the web label Jul 11, 2023
@keiya01 keiya01 changed the title Feat/hbao feat: support HBAO Jul 11, 2023
@keiya01 keiya01 changed the title feat: support HBAO feat(web): support HBAO Jul 11, 2023
@keiya01 keiya01 marked this pull request as ready for review July 11, 2023 08:12
@github-actions github-actions bot requested a review from nina992 July 11, 2023 08:12
@codecov
Copy link

codecov bot commented Jul 11, 2023

Codecov Report

Merging #569 (cde016b) into main (215c735) will decrease coverage by 0.12%.
The diff coverage is 1.00%.

❗ Current head cde016b differs from pull request most recent head 6e515f9. Consider uploading reports for the commit 6e515f9 to get more accurate results

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #569      +/-   ##
==========================================
- Coverage   28.65%   28.53%   -0.12%     
==========================================
  Files        1376     1385       +9     
  Lines      149256   149897     +641     
  Branches     3573     3587      +14     
==========================================
+ Hits        42762    42769       +7     
- Misses     105342   105976     +634     
  Partials     1152     1152              
Flag Coverage Δ
web 26.43% <1.00%> (-0.14%) ⬇️
web-beta 26.43% <1.00%> (-0.14%) ⬇️
web-classic 26.43% <1.00%> (-0.14%) ⬇️
web-utils 26.43% <1.00%> (-0.14%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
web/src/beta/lib/core/Map/types/index.ts 0.00% <0.00%> (ø)
...nes/Cesium/PostProcesses/hbao/AmbientOcclusion.tsx 0.00% <0.00%> (ø)
...m/PostProcesses/hbao/AmbientOcclusionOutputType.ts 0.00% <0.00%> (ø)
...b/core/engines/Cesium/PostProcesses/hbao/config.ts 0.00% <0.00%> (ø)
.../PostProcesses/hbao/createAmbientOcclusionStage.ts 0.00% <0.00%> (ø)
...tProcesses/hbao/createCrossBilateralFilterStage.ts 0.00% <0.00%> (ø)
...ib/core/engines/Cesium/PostProcesses/hbao/index.ts 0.00% <0.00%> (ø)
.../lib/core/engines/Cesium/helpers/createUniforms.ts 0.00% <0.00%> (ø)
.../beta/lib/core/engines/Cesium/hooks/useInstance.ts 0.00% <0.00%> (ø)
...eta/lib/core/engines/Cesium/hooks/useSceneEvent.ts 0.00% <0.00%> (ø)
... and 16 more

@keiya01 keiya01 requested a review from pyshx July 11, 2023 08:13
@keiya01 keiya01 enabled auto-merge (squash) July 12, 2023 00:31
@keiya01 keiya01 merged commit d5b3c94 into main Jul 12, 2023
10 checks passed
@keiya01 keiya01 deleted the feat/hbao branch July 12, 2023 00:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants