Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Mug
Apr 26, 2005

Seashell Salesman posted:

Write whatever kind of three-way max you need as a macro or an inline function. I would point out, though, that if you are using Bresenham's line algorithm, doing a handful of comparisons before you go into the algorithm will be negligible compared to running the algorithm itself.

On that note, is there any other algorithms you can name that might be better for casting a ray over over three dimensions?

Adbot
ADBOT LOVES YOU

Seashell Salesman
Aug 4, 2005

Holy wow! That "Literally A Person" sure is a cool and good poster. He's smart and witty and he smells like a pure mountain stream. I posted in his thread and I got a FANCY NEW AVATAR!!!!

Mug posted:

On that note, is there any other algorithms you can name that might be better for casting a ray over over three dimensions?

There are a few ways to interpret this, I think. You can plot a 2D line between two points in 3D space on the rendered scene for it (using Bresenham's), 'cast' rays in 3D space in the conventional 3D graphics sense (I'm not a full bottle on these algorithms but should be extremely easy to find info on google), or plot some kind of a block line in 3D space. Are you trying to do that last one? In that case I have no idea off the top of my head if there is a more efficient solution than extending Bresenham's to another dimension.

Unormal
Nov 16, 2004

Mod sass? This evening?! But the cakes aren't ready! THE CAKES!
Fun Shoe

Seashell Salesman posted:

There are a few ways to interpret this, I think. You can plot a 2D line between two points in 3D space on the rendered scene for it (using Bresenham's), 'cast' rays in 3D space in the conventional 3D graphics sense (I'm not a full bottle on these algorithms but should be extremely easy to find info on google), or plot some kind of a block line in 3D space. Are you trying to do that last one? In that case I have no idea off the top of my head if there is a more efficient solution than extending Bresenham's to another dimension.

I'm not really an expert, but my dilettante's view is that Bresenham's or some DDA/DDAesque thing is probably as fastest way to approach naive ray tracing a voxel volume. The key word there is naive, since you can almost certainly wrangle orders of magnitude improvements through optimizations that either restrict the voxel map in some way (height map only), allowing you to do something even more efficient than actually walking the full volume, and/or arrange your space in such a way that you can skip huge portions of the naive trace (i.e. the fastest way to do something is to not do it).

There's a lot of crazy ray-tracing tech if you search around in shader algorithims for depth, offset or displacement mapping.

http://www.cs.columbia.edu/~ktegan/papers/sketch_proposal.pdf
http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter08.html

etc...

Mug
Apr 26, 2005

Unormal posted:

I'm not really an expert, but my dilettante's view is that Bresenham's or some DDA/DDAesque thing is probably as fastest way to approach naive ray tracing a voxel volume. The key word there is naive, since you can almost certainly wrangle orders of magnitude improvements through optimizations that either restrict the voxel map in some way (height map only), allowing you to do something even more efficient than actually walking the full volume, and/or arrange your space in such a way that you can skip huge portions of the naive trace (i.e. the fastest way to do something is to not do it).

There's a lot of crazy ray-tracing tech if you search around in shader algorithims for depth, offset or displacement mapping.

http://www.cs.columbia.edu/~ktegan/papers/sketch_proposal.pdf
http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter08.html

etc...

Okay, I'll keep using Bresenham's, and write in a bunch of other poo poo so it can jump large distances where appropriate.
edit:
I'm getting these tiny inaccuracies where it will fail to cast across some "pixels" sometimes at certain angles. I've got it set to actually draw the ray-trace at the moment. Here's what the ray paths look like at 0degrees rotation (correct):


But at 90degrees it does poo poo like this:


It has similar issues at 45degrees. My rotation code for the start and end of each ray is like this (p = Origin):
code:
		x1 = RayX
		y1 = RayY
		z1 = RayDepthStart

                x1rot = (px + (x1 - px) * COS(theAnglerYaw) - (z1 - pz) * SIN(theAnglerYaw))
                z1rot = (px + (x1 - px) * SIN(theAnglerYaw) + (z1 - pz) * COS(theAnglerYaw))

                x1rot = (px + (x1rot - px) * COS(theAnglerRoll) - (y1 - py) * SIN(theAnglerRoll))
                y1rot = (px + (x1rot - px) * SIN(theAnglerRoll) + (y1 - py) * COS(theAnglerRoll))

                z1rot = (pz + (z1rot - pz) * COS(theAnglerPitch) - (y1rot - py) * SIN(theAnglerPitch))
                y1rot = (pz + (z1rot - pz) * SIN(theAnglerPitch) + (y1rot - py) * COS(theAnglerPitch))

                x1 = (x1rot)
                z1 = (z1rot)
                y1 = (y1rot)

		x2 = RayX
		y2 = RayY
		z2 = RayDepthEnd

                x2rot = (px + (x2 - px) * COS(theAnglerYaw) - (z2 - pz) * SIN(theAnglerYaw))
                z2rot = (px + (x2 - px) * SIN(theAnglerYaw) + (z2 - pz) * COS(theAnglerYaw))

                x2rot = (px + (x2rot - px) * COS(theAnglerRoll) - (y2 - py) * SIN(theAnglerRoll))
                y2rot = (px + (x2rot - px) * SIN(theAnglerRoll) + (y2 - py) * COS(theAnglerRoll))

                z2rot = (pz + (z2rot - pz) * COS(theAnglerPitch) - (y2rot - py) * SIN(theAnglerPitch))
                y2rot = (pz + (z2rot - pz) * SIN(theAnglerPitch) + (y2rot - py) * COS(theAnglerPitch))

                x2 = (x2rot)
                y2 = (y2rot)
                z2 = (z2rot)
It's a rounding error when converting the accuracies of the "Single precision" results of the rotation, to the integer values of the on-screen pixels. But if I try ToInt and ToCInt and poo poo on any stage of the process, it just causes different inaccuracies.

Should I be rotating via some other logic?

edit: Oh, I might have fixed it. Turns out it was more an issue with the way I was rounding ray coordinates to screen pixels.

Mug fucked around with this message at 04:33 on Aug 24, 2013

ahmeni
May 1, 2005

It's one continuous form where hardware and software function in perfect unison, creating a new generation of iPhone that's better by any measure.
Grimey Drawer
Anyone else giving this ludum dare a shot? Theme is "10 Seconds", which I think is a decent one.

Zizi
Jan 7, 2010

Mug posted:

On that note, is there any other algorithms you can name that might be better for casting a ray over over three dimensions?

My (vague) understanding is most 3D raycasts are done by sampling along the line at set distance intervals (so you sample at every, say, .1 units along the line). the major issue is finding a sample distance that gets you sufficient accuracy while not over-sampling.

I'll dig out my game math book and see if it has anything to say about raycasting.

OneEightHundred
Feb 28, 2008

Soon, we will be unstoppable!

Zizi posted:

My (vague) understanding is most 3D raycasts are done by sampling along the line at set distance intervals (so you sample at every, say, .1 units along the line). the major issue is finding a sample distance that gets you sufficient accuracy while not over-sampling.

I'll dig out my game math book and see if it has anything to say about raycasting.
Raycasting is normally done through one of two mechanisms (or both): Either use primitives instead of sampling points in space so you can check rays against possible intersection points instead of points in space, or use a grouping structure like an octree that lets you quickly exclude large amounts of search area.

Unless I'm just completely misunderstanding the question.

OneEightHundred fucked around with this message at 20:14 on Aug 24, 2013

Mug
Apr 26, 2005
This is running pretty damned fast now; I'm not using raycasting. I ended up using a bunch of pre-rendering and only re-rendering when needed.
https://www.youtube.com/watch?v=g84zinrp4uM

leftist heap
Feb 28, 2013

Fun Shoe
I posted this on the libgdx forums as well, but maybe someone here can help me.

I'm stuck setting up scene2d in my game using multiple cameras, one for the entire screen and GUI and the other for the player character and level rendering, which needs to be able to zoom and pan independently. My code is available here

I'm trying to create a simple roguelike, with a bar on the right side with player information and a small black bar across the bottom for messages. Then in the remaining screen space I want the game world and player to be rendered. Relevant classes are these:

https://github.com/drt/rogueahoy/blob/master/rogueahoy/src/se/obtu/rogueahoy/screens/GameScreen.scala
https://github.com/drt/rogueahoy/blob/master/rogueahoy/src/se/obtu/rogueahoy/scene/WorldRenderer.java
https://github.com/drt/rogueahoy/blob/master/rogueahoy/src/se/obtu/rogueahoy/ui/UiGroup.scala

Right now in the world rendering I'm clipping the sprite batch to the bounds of the world display and then switching out the Stage's camera for one that follows the player character around. Everything mostly looks fine except the game world view isn't "centered". It's centered within the entire screen, but I want to center it within the remaining screen space after the UI elements are rendered. I'm guessing that the camera needs to be offset somehow to make up for the UI elements, but I'm not sure how to do it. Anyone have any advice?

seiken
Feb 7, 2005

hah ha ha

Mug posted:

This is running pretty damned fast now; I'm not using raycasting. I ended up using a bunch of pre-rendering and only re-rendering when needed.
https://www.youtube.com/watch?v=g84zinrp4uM

So Mug when is Black Annex out? Why are you posting QBasic Minecraft? What is going on?

Pigmassacre
Nov 23, 2010

GARBAGE DAY

rrrrrrrrrrrt posted:

Right now in the world rendering I'm clipping the sprite batch to the bounds of the world display and then switching out the Stage's camera for one that follows the player character around. Everything mostly looks fine except the game world view isn't "centered". It's centered within the entire screen, but I want to center it within the remaining screen space after the UI elements are rendered. I'm guessing that the camera needs to be offset somehow to make up for the UI elements, but I'm not sure how to do it. Anyone have any advice?

Well, unless I'm mistaken it's very easy if you know how much space the ui elements use up. Your game world view would need to be offset by ((the height of the screen - height of ui elements) - height of game world view) / 2. This is assuming you only want to center vertically.

So basically: (height of area you want to center in - height of object you want to center) / 2

Same thing for width.

DancingPenguin
Nov 27, 2012

I ish kakadu.

Pigmassacre posted:

Well, unless I'm mistaken it's very easy if you know how much space the ui elements use up. Your game world view would need to be offset by ((the height of the screen - height of ui elements) - height of game world view) / 2. This is assuming you only want to center vertically.

So basically: (height of area you want to center in - height of object you want to center) / 2

Same thing for width.

Yea, the absolute most basic centering is screenwidth/2.
So subtracting UI etc if that's what you want makes sense, usually player coordinates have to be accounted for but since you use world cords and so on you should be fine.

Just make sure that your coordinate system is standard (i.e. +x is right and +y is up).

code:

CamX = (ScreenWidth/2) + PlayerX - UIX;
CamY = (ScreenHeight/2) + PlayerY - UIY;
//Something like this

DancingPenguin fucked around with this message at 09:20 on Aug 26, 2013

Mug
Apr 26, 2005

seiken posted:

So Mug when is Black Annex out? Why are you posting QBasic Minecraft? What is going on?

Hahah, Black Annex is cancelled gently caress yooouuuuu nah I just make levels and sprites for it all the time now. I hunger for code, though, so I make different stuff sometimes.

Who knows when it'll come out, next year I guess.

DancingPenguin
Nov 27, 2012

I ish kakadu.
So might do a little app development soon.
Thinking about publishing on both iOS and Android.
Pretty much know my way around Android, seems like I will have to pick up JS for that though.

Does anyone have any recommendations for IDEs etc that would let me publish on both platforms without too much rewriting?

Also, how annoying is Android deployment? I've heard that testing it could be a major pain given all the different systems and platforms, but Eclipse SDK (and probably many others) allow emulation, how accurate are these emulations in terms of graphics display?

Unormal
Nov 16, 2004

Mod sass? This evening?! But the cakes aren't ready! THE CAKES!
Fun Shoe

DancingPenguin posted:

So might do a little app development soon.
Thinking about publishing on both iOS and Android.
Pretty much know my way around Android, seems like I will have to pick up JS for that though.

Does anyone have any recommendations for IDEs etc that would let me publish on both platforms without too much rewriting?

Also, how annoying is Android deployment? I've heard that testing it could be a major pain given all the different systems and platforms, but Eclipse SDK (and probably many others) allow emulation, how accurate are these emulations in terms of graphics display?

http://unity3d.com/ makes it super easy. In my opinion, use unity for cross-platform game development unless you have a pretty well-articulated reason otherwise. (i.e. "I know only Python and refuse to use any other language ever python supremacy suckit Java/C#/VBScript!!")

DancingPenguin
Nov 27, 2012

I ish kakadu.

Unormal posted:

http://unity3d.com/ makes it super easy. In my opinion, use unity for cross-platform game development unless you have a pretty well-articulated reason otherwise. (i.e. "I know only Python and refuse to use any other language ever python supremacy suckit Java/C#/VBScript!!")

Already have a grip on C#/C++, main problem with Unity is the cost.
But hey, it's just a logo right?

Yodzilla
Apr 29, 2005

Now who looks even dumber?

Beef Witch
Yeah if you don't mind having the logo in front of your game the free version of Unity can do a lot of stuff.

DancingPenguin
Nov 27, 2012

I ish kakadu.

Yodzilla posted:

Yeah if you don't mind having the logo in front of your game the free version of Unity can do a lot of stuff.

Yea, using Unity C# right now for PC/Web, and the free editor is wonderful.
So unless someone else has a better (free) suggestion I suppose that's what I'm rolling with.

Would I have to stick to JS or could I use C# instead? (Since C# would allow me to lower my development time by quite a lot.)

xzzy
Mar 5, 2009

It's actually better to not use JS at all.

DancingPenguin
Nov 27, 2012

I ish kakadu.

xzzy posted:

It's actually better to not use JS at all.

That tiny bit of hope this gave me might be enough for me to start working on it tonight.

Shalinor
Jun 10, 2002

Can I buy you a rootbeer?
So. This is what I've been working on for the last, oh, five months. It's Hot Tin Roof: The Cat That Wore A Fedora, and I can fiiinnnaaallly start talking about it.

https://www.youtube.com/watch?v=8TKPdqR79lM

Unormal
Nov 16, 2004

Mod sass? This evening?! But the cakes aren't ready! THE CAKES!
Fun Shoe

DancingPenguin posted:

That tiny bit of hope this gave me might be enough for me to start working on it tonight.

Yeah, there's no reason to use Javascript at all. You can use C# everywhere, if you'e confused by their dumb documentation that defaults to Javascript, there's a pulldown on each of the code listings to switch it to C#. :D

DancingPenguin
Nov 27, 2012

I ish kakadu.

Unormal posted:

Yeah, there's no reason to use Javascript at all. You can use C# everywhere, if you'e confused by their dumb documentation that defaults to Javascript, there's a pulldown on each of the code listings to switch it to C#. :D

Haha yea, I know, the whole default thing is a bit silly.

Thanks for the help everyone, and thanks for helping me avoid Javascript! :commissar:

Yodzilla
Apr 29, 2005

Now who looks even dumber?

Beef Witch
I actually had someone tell me a very good reason for using Javascript in Unity as it was meant to be where you'd have backend people writing in C# and then your scripters and designers working in JS so that compile-time errors are relegated to one team and runtime scripting to another.

Obviously if you're the only developer on a project this means dick-all and you should just stick to C# but if you're using Unity for a big project that can be structured in such a way JS is really valuable.

xzzy
Mar 5, 2009

Unormal posted:

Yeah, there's no reason to use Javascript at all. You can use C# everywhere, if you'e confused by their dumb documentation that defaults to Javascript, there's a pulldown on each of the code listings to switch it to C#. :D

Even better they recently updated the website so if you select C# once, it saves to a cookie and uses that as default! :dance:

seiken
Feb 7, 2005

hah ha ha

Shalinor posted:

So. This is what I've been working on for the last, oh, five months. It's Hot Tin Roof: The Cat That Wore A Fedora, and I can fiiinnnaaallly start talking about it.

I don't know how much is placeholder art, but I feel like your colours are generally way too saturated to really nail the noir look right now.

Congrats on getting it together so far.

seiken fucked around with this message at 16:39 on Aug 26, 2013

DancingPenguin
Nov 27, 2012

I ish kakadu.

Yodzilla posted:

I actually had someone tell me a very good reason for using Javascript in Unity as it was meant to be where you'd have backend people writing in C# and then your scripters and designers working in JS so that compile-time errors are relegated to one team and runtime scripting to another.

Obviously if you're the only developer on a project this means dick-all and you should just stick to C# but if you're using Unity for a big project that can be structured in such a way JS is really valuable.

V This thread is so confusing.

DancingPenguin fucked around with this message at 16:48 on Aug 26, 2013

seiken
Feb 7, 2005

hah ha ha

Yodzilla posted:

I actually had someone tell me a very good reason for using Javascript in Unity as it was meant to be where you'd have backend people writing in C# and then your scripters and designers working in JS so that compile-time errors are relegated to one team and runtime scripting to another.

Obviously if you're the only developer on a project this means dick-all and you should just stick to C# but if you're using Unity for a big project that can be structured in such a way JS is really valuable.

Oh god no this is the worst advice ever. Forgiving scripting languages are often presented as "they don't have compile errors, so people who can't really code can code in them!" and this is horseshit. You don't want people who "can't really code" coding at all, and if they absolutely must then you certainly don't want them coding in a language where mistakes mean subtle errors and things mysteriously not working later on, rather than immediate "no you're wrong" which will at least prevent them from causing too much damage.

Shalinor
Jun 10, 2002

Can I buy you a rootbeer?
EDIT: ^^ Bingo. If your scripter is good enough to be a scripter, they'll pick up C# fine. If they're not, gently caress NO YOU DO NOT LET THEM CODE. Give them uScript, or PlayMaker. Let them NOWHERE near source.

PlayMaker is the real answer here. "IF !C#, THEN PLAYMAKER". Done and done. It's all the scripting tool a non-programmer really needs for gameplay logic, and it's easy to extend with your custom stuff.

seiken posted:

I don't know how much is placeholder art, but I feel like your colours are generally way too saturated to really nail the noir look right now.

Congrats on getting it together so far.
There's (almost) no placeholder art remaining in any of those shots, but it also isn't final art. We're still noodling on how to balance the "noir" with the "being able to see poo poo," especially for interiors. Interiors are hard as hell to make feel noir without also making feel like some dingy forgotten basement.

Also, the Q&A just went up, if anyone wants more gameplay detail. It's a bit chopped up, but lots of good bits in there.

endlosnull
Dec 29, 2006

Anyone do Ludum Dare 27 this past weekend? I did the 48 hour solo competition for the first time and it was grueling but fun. I used Unity but I already had a good grasp on it from work but I still highly recommend it for at least prototyping. Also yes, just stick with C# in Unity if you know C#.

Here's my submission, http://www.ludumdare.com/compo/ludum-dare-27/?action=preview&uid=27026


I had absolutely no clue on a game concept for probably 90% of the development and it was mostly me throwing in things that looked cool and easy to do within the time frame. This kind of stuff only makes me wish I was more creative.

Chance
Apr 28, 2002

Since we're on the topic of languages. I came into Unity and started using Boo, for the only reason that I was somewhat familiar with python syntax. So far it hasn't really been an issue, but I know as clear as day it's the bastard stepchild of the lot, and documentation for it reads like someone got bored halfway through and just left. I'm already reading C# Unity tutorials and redoing them in boo, so I'm not completely oblivious, but anyone have any good advice on how to transition over to just using C# ?

I'm kind of self taught everything else and feel like I'm probably missing loads of ground level coding info so this is probably a good time to step up to knowing why things are a certain way. So anyone have any C# advice, I mean aside from just saying start using it/go through the unity tutorials in it?

That was kind of a meandering request. I just want to keep using unity but learn C# with good practices rather than my current Boo and whatever works :(

poemdexter
Feb 18, 2005

Hooray Indie Games!

College Slice

Chance posted:

Since we're on the topic of languages. I came into Unity and started using Boo, for the only reason that I was somewhat familiar with python syntax. So far it hasn't really been an issue, but I know as clear as day it's the bastard stepchild of the lot, and documentation for it reads like someone got bored halfway through and just left. I'm already reading C# Unity tutorials and redoing them in boo, so I'm not completely oblivious, but anyone have any good advice on how to transition over to just using C# ?

I'm kind of self taught everything else and feel like I'm probably missing loads of ground level coding info so this is probably a good time to step up to knowing why things are a certain way. So anyone have any C# advice, I mean aside from just saying start using it/go through the unity tutorials in it?

That was kind of a meandering request. I just want to keep using unity but learn C# with good practices rather than my current Boo and whatever works :(

C# syntax is a lot like java syntax but NOTHING like any scripting language syntax including python. The Unity documentation has a little toggle for flipping between C#, javascript, and I think Boo so that might be a handy tool to seeing how it goes. Other than that, I recommend doing what I do when learning a new language: Google 'for loop <language>', 'if statement <language>', etc.

Seashell Salesman
Aug 4, 2005

Holy wow! That "Literally A Person" sure is a cool and good poster. He's smart and witty and he smells like a pure mountain stream. I posted in his thread and I got a FANCY NEW AVATAR!!!!

poemdexter posted:

C# syntax is a lot like java syntax but NOTHING like any scripting language syntax including python. The Unity documentation has a little toggle for flipping between C#, javascript, and I think Boo so that might be a handy tool to seeing how it goes. Other than that, I recommend doing what I do when learning a new language: Google 'for loop <language>', 'if statement <language>', etc.

Also goes without saying MSDN and Stack Overflow are very good resources for anything C# related.

FuzzySlippers
Feb 6, 2009

Shalinor posted:

We're still noodling on how to balance the "noir" with the "being able to see poo poo," especially for interiors. Interiors are hard as hell to make feel noir without also making feel like some dingy forgotten basement.

With the number of mods that do nothing but make TES games super dark obviously some people like those realistic dingy interiors, but I can't imagine most do. Suggesting dark with color choice and such seems way better than actually being dark.

I would think when most people think of 'noir' they think black and white so once you've abandoned that you've got room on the look. It's been a while but as I remember LA Confidential and Chinatown aren't terribly dark they just have hard shadows.

seiken
Feb 7, 2005

hah ha ha

FuzzySlippers posted:

With the number of mods that do nothing but make TES games super dark obviously some people like those realistic dingy interiors, but I can't imagine most do. Suggesting dark with color choice and such seems way better than actually being dark.

I would think when most people think of 'noir' they think black and white so once you've abandoned that you've got room on the look. It's been a while but as I remember LA Confidential and Chinatown aren't terribly dark they just have hard shadows.

Yeah, hard shadows is a good point. Everything's bold shapes and hard edges. If it's not black and white the same applies to saturation: everything is either super-saturated (and if so then it's one of like two or three colours), or else it's black and white, and there are very few actual colours used that aren't shades of grey. For example, in the first shot, other than the background, everything is basically black and white apart from the super-red lips or the yellow lights.


Shalinor
Jun 10, 2002

Can I buy you a rootbeer?

FuzzySlippers posted:

I would think when most people think of 'noir' they think black and white so once you've abandoned that you've got room on the look. It's been a while but as I remember LA Confidential and Chinatown aren't terribly dark they just have hard shadows.
Mostly, it's the lighting. Which sucks majorly, working with your standard lambert point lights, but deferred is showing promise. I should be able to mix shadow casting spots with fill points to get the right balance, it's just that I need to do that AND be able to duplicate it quickly, everywhere. Sneezing tiny fill lights into every volume just won't work, but that's what I've found has the best look, thus far.

Anyways, once I get it right, the coloring won't matter. I'll probably stick to the bright colors at that point, because I kinda like them, and it fits nicely with the Art Deco styling everything has. Gives it all a unique flair, once the artists take the level geometry a bit more extreme.

seiken
Feb 7, 2005

hah ha ha
I think you can be super-noir and still really colourful if you just make the lighting very nonlinear with some kind of postprocessing or fancy shaders (this is obviously extreme. Like you said it's probably difficult to balance being able to see things)

xzzy
Mar 5, 2009

To get an authentic noir look, you'll probably have to use toon shading and render different layers with their own lighting. You basically gotta throw away "realistic" lighting and exchange it for something that's highly stylized.. that is, Sin City.

A color example would be Dick Tracy.. they used colored light and built scenes with large blocks of color to give the impression of a color comic book. Advantage is that they could use normal lights and didn't need a mountain of computers to process CGI.

MSPain
Jul 14, 2006
That is one bouncy protagonist.

Adbot
ADBOT LOVES YOU

Shalinor
Jun 10, 2002

Can I buy you a rootbeer?

xzzy posted:

To get an authentic noir look, you'll probably have to use toon shading and render different layers with their own lighting. You basically gotta throw away "realistic" lighting and exchange it for something that's highly stylized.. that is, Sin City.
You really don't. People have this idea of what noir is from watching a few stylized movies like Sin City, but there's a huge range. Noir isn't black and white, and it isn't muted colors - it's lighting, light use and color choice. Chiaroscuro lighting, to be precise. Everything else is a stylistic choice.

My topmost favorite noir film is Blast Of Silence. It's black and white, but that isn't what makes it noir. It's the way the scenes are shot, and the overlay they're using to fuzz out the edges / give the whole thing a burned look, when combined with the dramatic lighting. The Lady From Shanghai is similar, though less distinct / leans slightly more heavily on the B&W and noir tropes to give the film that feeling.

Then there's The 13th Floor. Full color, but it uses careful lighting, a dramatic dark color palette offset with sharp, stark coloration, and an art deco motif to sell itself as noir. The apartment they use in it (Ennis House) is the same apartment used in Blade Runner, another (better) example of lending noir through dramatic lighting, and a stark/sharp color palette mixed with art deco. They even use it in Rocketeer, yet another noir-ish movie, though I'll grant you that they don't do much with the style there beyond touch on it.

... point is, going the Sin City / toonshading route is a bit hamfisted. It'd work, but it would amount to aping the style of something else. When you're trying to nail a style, you go back to the core and find your own interpretation of it. Borrowing someone else's interpretation is lazy, and the results will never be as memorable.


EDIT: Good god, I sound like a film geek. Which I kind of am, I guess.

Regardless, I will grant you that doing noir with forward-shaded point lights is effectively impossible - but that's why I'm using deferred. It lets me stuff a billion non-shadowing lights into the scenes, with which I can pull some very clever selective lighting tricks. The "trick" of it is just in figuring out the density and placement of the lights to give the scenes the right feeling, without compromising their playability. Then I need to package that technique up in a way I can deploy to all the zones quickly, with a minimum of oversight, so that I can tell my other level designer "just use these prefabs here here and here, and you're good." We're not a big enough studio where I can spend a ton of art time hand-tweaking the lighting from every angle in every scene, that'd get insane.

Shalinor fucked around with this message at 05:18 on Aug 27, 2013

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply