Commit Graph

67 Commits

Author SHA1 Message Date
PepperCode1
af28c39a48 Streamlined internal referencing
- Remove all references to impl from api and lib packages; all internal
interaction with impl now goes through InternalFlywheelApi
- Separate and organize backend and impl mixins and extensions
- Remove camera position component getters from VisualFrameContext
- Improve accuracy of fog data update detection
- Make PoseTransformStack.stack private and add unwrap method
- Rename BackendManager.isOn -> isBackendOn (and associated methods in
other classes)
2024-01-28 15:27:02 -08:00
Jozufozu
52c31129b0 Bink and it's gone
- Remove jarjar stuffs from gradle script
2024-01-26 16:46:54 -08:00
Jozufozu
db942965a5 Get some bounding spheres at home
- Compute bounding spheres with the AABB method. Should be pretty well
  suited for funny block game.
- Remove Miniball from dependencies.
2024-01-26 16:40:15 -08:00
PepperCode1
6204acf8bf Automated nullability
- Remove most NotNull annotations
- Automatically generate missing package-info.java files which contain
annotations to establish that everything is not null by default
- Remove CurseForge integration from build script
- Fix some other formatting
2024-01-22 11:12:48 -08:00
PepperCode1
80127664d2 Fix crash after compilation error during in-world resource reload
- Store *Programs inside engines to disallow replacement and use
reference counting to delete programs at the appropriate time
- Move CompilationHarness, Compile, and SourceLoader to compile.core
- Fix packed material comments
- Fix pack.mcmeta pack format
- Remove Embeddium version range
2024-01-17 10:37:39 -08:00
Jozufozu
e582379ab5 Insanity ball
- Publish jarjar artifact as default.
- Publish slim artifact without any fancy stuff.
- Update mods.toml
  - Switch rubidium to embeddium.
  - Set displayURL to modrinth.
  - Change version related stuff to $ variables
- Add processResources step to build.gradle to populate mods.toml.
2024-01-15 17:41:17 -08:00
Jozufozu
60b3d99a43 Frag shader go brr
- Add flw_vertexDiffuse and flw_fragDiffuse to glsl api.
- Compute/apply diffuse in the fragment shader.
- Move common glsl between instancing/indirect to common.vert/.frag.
- Add a pittance more documentation to api spec.
- Sneak in a block to build.gradle to always download sources/javadoc.
2024-01-15 14:09:19 -08:00
Jozufozu
32668187c8 More artificer
- Add sources and javadoc to maven artifact
- Update artifact mc version
- Actually test publish locally :lwe:
2023-12-28 13:05:25 -08:00
Jozufozu
cb11ee030e Artifice
- Specify artifactId again in maven publication
2023-12-27 12:44:16 -08:00
PepperCode1
e68845ee3e Port fixes and other changes 2023-11-25 14:09:30 -08:00
Jozufozu
e5cda8944e Shaking things out
- Use JOML better where we can.
  - Inline MatrixUtil#store and #toJoml
  - FlwShaderUniforms keeps a scratch matrix around for mutating the
    viewProjection.
  - Directly store a Quaternion4f in OrientedInstance to avoid creating
    new objects in the batching transformers.
- Move FrameContext creation to a functor.
- We do need to check the renderDebug flag still :ioa:
- Make VisualUpdatePlan's internal plan not null.
- Remove ClientMainMixin :sad:
  - Forge's new earlywindow stuff means there's no opportunity for
    Flywheel the mod to inject renderdoc before the window is
    initialized.
  - The workaround for now is to breakpoint in FML's
    DisplayWindow#initialize and evaluate
    `System.loadLibrary("renderdoc")` manually.
2023-11-24 14:29:03 -08:00
Jozufozu
8ff208d23e Instant backport
- Switch to 1.20.1
- It still compiles!
2023-11-23 22:45:39 -08:00
Jozufozu
57faab9291 Build system but no build
- Start with a cherry pick from 1.20/dev
- Copy over newer gradle wrapper related things from the forge 1.20 mdk
- Follow example from 1.20 mdk to update build.gradle and
  settings.gradle
- Update parchment version
2023-11-22 20:57:46 -08:00
PepperCode1
6d86437514 Sweeping changes
- Add VisualizationManager and VisualManager API
- Simplify and fix memory leaks in model utilities
- Pass partialTick directly to visuals and remove AnimationTickHolder
- Fix LevelAttached and FlwTaskExecutor not being thread-safe
- Reorganize and rename many things
- Remove unnecessary things
2023-11-18 11:46:04 -08:00
Jozufozu
ce6ce841d1 Housekeeping
- Update dependencies, forge version
- Bump LICENCE year
- Use fma in MatrixUtil and VertexTransformations
- Remove some dead variables from TransformCall
- Use onSpinWait in WaitGroup#await
- Do not allow adding negative numbers to a WaitGroup
- Thin abstraction for TaskNotifier
- Clean up WorkerThread task polling
2023-05-21 15:24:33 -07:00
Jozufozu
a0b904c387 Merge branch '1.18/plan' into 1.18/next
# Conflicts:
#	src/main/java/com/jozufozu/flywheel/api/backend/Engine.java
#	src/main/java/com/jozufozu/flywheel/backend/engine/batching/BatchingEngine.java
#	src/main/java/com/jozufozu/flywheel/backend/engine/batching/TransformCall.java
#	src/main/java/com/jozufozu/flywheel/backend/engine/indirect/IndirectEngine.java
#	src/main/java/com/jozufozu/flywheel/backend/engine/instancing/InstancingEngine.java
#	src/main/java/com/jozufozu/flywheel/handler/EntityWorldHandler.java
#	src/main/java/com/jozufozu/flywheel/impl/instancing/InstancedRenderDispatcher.java
#	src/main/java/com/jozufozu/flywheel/impl/instancing/manager/InstanceManager.java
#	src/main/java/com/jozufozu/flywheel/impl/instancing/storage/AbstractStorage.java
#	src/main/java/com/jozufozu/flywheel/impl/visualization/VisualWorld.java
#	src/main/java/com/jozufozu/flywheel/mixin/instancemanage/InstanceRemoveMixin.java
#	src/main/java/com/jozufozu/flywheel/mixin/visualmanage/VisualAddMixin.java
#	src/main/java/com/jozufozu/flywheel/mixin/visualmanage/VisualUpdateMixin.java
2023-04-15 15:27:18 -07:00
PepperCode1
26cced23b4 Add Rubidium compatibility
- Add proper Rubidium compatibility on our side
- Overwrite methods in Rubidium's FlywheelCompat class with stubs to
prevent crashes
2023-04-13 10:16:33 -07:00
Jozufozu
09394efb5c Putting our plan to the test
- Implement plan simplification
- Add unit tests for plan execution and simplification
2023-04-09 14:15:29 -07:00
PepperCode1
a27fffca69 Use external JOML
- Use JOML from its official Maven source instead of bundling classes
- Organize imports
2023-03-29 22:03:28 -07:00
Jozufozu
4bb7c4bd48 Merge branch '1.18/culling' into 1.18/next
# Conflicts:
#	build.gradle
#	src/main/java/com/jozufozu/flywheel/Flywheel.java
#	src/main/java/com/jozufozu/flywheel/backend/Loader.java
#	src/main/java/com/jozufozu/flywheel/backend/instancing/InstanceWorld.java
#	src/main/java/com/jozufozu/flywheel/backend/instancing/batching/BatchingDrawTracker.java
#	src/main/java/com/jozufozu/flywheel/backend/instancing/instancing/MeshPool.java
#	src/main/java/com/jozufozu/flywheel/core/compile/ProgramCompiler.java
#	src/main/java/com/jozufozu/flywheel/core/crumbling/CrumblingRenderer.java
#	src/main/java/com/jozufozu/flywheel/core/model/ModelUtil.java
#	src/main/java/com/jozufozu/flywheel/mixin/LevelRendererMixin.java
#	src/main/java/com/jozufozu/flywheel/mixin/matrix/Matrix3fMixin.java
#	src/main/java/com/jozufozu/flywheel/mixin/matrix/Matrix4fMixin.java
2022-08-22 17:18:13 -07:00
PepperCode1
72826f1de5 No more leaks
- Free all DrawBuffers on renderer reload
- Add flw.debugMemorySafety flag to detect leaked untracked MemoryBlocks
- Replace VertexListProviderRegistry with static methods in
VertexListProvider and a VertexFormatMixin
- Make the DrawBuffer constructor accept a VertexFormat instead of a
RenderType
- Merge TStack into TransformStack
- Move all duck interfaces/extensions to extension package
- Make mixin style more consistent
2022-08-17 16:20:31 -07:00
PepperCode1
e7518d5230 Merge branch '1.18/dev' into 1.18/next
Conflicts:
	.github/ISSUE_TEMPLATE/bug_report.yml
	gradle.properties
	src/main/java/com/jozufozu/flywheel/backend/instancing/DrawBuffer.java
	src/main/java/com/jozufozu/flywheel/mixin/RenderTypeMixin.java
2022-08-16 10:48:46 -07:00
PepperCode1
527d91b8ae Fix crash with Rubidium when using batching
- Backport fix from 1.18/next
- Downgrade and lock ForgeGradle version to fix build
- Update Forge to match 1.18/next
- Bump version
2022-08-13 13:54:52 -07:00
Jozufozu
e00d5772c3 Things on the screen
- Specialize MeshPool for the indirect engine
 - Temporarily force the engine to be indirect
 - Fix compilation issues with test shaders
 - VertexAttribute supports DSA
 - Fix Miniball issues in dev-env
 - VertexList implements PointSet for use with Miniball
 - Meshes store their bounding spheres
 - Add hook/system property to load renderdoc on client launch
 - StructTypes provide separate StorageBufferWriter for indirect
2022-08-05 10:51:07 -07:00
Jozufozu
e42657cd8a Culling experiments 2: not testing the GPU
- Skeleton for compute shader culling/indirect rendering
2022-07-29 21:46:09 -07:00
Jozufozu
0b228b9db9 Merge branch '1.18/dev' into 1.18/next
# Conflicts:
#	.github/ISSUE_TEMPLATE/bug_report.yml
#	build.gradle
#	gradle.properties
#	src/main/java/com/jozufozu/flywheel/Flywheel.java
#	src/main/java/com/jozufozu/flywheel/backend/Backend.java
#	src/main/java/com/jozufozu/flywheel/backend/Loader.java
#	src/main/java/com/jozufozu/flywheel/backend/OptifineHandler.java
#	src/main/java/com/jozufozu/flywheel/backend/instancing/AbstractInstance.java
#	src/main/java/com/jozufozu/flywheel/backend/instancing/InstanceManager.java
#	src/main/java/com/jozufozu/flywheel/backend/instancing/batching/BatchedMaterialGroup.java
#	src/main/java/com/jozufozu/flywheel/core/model/BakedModelBuilder.java
#	src/main/java/com/jozufozu/flywheel/core/model/Bufferable.java
#	src/main/java/com/jozufozu/flywheel/core/model/ModelUtil.java
#	src/main/java/com/jozufozu/flywheel/core/model/WorldModel.java
#	src/main/java/com/jozufozu/flywheel/core/model/WorldModelBuilder.java
#	src/main/java/com/jozufozu/flywheel/core/vertex/BlockVertexList.java
#	src/main/java/com/jozufozu/flywheel/core/vertex/BlockVertexListUnsafe.java
#	src/main/java/com/jozufozu/flywheel/core/vertex/PosTexNormalVertexListUnsafe.java
#	src/main/java/com/jozufozu/flywheel/mixin/FrustumMixin.java
2022-07-19 00:19:50 -07:00
PepperCode1
2323e770d2 Final fix-ups
- Revert mods.toml version to ${file.jarVersion}
- Fix license not being added to built jars
- Rename LICENCE.md to LICENSE.md
2022-07-15 19:29:42 -07:00
PepperCode1
2a715dfd5d Fix mixins sometimes not remapping
- Compress logo image
2022-07-15 09:42:14 -07:00
PepperCode1
dd18300b70 Scheme-a-version
- Fix Resources not being closed properly
- Change versioning scheme to match Create
- Add LICENSE to built jar
- Fix mods.toml version sync
- Move JOML code to non-src directory
- Update Gradle
- Organize imports
2022-07-15 00:00:54 -07:00
Jozufozu
5f07fedf2e Oculus compatibility
- Rename OptifineHandler to ShadersModHandler
 - Rename functions to match fabric version
2022-07-10 18:08:59 -04:00
Jozufozu
e521bb20cf Better buffer binding
- Directly call GlBuffer#bind before raw gl calls
 - Everything else is hidden now
 - GlStateTracker.State implements AutoCloseable for try-with-resources blocks
 - Wrap InstancedModel render calls in a GlStateTracker restore block
 - Improve EBO creation
 - Track CPU memory usage (wish java had ownership concepts)
 - Misc cleanups
2022-06-09 12:44:52 -07:00
PepperCode1
e280437c4c Instant legacy code
- Respect fog shape and type
  - Add uFogShape uniform
  - Add macro for current FogType
- Respect dimension constant ambient light when calculating diffuse
  - Add uConstantAmbientLight uniform
  - Redirect diffuse calculation to FLWDiffuse
  - Do not automatically include diffuse.glsl
- Fill CoreShaderInfoMap with info for vanilla and Forge core shaders
- Use try-with-resources when querying ResourceManager
- Move WorldProgram uniform uploading from bind to uploadUniforms
- Use correct layer when rendering bells (cutout -> solid)
- Update Starlight
2022-05-13 23:58:24 -07:00
Jozufozu
a8de91d541 Layoff some workers
- Only one task engine for everything now
 - Fixes crash on LightUpdater init when Flywheel is off
 - Attempt to wrangle InstanceWorld init code
 - Misc. cleanup/renaming
2022-04-07 14:19:36 -07:00
PepperCode1
74f9e1f9a3 Update to 1.18.2
- Switch to SLF4J logging
- Bump version
- Add 0.6.1 changelog
2022-03-14 10:52:28 -07:00
PepperCode1
aa08ef1430 Add, refactor, remove
- Add DiffuseLightCalculator
- Add ModelUtil.VANILLA_RENDERER for consistent virtual rendering
- Refactor OptifineHandler
- Remove MatrixTransformStack
2022-02-08 19:26:36 -08:00
Jozufozu
283195bbd0 Towards starlight compat
- Steal Mods enum from Create.
 - Cursemaven dep for starlight

Co-authored-by: Aeiou <3160746+aeiouenigma@users.noreply.github.com>
2021-12-26 15:41:20 -08:00
Jozufozu
dbfeeea477 No more diffuse divide
- Move PlacementSimulationWorld to Flywheel as VirtualRenderWorld
 - Simplify ModelTransformer
 - Model doesn't need #configure
2021-12-25 15:51:22 -08:00
Jozufozu
de6c4270b2 Repack JOML 2021-12-24 02:21:59 -08:00
Jozufozu
aa373cbe40 Switch back to parchment, update forge 2021-12-23 23:09:51 -08:00
Jozufozu
03f513a2f1 Ready for release 2021-12-12 22:53:22 -08:00
Jozufozu
733fdbefa3 Bump version - 0.4.1 2021-12-11 17:32:39 -08:00
Jozufozu
2394b02e3d Update changelog 2021-12-09 18:51:09 -08:00
Jozufozu
46cbd76fb6 Update to 1.18 2021-12-06 21:29:21 -08:00
Jozufozu
f75d107db2 Fix weird intellij issues with mixin's annotation processor
- Update forge/mixin version
2021-12-02 14:03:14 -08:00
PepperBell
b1f34389b7 Improve StitchedSprite functionality
- Make StitchedSprite work like PartialModel
- Allow StitchedSprite instances to be created directly
- Allow StitchSprites to be created for any atlas
- Use texture stitch post event instead of lazy computation for filling
StitchedSprites
- Remove legacy method from AngleHelper
- Change artifact name from flywheel to flywheel-forge
- Organize imports
2021-11-24 18:43:05 -08:00
PepperBell
279e0893c6 Server crash fix and formatting
- Fix matrix mixins being applied on dedicated server
- Expand PartialModel functionality: add location getter and model
setter
- Remove Loader.getResourceType since selective reloading is deprecated
- Organize imports and mixin order
- Other formatting
- Update Gradle and Forge
2021-11-18 14:59:39 -08:00
Jozufozu
d0fec67b60 Parchment and gradle changes 2021-11-08 13:19:48 -08:00
Jozufozu
7c5e02d2e8 UNTESTED - Replace ATs
- Matrices use #store
 - Accessor for pausedPartialTick
2021-09-26 19:40:53 -07:00
Jozufozu
d11676cf3a MDK println build test 2021-09-18 17:01:20 -07:00
Jozufozu
7da64cded6 It renders stuff
- The lightmap moved
 - Begin to move away from access transformers
 - .textureManager -> .getTextureManager()
 - RIP cutout, saw that coming
2021-09-16 20:03:45 -07:00