Brush Editing Branch
I ported it to 2.0 - I might not have tested it in 2.0 😉
20 Replies
Hmm, well, seems to have some problems. Attempted to load in unity.
ignoring the error gives me these
ignoring the error gives me these
looks easy to fix.
on your side or mine?
what happened there?
me
Just pushed a fix
Alright, thanks will take a look at it now
1. Set up the file
2. Made a sketch
3. Created a user brush
4. Added to sketch and saved
5. Recorded video.
All is great so far 6. Stopped game 7. Attempted to render 360 video [didn't work, just recorded background] 8. cancelled render (although maybe it still kept running) and deleted the render folder 9. reloaded game 10. Attempted to load saved sketch
All is great so far 6. Stopped game 7. Attempted to render 360 video [didn't work, just recorded background] 8. cancelled render (although maybe it still kept running) and deleted the render folder 9. reloaded game 10. Attempted to load saved sketch
DirectoryNotFoundException: Could not find a part of the path 'C:\Users\shape\Documents\Open Brush\Sketches\Untitled_634.tilt\Brushes'.
System.IO.Enumeration.FileSystemEnumerator
1[TResult].CreateDirectoryHandle (System.String path, System.Boolean ignoreNotFound) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Enumeration.FileSystemEnumerator1[TResult]..ctor (System.String directory, System.IO.EnumerationOptions options) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Enumeration.FileSystemEnumerable
1+DelegateEnumerator[TResult]..ctor (System.IO.Enumeration.FileSystemEnumerable1[TResult] enumerable) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Enumeration.FileSystemEnumerable
1[TResult]..ctor (System.String directory, System.IO.Enumeration.FileSystemEnumerable1+FindTransform[TResult] transform, System.IO.EnumerationOptions options) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Enumeration.FileSystemEnumerableFactory.UserFiles (System.String directory, System.String expression, System.IO.EnumerationOptions options) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Directory.InternalEnumeratePaths (System.String path, System.String searchPattern, System.IO.SearchTarget searchTarget, System.IO.EnumerationOptions options) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Directory.GetFiles (System.String path, System.String searchPattern, System.IO.EnumerationOptions enumerationOptions) (at <75633565436c42f0a6426b33f0132ade>:0)
System.IO.Directory.GetFiles (System.String path) (at <75633565436c42f0a6426b33f0132ade>:0)
TiltBrush.FolderOrZipReader.GetContentsAt (System.String path) (at Assets/Scripts/Save/FolderOrZipReader.cs:163)
TiltBrush.TiltFile.GetContentsAt (System.String path) (at Assets/Scripts/Save/TiltFile.cs:149)
TiltBrush.DiskSceneFileInfo.GetContentsAt (System.String path) (at Assets/Scripts/Save/DiskSceneFileInfo.cs:368)
TiltBrush.SaveLoadScript.Load (TiltBrush.SceneFileInfo fileInfo, System.Boolean bAdditive) (at Assets/Scripts/Save/SaveLoadScript.cs:696)
TiltBrush.SketchControlsScript.LoadSketch (TiltBrush.SceneFileInfo fileInfo, System.Boolean quickload, System.Boolean additive) (at Assets/Scripts/SketchControlsScript.cs:4108)
TiltBrush.SketchControlsScript.IssueGlobalCommand (TiltBrush.SketchControlsScript+GlobalCommands rEnum, System.Int32 iParam1, System.Int32 iParam2, System.Str
Followed by multiple copies of a height errorArgumentException: RenderTextureDesc height must be greater than zero.
Parameter name: desc.height
UnityEngine.RenderTexture.ValidateRenderTextureDesc (UnityEngine.RenderTextureDescriptor desc) (at <4746c126b0b54f3b834845974d1a9190>:0)
UnityEngine.RenderTexture.GetTemporary (UnityEngine.RenderTextureDescriptor desc) (at <4746c126b0b54f3b834845974d1a9190>:0)
UnityEngine.RenderTexture.GetTemporaryImpl (System.Int32 width, System.Int32 height, System.Int32 depthBuffer, UnityEngine.Experimental.Rendering.GraphicsFormat colorFormat, System.Int32 antiAliasing, UnityEngine.RenderTextureMemoryless memorylessMode, UnityEngine.VRTextureUsage vrUsage, System.Boolean useDynamicScale) (at <4746c126b0b54f3b834845974d1a9190>:0)
UnityEngine.RenderTexture.GetTemporary (System.Int32 width, System.Int32 height, System.Int32 depthBuffer, UnityEngine.RenderTextureFormat format) (at <4746c126b0b54f3b834845974d1a9190>:0)
SENaturalBloomAndDirtyLens.OnRenderImage (UnityEngine.RenderTexture source, UnityEngine.RenderTexture destination) (at Assets/ThirdParty/Sonic Ether/Natural Bloom/Scripts/SENaturalBloomAndDirtyLens.cs:123)
UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr, Boolean&)
send me the .tilt file?
ok
there's the brushes folder with the one custom brush if you need it as well
that tilt file is weird. i can't unzip it.
Also - the error said "Untitled_634.tilt" - not Untitled_633.tilt
oh, hmm. Probably user error. Maybe had two copies. Will check
It's definitely freaking out on load. When loading 633. Tried to stop the game, clear console, still keeps popping errors. Possible that I corrupted the whole thing.
Will reinstall from scratch and try again.
Simplified
1. Install game
2. make sketch with wind brush
3. activated modify brush tool
4. added a stroke with the modified wind brush (from previous test)
5. saved
6. Attempt to load (blank screen loads)
Just pushed a fix that appears to solve that. Also - fallback brushes kinda worked I think? There was something created for each stroke (it used "Wind" for some reason. I was in mono mode so I didn't try rebrushing)
Is there somewhere you can set the fallback brush for your custom brushes?
I think those get set in the shader scripts.
The brush.cfg file has these entries (examples):
Not really sure how the fallback brushes thing works. Does seem that there are a pretty minimal number of "raw types" of strokes, My impression is that eveything is pretty much a hull, a line, a strip/flatbrush, or a tube, at it's root. If that's correct, then it might make sense to use that to choose a fallback brush. Will check out the fix, see what happens. Thanks
The brush.cfg file has these entries (examples):
"VariantOf": "f73ec0e7-a844-4e38-82e3-140c44772699
"Shader": "Brush/StandardDoubleSided"
"BrushDescriptionVersion": 1
I'd guess it's checking the shader itself or the shader from the source variant?
BrushDescriptionVersion might be useful for a more globally oriented update, depending on how it works
In the above sketch, the fallback was for wind because the main brush used was wind, and the modified brush was a wind variant
Pretty sure I just used the two to keep it simple.Not really sure how the fallback brushes thing works. Does seem that there are a pretty minimal number of "raw types" of strokes, My impression is that eveything is pretty much a hull, a line, a strip/flatbrush, or a tube, at it's root. If that's correct, then it might make sense to use that to choose a fallback brush. Will check out the fix, see what happens. Thanks
TESTED NEW VERSION
Having a bit of trouble with brushes retaining data.
Example. Created and recorded this sketch
Example. Created and recorded this sketch
When reloaded the sketch looked like this
After editing the brush again saving, exiting, saving unity and reloading...
the sketch loaded successfully using the brush data after I remade the brush. (need further testing to see which of those are essential)
This is probably a legacy issue, been a while since I made one in game
Seems that it is mostly an issue of getting the modified brush to save properly. Maybe the changes get discarded if the game delays the write step for the brush?
Next, will check if this version will 3d record
Alright. Seems to be fixed, can see scaling and is generating an issue. Consider brush memory a fairly minor issue at this point. Can be worked around
Nice work! Thanks!