-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rename uniformBuffer to Ubo for consistency
- Loading branch information
1 parent
2a2726e
commit 9fd9c46
Showing
37 changed files
with
206 additions
and
211 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { ExtensionType } from '../../../extensions/Extensions'; | ||
import { UboSystem } from '../shared/shader/UboSystem'; | ||
import { createUboElementsSTD40 } from './shader/utils/createUboElementsSTD40_'; | ||
import { createUboSyncFunctionSTD40 } from './shader/utils/createUboSyncSTD40'; | ||
|
||
/** | ||
* System plugin to the renderer to manage uniform buffers. But with an WGSL adaptor. | ||
* @memberof rendering | ||
*/ | ||
export class GlUboSystem extends UboSystem | ||
{ | ||
/** @ignore */ | ||
public static extension = { | ||
type: [ExtensionType.WebGLSystem], | ||
name: 'ubo', | ||
} as const; | ||
|
||
constructor() | ||
{ | ||
super({ | ||
createUboElements: createUboElementsSTD40, | ||
generateUboSync: createUboSyncFunctionSTD40, | ||
}); | ||
} | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
src/rendering/renderers/gl/shader/utils/createUboSyncSTD40.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* eslint-disable quote-props */ | ||
|
||
import { createUboSyncFunction } from '../../../shared/shader/utils/createUboSyncFunction_'; | ||
import { uboSyncFunctionsSTD40 } from '../../../shared/shader/utils/uboSyncFunctions'; | ||
import { generateArraySyncSTD40 } from './generateArraySyncSTD40'; | ||
|
||
import type { UboElement, UniformsSyncCallback } from '../../../shared/shader/types'; | ||
|
||
export function createUboSyncFunctionSTD40( | ||
uboElements: UboElement[], | ||
): UniformsSyncCallback | ||
{ | ||
return createUboSyncFunction( | ||
uboElements, | ||
'uboStd40', | ||
generateArraySyncSTD40, | ||
uboSyncFunctionsSTD40, | ||
); | ||
} |
19 changes: 0 additions & 19 deletions
19
src/rendering/renderers/gl/shader/utils/createUniformBufferSyncSTD40.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { ExtensionType } from '../../../extensions/Extensions'; | ||
import { UboSystem } from '../shared/shader/UboSystem'; | ||
import { createUboElementsWGSL } from './shader/utils/createUboElementsWGSL_'; | ||
import { createUboSyncFunctionWGSL } from './shader/utils/createUboSyncFunctionWGSL'; | ||
|
||
/** | ||
* System plugin to the renderer to manage uniform buffers. With a WGSL twist! | ||
* @memberof rendering | ||
*/ | ||
export class GpuUboSystem extends UboSystem | ||
{ | ||
/** @ignore */ | ||
public static extension = { | ||
type: [ExtensionType.WebGPUSystem], | ||
name: 'ubo', | ||
} as const; | ||
|
||
constructor() | ||
{ | ||
super({ | ||
createUboElements: createUboElementsWGSL, | ||
generateUboSync: createUboSyncFunctionWGSL, | ||
}); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.