Get on:
Sales on Unity Assets Store
Experience right now on:
Online Demo
This is a texture paint toolset,you can use in Unity RawImage/Sprite/Mesh Texture/Unity Edtior UI/other UI system;
- Paint in runtime
- Paint in editor mode
- Paint in GPU
- Solid brush
- Texture brush
- Graphic brush
- Composite brush
- Fill Tool
- Pixel Mode
- More blend type
- Post effect
- Undo/Redo
- Import uPainter package into your project
- After compiled, click menu "uPainter/AddSamples" to add samples scenes to Build Setting, ensure you can run the samples correctly
- Open demo scene "uPainter/Samples/Samples.unity"
- Click one sample
- Draw on canvas
- Editor sample just click menu "uPainter/EditorDemo"
- Create a new scene
- Add a Empty Object in Canvas, and stretch to fit size
- Add PaintRawImage to this
- Create a solid brush:in assets window, click right mouse button, select in path "Create/uPainter/SolidBrush"
- Modify brush's attributes
- Assign the solid brush to RawImagePaintCanvs's "Brush" property
- Draw on canvas
Paint solid color to texture
Brush Color: color of brush
Size: size of brush,value Range(0,1)Point Distance Interval: the minimum distance of last two points
Self Overlay: whether or not overlay self in on paint life circleBlend Mode: blend type with layer texture
- Normal: Default mode
- Restore: Easer use this mode
- Replace: Scratch card use this mode
- Darken
- Mutipy
- ColorBurn
- LinearDark
- Lighten
- ColorScreen
- ColorDodge
- LinearDodge
- Overlay
- HardLight
- SoftLight
- VividLight
- PinLight
- LinearLight
- HardMix
- Difference
- Exclusion
- Subtract
- Add
Pixel Mode: If true, the input uv will be modify clamp to pixel cell, the layer filter mode must be point, then can get perfect effect, and you need set a correct layer and brush size
Softness: softness of brush,useful highlight effect, value Range(0,1),default is 0
Noise Rate: mask brush with noise, can use this property to simulation uneven effect,such as crayon pen, only value bigger than 0 can be effective,value Range(0,1)
Noise Size: set the noise size, only noise rate bigger than 0 can be effective,value Range(0,1)Paint Mode: Brush paint mode, has Dash/Line mode
Cap Style: Brush cap styles, has Flat/Round mode
Line Joint Style: The corner style just effect in line paint mode, has Round/Flat/Sharp mode
Paint texture to target texture
Brush Texture: The brush texture
Rotate Angle: Anticlockwise angle in degree of brush textureRotate Fllow Direction: When in dash mode, the texture will rotate by the direction between two points
Tilling: Repeat count of texture, when enable global uv,the tilling means global repeat count,Range(0,1)Offset: Offset of texture uv,Range(0,1)
Enable Gloable UV: Use global texture uv,effected by brush size,can use to mosaic effect
Enable Gloable Reapeat Count: If true, will ignore brush size, only effected by tilling value
Use GL mode to draw lines,can paint lines to texture
Line Count: The count of lines
This is a brush group effect brush,can overlay many brush effect in one paint
Brushes: Composite's sub brushes, overlay order by array index
When paint done, post effect will process the texture, add effect to the result,the effect can be multiple in brush, inner effect has:
Blur Brush Post
Outline Brush Post
Drawer Painter interaction proxy, will handle touch input, we use drawer to create more texture painter, like raw image drawer, other ui system drawer and mesh drawer(need mesh collider)
Replace Brush: When canvas is empty, this property will set to canvas brush
Show Preview: If true, will show cursor on texture
Simulate Pressure: If true, will simulate the pressure, distance between two points is more larger ,the size will more small;
There has interface to extend, you owen simulate method, even use real touch sensor data;Brush Pressure Strength: The strength of pressure, the value is more larger, the line will more thinner, value range(0,1)
Corner Smooth: Corner smooth strength, value range(0,0.5) (In older device you can set this value to ZERO)
Use Shader Smooth: If true, use shader bezier curve, or calucate in cpu, Graphic/Line Brush do not support shader smooth
Curve Interpolation: Only when do not use shader smooth mode, will decide how many segments number of the bezier curve, the value is larger, the line will more smooth, and need more caculation,value range(0,5)
PainterOperation is a undo/redo system, default max undo/redo step is 10, you can extend this system to save command result to disk,so you can use limitless undo/redo operate;
Sample undo/redo code:
PainterOperation.Instance.Undo()
PainterOperation.Instance.Redo()