Well I was toying around with some textures for FC blocks and I actually had a few questions in mind after that. First of all what is the res of the texture pack ? I always believed 32x32 works the best for MC.
The more important question is how connected textures will work if there will actually be any ? When you look at the ships with those simple unconnected textures you understand that you could make it look much more neat if you could cover it in a unified texture or at least in bigger texture blocks. You can for example make those patterns you usually see on Sci-Fi ships where you can see the armor plates separated, making it on 1x1 block for smaller ships and then adding bigger variations for 2x2 and so on. Other textures will look better if all blocks are unified into a complete texture. Also those variations can allow to fake stuff like reflections (which is simply adding lighter colors in the middle) which brings me to the next question.
Will there be shaders and stuff ? Reflections ? I do not ask to see stuff in the metal just reflecting light to make stuff feel like a metal ?
Textures
- fr0stbyte124
- Developer
- Posts:727
- Joined:Fri Dec 07, 2012 3:39 am
- Affiliation:Aye-Aye
Re: Textures
There's no reason we can't make a texture larger than a 1x1 block; that's just a matter of playing with the UV coordinates, and it would probably look quite good for ship hulls.
There were always going to be shaders, but not quite in the way it is normally used in minecraft mods. A programmable shader is simply a custom program for how graphics data is processed. It's much less common to use the fixed pipeline like Minecraft does, and I think the fixed pipeline functionality is depreciated in the newer shader architectures. We need it quite a bit for raymarching terrain, but we can put other things in the pipeline as well, provided they are optional.
There are different kinds of reflections possible, depending on the level of sophistication you are trying to achieve. One that has been around forever is specular maps, which is basically how shiny a material is. The shinier it is, the more light it will reflect from direct light sources, and the less it will reflect diffusely. This works well in a deferred shading pipeline, like what the Minecraft shader packs are built to use. Then there is screen-space reflections which can get true reflections as a post-processing effect, which you can see with wet surfaces in Sonic Ether's shader. This is a Cryengine 3 technique, so keep that in mind, as well. Then there are true reflections, which require the scene to be re-rendered for each reflective surface. I believe one of the water shaders used this, but it is not very scalable. The nice thing about pixel shaders is that their cost generally scales with screen real-estate. If something with a shader effect is obstructed or you are not looking at it, it doesn't cost you anything. We still need to be careful with how heavily we add special effects, but here and there should be fine.
One effect I am looking forward to is relief mapping. Some time ago I linked a demo to some Unity source code I bought, and though the demo link is dead now, it looked like this![Image](http://www.stobierski.pl/unity/spaceShip_screenshot.jpg)
Believe it or not, that is actually a flat sphere made with a handful of polygons. Everything else is done with some really cleverly optimized raytracing. Essentially, a pixel takes two or three texture sample points to figure out whether it is up front, in the back, or on the wall, and is efficient enough it can do self-shading as well. I would very much like to see some multi-layered hull textures using this effect.
There were several different flavors of the technique in the pack, each with different abilities and costs. The high-performance spaceship demo, however, was limited to right-angle reliefs, and I don't remember if it could supported multiple depths, but I am sort of thinking not (*edit* yep, one depth, but the intensity is adjustable). Additionally, the silhouette retains the shape of the original geometry, so if we use this, we should make sure that the grid edges are not recessed (though the texture can still span multiple tiles).
There were always going to be shaders, but not quite in the way it is normally used in minecraft mods. A programmable shader is simply a custom program for how graphics data is processed. It's much less common to use the fixed pipeline like Minecraft does, and I think the fixed pipeline functionality is depreciated in the newer shader architectures. We need it quite a bit for raymarching terrain, but we can put other things in the pipeline as well, provided they are optional.
There are different kinds of reflections possible, depending on the level of sophistication you are trying to achieve. One that has been around forever is specular maps, which is basically how shiny a material is. The shinier it is, the more light it will reflect from direct light sources, and the less it will reflect diffusely. This works well in a deferred shading pipeline, like what the Minecraft shader packs are built to use. Then there is screen-space reflections which can get true reflections as a post-processing effect, which you can see with wet surfaces in Sonic Ether's shader. This is a Cryengine 3 technique, so keep that in mind, as well. Then there are true reflections, which require the scene to be re-rendered for each reflective surface. I believe one of the water shaders used this, but it is not very scalable. The nice thing about pixel shaders is that their cost generally scales with screen real-estate. If something with a shader effect is obstructed or you are not looking at it, it doesn't cost you anything. We still need to be careful with how heavily we add special effects, but here and there should be fine.
One effect I am looking forward to is relief mapping. Some time ago I linked a demo to some Unity source code I bought, and though the demo link is dead now, it looked like this
![Image](http://www.stobierski.pl/unity/spaceShip_screenshot.jpg)
Believe it or not, that is actually a flat sphere made with a handful of polygons. Everything else is done with some really cleverly optimized raytracing. Essentially, a pixel takes two or three texture sample points to figure out whether it is up front, in the back, or on the wall, and is efficient enough it can do self-shading as well. I would very much like to see some multi-layered hull textures using this effect.
There were several different flavors of the technique in the pack, each with different abilities and costs. The high-performance spaceship demo, however, was limited to right-angle reliefs, and I don't remember if it could supported multiple depths, but I am sort of thinking not (*edit* yep, one depth, but the intensity is adjustable). Additionally, the silhouette retains the shape of the original geometry, so if we use this, we should make sure that the grid edges are not recessed (though the texture can still span multiple tiles).
Re: Textures
Yea I saw it before when I worked with DDS textures, it could be nice on smaller scale blocks but I can't really find a use for it on bigger scale where the same effect is achieved by simply taking off blocks. The specular maps seem to serve out needs quite well.
Now for that matter will the connected texture works the way they do currently for most texture packs ? And the specular maps are standard black and white versions of the current texture ? Because basically for the whole block there is the same reflection value as it is the same material, maybe it is enough to store a numeric value ?
Now for that matter will the connected texture works the way they do currently for most texture packs ? And the specular maps are standard black and white versions of the current texture ? Because basically for the whole block there is the same reflection value as it is the same material, maybe it is enough to store a numeric value ?
They're watching ... ![Image](http://i1340.photobucket.com/albums/o724/Iv121/SOF-Anim-Chrome_zps59b9973a.gif)
"I am forbidden tag" -CvN
![Image](http://i1340.photobucket.com/albums/o724/Iv121/SOF-Anim-Chrome_zps59b9973a.gif)
"I am forbidden tag" -CvN
- fr0stbyte124
- Developer
- Posts:727
- Joined:Fri Dec 07, 2012 3:39 am
- Affiliation:Aye-Aye
Re: Textures
You can think of the specular map as a black and white version. Traditionally, it will take up one color channel, with the normal map taking up the other two (the normal has three components, but the third can be derived from the other two). The only real advantage to making the specular map a single value is to save video memory, but our textures are not really so big we need to worry much about that. Specular highlights still need to be calculated on a per-pixel basis, and they need to be accessed from the texture to avoid stalling the pipeline. Plus, if you look in the sonic ether texture packs, you will see that the specular map is not constant across each tile, for instance the metal pieces of the door texture are very reflective and the holes in a pumpkin naturally have no reflection at all.
Still, if we wanted, we could split up the tiles into those with specular/normal mapping and those without and render them with separate shader programs. It's not good to switch contexts too many times during a draw because it eats into the batch limit, but a handful of times for different materials is perfectly acceptable.
As for the connected textures, I've never looked at the code, but after examining the texture pack, it looks like there are multiple variations of the same material with each of the possible edge combinations present, though which combinations are possible depends on the type of block (e.g. bookshelves only tile horizontally). For our purposes, what would probably work best would be having a single large texture spanning multiple tiles, and align the UV map with world coordinates rather than worry about the position of neighboring blocks. The only real restriction is that it looks natural regardless of where the blocks stop, or more likely, have a border present on each tile, but is camouflage it with other stuff so that it doesn't look out of place.
There is more advanced stuff we could do as well, such as layering transparencies over the structure to mix it up, but I would like to avoid anything like that until there is evidence that it is worth investing in. Ultimately, it will come down to the creativity of the texture artist what we end up being able to do.
Still, if we wanted, we could split up the tiles into those with specular/normal mapping and those without and render them with separate shader programs. It's not good to switch contexts too many times during a draw because it eats into the batch limit, but a handful of times for different materials is perfectly acceptable.
As for the connected textures, I've never looked at the code, but after examining the texture pack, it looks like there are multiple variations of the same material with each of the possible edge combinations present, though which combinations are possible depends on the type of block (e.g. bookshelves only tile horizontally). For our purposes, what would probably work best would be having a single large texture spanning multiple tiles, and align the UV map with world coordinates rather than worry about the position of neighboring blocks. The only real restriction is that it looks natural regardless of where the blocks stop, or more likely, have a border present on each tile, but is camouflage it with other stuff so that it doesn't look out of place.
There is more advanced stuff we could do as well, such as layering transparencies over the structure to mix it up, but I would like to avoid anything like that until there is evidence that it is worth investing in. Ultimately, it will come down to the creativity of the texture artist what we end up being able to do.
Re: Textures
I am not sure how I would make it in general, you really need to examine each case separately. I guess it is one of those few cases I don’t have an opinion of my own on the matter apart from that we need those connected textures.
They're watching ... ![Image](http://i1340.photobucket.com/albums/o724/Iv121/SOF-Anim-Chrome_zps59b9973a.gif)
"I am forbidden tag" -CvN
![Image](http://i1340.photobucket.com/albums/o724/Iv121/SOF-Anim-Chrome_zps59b9973a.gif)
"I am forbidden tag" -CvN
- fr0stbyte124
- Developer
- Posts:727
- Joined:Fri Dec 07, 2012 3:39 am
- Affiliation:Aye-Aye
Re: Textures
Well, I guess that is why it is called texture art and not texture science. I don't think there is necessarily a "right" way to do this, nor do I have any experience with how it should be approached. I would think the first step ought to be trying out concepts in an environment you have full control over, like Blender. The advantage there is that it supports all the standard lighting properties out of the box.
By no means should this be considered a simple task. We're dabbling in professional gamedev territory here, albeit briefly. It's not going to be easy, but I think it will definitely be worth the effort.
By no means should this be considered a simple task. We're dabbling in professional gamedev territory here, albeit briefly. It's not going to be easy, but I think it will definitely be worth the effort.