RenderOptions available in MeshComponent#78
Closed
Remscar wants to merge 428 commits intoFacepunch:masterfrom
Closed
RenderOptions available in MeshComponent#78Remscar wants to merge 428 commits intoFacepunch:masterfrom
RenderOptions available in MeshComponent#78Remscar wants to merge 428 commits intoFacepunch:masterfrom
Conversation
Renderer.RenderOptions available in MeshComponentRenderOptions available in MeshComponent
Member
|
Something for @aylaylay to think about |
Contributor
Author
|
@aylaylay My use case for this is I would like to create a shadow casting volume without having the actual mesh be visible to the player, similar to solid block light in hammer |
--------- Co-authored-by: DrakeFruit <foxflowgaming@gmail.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…acepunch#3613) * Fixes GameObject references in GameObjectSystem NetLists and NetDictionaries being null on clients. * dotnet format --------- Co-authored-by: Andy <10728824+andy013@users.noreply.github.com>
Tint pause button blue when the game is paused.
- `PolygonMesh.SetFaceTextureCoords()` now properly sets `IsDirty` - Added `PolygonMesh.GetFaceTextureCoords()` - Added `FastTextureWindow` (which extends RectEditor.Window) and `FastTextureSettings` classes - Added `MeshRectangle` which is a RectEditor `Rectangle` that contains faces from a mesh unwrapped within the rectangle, reflecting any transform changes made back to the associated mesh faces - Added `EdgeAwareFaceUnwrapper` class which handles all UV unwrapping - Added a "Fast Texturing Tool" button to the Mapping Tool's Texture Mode which opens a FastTextureWindow with the selected faces. This can also be opened with the shortcut CTRL+G (from the Texture Mode OR the Face Mode) - If a Fast Texturing Tool window is open and the faces are deselected (or the user exits the Mapping Tool) the window will automatically close itself - Implemented U/V Alignment Settings (+ Horizontal/Vertical Flip) - Implemented Inset X/Y Settings - Implemented Square Unwrap, Planar Unwrap, and Use Existing mapping modes - If the selected material has a rect asset, you can double-click on a rect to automatically fit your UV rectangle to the one you double-clicked. (You can also toggle the visibility of the material's rects) - Implemented the "Pick Edge" button which allows you to select an edge from the unwrap and automatically orient the UVs so that the selected edge is aligned with the grid. - Added `Rectangle,CanDelete`, used by MeshRectangles so they cant be deleted - Fixed `RectView.DragResizeRect` behaviour so that resizing a rect will snap the dragged edges to the grid instead of just increasing/decreasing by the grid size - Added Panning/Zooming to the Rect Editor - Disabling the Grid in the RectEditor now disables grid snapping - Can now resize rects in on themselves to resize in the other direction without making an invalid rect - Added Tile View to RectView
Co-authored-by: J Shwiizzle <160753124+SwagAccount@users.noreply.github.com>
Fixes Facepunch/sbox-issues#9744
Contributor
|
Sorry, I didn't get the notification. Yeah this seems ok. |
* Extended whitelist tests to use the other method of creating a compiler without explicit compiler settings * Initialize Compiler._config as it's a struct so everything was zeroed before
* Use MathF instead of Math for vector3 math * Vectorize Sort and Negate * Skip unnecessary dot products * Add tests for changed methods
* Add MathX.ExponentialDecay, similar to our C++ version of it * Replace SmoothDamp usage in audio components with expdecay
* Add Ctrl+A select all shortcut for track list * Simplify how raw sample data is stored in movie projects * Add Create Missing References track context menu option * Creates GameObjects / Components for the track to target if they don't exist * Support .movie resources that only contain compiled data * Default to only root tracks being expanded * Support List<T> in movies * Clean up timeline view transform code, get vertical scroll bar working again * Fix reversed focused check when clicking on a timeline track * Timeline tick tweaks
… crash when calling in event callbacks (Facepunch#3889)
Contributor
Author
|
@handsomematt you got it boss |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds RenderOptions support to MeshComponent, enabling advanced rendering control such as rendering to specific layers (Game, Overlay, Bloom, AfterUI). This allows MeshComponent to have the same rendering flexibility as ModelRenderer, particularly enabling invisible meshes that cast shadows.
Changes:
- Added
RenderOptionsproperty with lazy initialization pattern matching the Renderer base class - Added
OnRenderOptionsChangedcallback that updates the SceneObject when render options change - Applied RenderOptions to the SceneObject in
UpdateSceneObject()
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR adds a
RenderOptionsmember toMeshComponentand applies the options onto the SceneObject.They are used and operate the same way that
ModelRendererimplements them.This ultimately allows invisible MeshComponent's which cast shadows; before if you selected "Hide in Game" and had rendering to "Shadows Only", no shadows would be cast.