Alpha textures Always Behind Grease Pencils #59979

Closed
opened 2018-12-30 08:14:20 +01:00 by Daniel Oakey · 12 comments

System Information
Operating system: Arch Linux
Graphics card: GTX 1060

Blender Version
Broken: 2.80, 266b1e2cdb

Short description of error
Import an image as plane with a transparent texture. The grease pencil object will always be rendered in front

Exact steps for others to reproduce the error

  1. Import the provided laser.png image into blender using the images-as-planes add-on
  2. In the Materials section of the Properties window, set the Blend mode to either Alpha Blend or Multiply
  3. Add a grease pencil monkey (or any grease pencil object with a drawing)
  4. Rotate the camera --> the image plane will be rendered behind the camera no matter the orientation

laser.png

demo.gif

**System Information** Operating system: Arch Linux Graphics card: GTX 1060 **Blender Version** Broken: 2.80, 266b1e2cdbc1 **Short description of error** Import an image as plane with a transparent texture. The grease pencil object will always be rendered in front **Exact steps for others to reproduce the error** 1. Import the provided laser.png image into blender using the images-as-planes add-on 2. In the Materials section of the Properties window, set the Blend mode to either Alpha Blend or Multiply 3. Add a grease pencil monkey (or any grease pencil object with a drawing) 4. Rotate the camera --> the image plane will be rendered behind the camera no matter the orientation ![laser.png](https://archive.blender.org/developer/F6114536/laser.png) ![demo.gif](https://archive.blender.org/developer/F6114541/demo.gif)
Author

Added subscriber: @doakey3

Added subscriber: @doakey3
Antonio Vazquez was assigned by Sebastian Parborg 2018-12-31 16:50:22 +01:00

Added subscriber: @info-27

Added subscriber: @info-27
Antonio Vazquez was unassigned by Dalai Felinto 2019-12-23 16:35:30 +01:00

Added subscriber: @antoniov

Added subscriber: @antoniov

This comment was removed by @antoniov

*This comment was removed by @antoniov*

Added subscriber: @fclem

Added subscriber: @fclem

@fclem I have tested with new engine and still does the same. Do you think this is a design limitation?

@fclem I have tested with new engine and still does the same. Do you think this is a design limitation?
[Test_file.blend](https://archive.blender.org/developer/F8297481/Test_file.blend)

Yes this is because we are rendering in layers. The GPencil engine cannot know that something has been rendered and is transparent in front of it unless it has been written to the depth buffer.

There is no real workaround this it is a limitation of the way things works.

Yes this is because we are rendering in layers. The GPencil engine cannot know that something has been rendered and is transparent in front of it unless it has been written to the depth buffer. There is no real workaround this it is a limitation of the way things works.

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Antonio Vazquez self-assigned this 2020-05-11 18:12:01 +02:00

This is a design limitation impossible to solve, so we can close it... no reason to keep it open.

This is a design limitation impossible to solve, so we can close it... no reason to keep it open.

Added subscriber: @Ulf3000

Added subscriber: @Ulf3000

In #59979#857098, @fclem wrote:
Yes this is because we are rendering in layers. The GPencil engine cannot know that something has been rendered and is transparent in front of it unless it has been written to the depth buffer.

There is no real workaround this it is a limitation of the way things works.

now over a year later is there any idea to resolve this in the long run (like rendering gp objects with eevee )?

i dont know how you composit the things in code but just know that image planes and cartoon animation belong together like siamese twins and are the gold standard in 2d animation (and will never change)

it would be sad if the tool is just left so you can never do a full animation scene (or the bulk of it at least) directly in eevee and instead plan it around using aftereffects, still.


Since alpha clipped textures are working fine with grease pencil objects,

maybe adding a compositing step and reusing the alpha buffer of the image plane's shader onto a depth buffered(alphaclipped) version/copy of the alpha blended object/material (the one you use for compositing),

and therefor at least approximate the alpha blending.

You guys also approximate the camera depth blur so maybe that would be a solution ?

> In #59979#857098, @fclem wrote: > Yes this is because we are rendering in layers. The GPencil engine cannot know that something has been rendered and is transparent in front of it unless it has been written to the depth buffer. > > There is no real workaround this it is a limitation of the way things works. now over a year later is there any idea to resolve this in the long run (like rendering gp objects with eevee )? i dont know how you composit the things in code but just know that image planes and cartoon animation belong together like siamese twins and are the gold standard in 2d animation (and will never change) it would be sad if the tool is just left so you can never do a full animation scene (or the bulk of it at least) directly in eevee and instead plan it around using aftereffects, still. -------------------------------- Since alpha clipped textures are working fine with grease pencil objects, maybe adding a compositing step and reusing the alpha buffer of the image plane's shader onto a depth buffered(alphaclipped) version/copy of the alpha blended object/material (the one you use for compositing), and therefor **at least approximate the alpha blending**. You guys also approximate the camera depth blur so maybe that would be a solution ?
Sign in to join this conversation.
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset Browser
Interest
Asset Browser Project Overview
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
EEVEE & Viewport
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
EEVEE & Viewport
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Priority
High
Priority
Low
Priority
Normal
Priority
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
6 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#59979
No description provided.