Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (533)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Outlining a Mesh?  (Read 372 times)
0 Members and 1 Guest are viewing this topic.
Online Longarmx
« Posted 2014-02-12 05:31:35 »

So, I have been googling this problem for a couple days but I can't come to a definite answer. What I want to achieve is render an outline of a mesh to create a look like Antichamber. I have found three possible solutions so far.

1. Use Sobel Operator to determine the outline of the mesh (This may not work with single color meshes)
2. Use Cel Shading to generate outline using back rendered faces of the mesh drawn a second time. (I don't know how costly this will be.)
3. Create the texture/outline meshes by hand. (This is the least preferred due to the amount of manual work involved)

So I was wondering what you guys think about this? Am I on the right track with one of these three, and if so, what one is the best option?

Thanks,
Longarmx

Offline Longor1996
« Reply #1 - Posted 2014-02-12 17:01:55 »

-snip to get rid of quote quota-

Antichamber uses Sobel-Cel-Shading (Sobel-Operator as you call it).
Don't ask me, I don't know how it works.

- Longor1996

Sorry for my bad English! That's because i am from Germany.
Offline matheus23

JGO Kernel


Medals: 106
Projects: 3


You think about my Avatar right now!


« Reply #2 - Posted 2014-02-12 18:41:48 »

1. I wouldn't use Sobel on the colors, when I have a depth buffer Wink You can 'simply' run the Sobel Operator on the Depth buffer and it works no matter what colour the meshes are. That version has trouble finding an outline, if two sheets of paper lie on top of each other in your scene, for example (when the depth value difference is small)

2. It's exactly as costly as rendering your object without doing fancy fragment operations (for example lightning). Depending on how costly your fragment operations are, it's from about 1.5 times to twice as costly Smiley

I'm by no means an OpenGL expert, but these are my thoughts, I hope, they're still helpful Wink

See my:
    My development Blog:     | Or look at my RPG | Or simply my coding
http://matheusdev.tumblr.comRuins of Revenge  |      On Github
Pages: [1]
  ignore  |  Print  
 
 

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

pw (24 views)
2014-07-24 01:59:36

Riven (23 views)
2014-07-23 21:16:32

Riven (18 views)
2014-07-23 21:07:15

Riven (21 views)
2014-07-23 20:56:16

ctomni231 (50 views)
2014-07-18 06:55:21

Zero Volt (45 views)
2014-07-17 23:47:54

danieldean (36 views)
2014-07-17 23:41:23

MustardPeter (39 views)
2014-07-16 23:30:00

Cero (54 views)
2014-07-16 00:42:17

Riven (54 views)
2014-07-14 18:02:53
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!