Materials processing is here, so where’s the relevant LSL functionality?

Back on June 19th 2013 with the release of viewer 3.6.0.277516, Second Life got a new capability: materials processing (please see Inara Pey’s coverage for more information on this) and we’ve alrady seen quite a few content creators offer “materials-ready” products. Materials processing, as far as I can understand it, uses two extra textures per face: a normal and a specular map. The purpose they serve is to:

How normal mapping can be used to enhance the detail of simplified, low-polygon meshes. In this example, the original mesh had 4 million triangles and, thanks to normal mapping, we get exactly the same look with a 500-triangle model.

How normal mapping can be used to enhance the detail of simplified, low-polygon meshes. In this example, the original mesh had 4 million triangles and, thanks to normal mapping, we get a very close approximation of the same look, but with a 500-triangle model. Image source: Wikipedia

  • Normal maps: They fake the lighting of bumps and dents – an implementation of Bump mapping (with which we’re already familiar, as it’s been in the “Texture” tab of the build floater for centuries). They add detail without adding more polygons. What’s the usefulness of this? Well, in Second Life, content is streamed from the server to our computers for rendering and, the more complex the objects are, the laggier things get. So, it’s in everyone’s best interest to use low polygon models for greater efficiency. So, normal maps are commonly used to greatly enhance the appearance and detail of such a low-poly (and thus, low lag) model by using a normal map from a high polygon model or a height map.
  • Specular maps: They basically represent the amount of specular reflectivity a surface has and are part of specularity, i.e. the visual appearance of specular reflections, which is a key component in determining the brightness of specular highlights, along with shininess to determine the size of the highlights.
Specular highlights on a pair of spheres. Image source: Wikipedia

Specular highlights on a pair of spheres. Image source: Wikipedia

This capability is already seen by several SL content creators as a godsend, because many have expressed their displeasure with the way SL handles shininess (a feature that really doesn’t look good on everything) and would like greater control over specularity and reflections, appropriate to the material depicted.

The flipside

Unfortunately, not every SL user can see normal and specular maps. This is reserved only for those people who have ALM (Advanced Lighting Model – the new name for “deferred rendering”) and for those who use viewers that are capable of rendering materials. So, who can’t see materials at the moment?

  • People who still use Firestorm 4.4.2.34167 and older versions of it – a rather large portion of SL’s userbase.
  • People who rely a lot on Android mobile devices (tablets, smartphones) for their SL experience. Their GPUs are – at best – where laptop GPUs were ten years ago, and so there’s no point for Lumiya developer Alina Lyvette to try to give her viewer such capabilities.
  • People whose desktops and laptops don’t have graphics hardware that can handle ALM.

As Inara Pey mentions, Linden Lab’s statistics (back in June) show that approximately 30% of the users have ALM turned on, while 75% are on hardware that can show ALM’s eyecandy and have “reasonable” performance (i.e. more than 10 frames per second – but in what regions and under what circumstances?), but it is unknown whether they have turned it on and/or whether they are on a materials-capable viewer. So, while materials support is indeed a godsend for SL content creators, it’s currently something that can only be enjoyed by users with fairly decent graphics cards and materials-capable viewers.

Incomplete implementation

I guess this is something we’ve come to accept as a fact of (second) life with the Lab. Remember mesh? Second Life still doesn’t have a mesh deformer, because no one thought that people would use it to create clothes (duh) and because, when the idea of a mesh deformer was coined, people also (rightly) pointed out that the existing avatar mesh is crap. So, I don’t expect to see a mesh deformer in Second Life unless we see an “improved” avatar mesh first – and, in the name of avoiding content breakage, this “new” avatar  (if and when it comes) will be full of compromises.

We are currently facing a similar situation with materials processing, and this has to do both with LL themselves and with external graphics applications developers. I’m going to start with the latter. The tools for normal map creation in Photoshop and GIMP are – at best – weak. Many graphic artists out there have even gone as far as to say they’re utter crap. I’m not going to dwell on this matter; if you search on the internet a bit, you’ll see tonnes of videos and articles explaining why. So, what are your options if you want to create good normal maps? Full-blown 3D graphics apps like Blender. Problem is, these are notoriously hard to use and the learning curve resembles the Dirac delta function. There are also some other apps that are dedicated to the creation of normal maps, but they’re Windows-only. Of course, we can’t blame LL for this.

What is within LL’s reach, though, is providing LSL control of materials. Materials (normal and specular maps) are basically textures. We already have functionality for changing an object’s colour, texture, shininess, full bright, light, light radius, light intensity and glow. Why not enhance those same LSL functions to also control normal and specular maps? I’m really not the first one to ask this question. It was brought up as a topic in the official forums by Hart Larsson on the 3rd of July, in two of Nyx Linden’s Content Creation/Mesh Import User Group meetings (October 7th by Storm Engineer and on 21st by yours truly). It was also brought up by me on October 22nd, in Simon Linden’s Server/Sim/Scripting User Group meeting.

Personally, I think it’d make great sense to have this functionality. In the transcript of Simon’s meeting, Loki Eliot (a well-known content creator) gives some excellent use-case examples, and I’m sure SL fashion designers will agree with my point that “[b]y extending LSL functionality, we’d be able to change the texture, the normal and the specular map at the same time, and you’d switch from, say, top-grain leather to velvet or suede or leatherette, and you’d also get the proper look. And yes, changing from a dry to a wet look, as Loki said, is another bonus.

.

Mona

.

See also:

.

Shortlink: http://wp.me/p2pUmX-o9

10 thoughts on “Materials processing is here, so where’s the relevant LSL functionality?

  1. animating normal maps would also be a ton of fun. but really, the main focus toward SL as a whole benefiting from materials MUST be aimed toward getting people to just turn on ALM to see how nice things look. otherwise we just accept that lots of people already think everything is pretty enough, and some extra geometry here and there never killed anyone or worse the silhouettes are convincing enough that they don’t have any idea they are missing anything. or whatever. maybe prolonging the life of invisiprim shoes is a worthwhile goal after all.

    as it stands now, people too shy to open the advanced or more tab or whatever it is called that allows setting graphic preferences individually and who happen to also use Firestorm, may never even discover the ALM setting because FS, contrary to the norm, deigned to put ALM past the ‘high’ setting on the graphics slider. yup, that’s right – what other viewers bundled into the medium to high slider range, FS decided instead belonged in the high to ultra range.

    maybe they know something the rest of them/us don’t.

    but of course ALM by itself does not require any particular mark on the slider span and in fact can be enabled and functions perfectly well with an overall slider setting of low, but how many will guess that by themselves.?

    so yeah, 75% could use ALM and therefore could enjoy the look of materials, but if they are FS users, then they are up against a double whammy of not likely to or at least not likely to so far. first, they will have to go get the beta viewer, and second, they will have to know to turn ALM on because, again contrary to other viewers, it will not be enabled by default on a system with a mid range GPU or higher.

    so i don’t see where or how the who can and cannot see materials issue is like the mesh deformer at all. the mesh deformer was a potential boon to clothing creators which never materialized. materials ARE here, and are being used as tools by creators, but so far they’re being overlooked by a large chunk of the population. that’s their choice, albeit in many cases an unwitting one, and in my opinion, it’s also their loss. but at least it’s a choice, materials are here, have a look, or don’t.

  2. That already has a fix implemented on Ukando, Rlv and more viewers, so it becomes a no problem, but still Firestorm resolved to not adapt it!
    Worse, latest LL code screwed the alpha masks, so when using Alm and shadows (as i do ) you can see , on certain angles, the alphas, so they are not fully invisible as they should!
    Im one that for long uses Alm and shadows on, so i know how terrible inv prims look like, the bug fix is a help, cause no matter what i did (Offered full perm alpha layers, made a notecard saying how and why they shoud be used always, even if the shoes have inv prims, offered links for free shoes that are already alpha enabled and much more, most didnt even care, as they where not using alm they where not seing how their feet look like and they still not use it at all, how many live shoes i go and still see so many with them on!
    Since yesterday with latest nvidia drivers im getting up to 10 more fps with alm ,shadows and draw distance of 1024m always! plus nod factor up to 16980 andRendervolumelod factor to 14!
    And my Vga is 2 years old already, so i can’t understand truly why more don’t use Alm, even if without shadows (and i cant leave without them now, finally using a day cycle makes sense!) and much less why Firestorm does not come by default with them enabled!

        1. What I’m talking about here is adding new parameters to the LSL functions llSetPrimitiveParams, llSetPrimitiveParamsFast, llSetLinkPrimitiveParams and llSetLinkPrimitiveParamsFast that will allow a script (such as a colour/texture change HUD like the ones you often see bundled with shoes) to change not only the main texture (the diffuse map), but also the normal map (the material) and the specular map (i.e. the way light is reflected by the object).

          As for invisiprims, they are far beyond the scope of this article. But even though they might have their uses (as Henri says), they’ve always sucked ass for shoes and, honestly, shoe designers that still insist on using them need a bucket of cold water to their faces right now.

  3. For a fetish feet gurl like me, you can imagine the pain i suffered for so much time after starting to use ALM, i could not want to loose all the graphics beauty it delivers but i could not stand seeing so many, with their heels completely screwed.
    I really wish that LL just blocked any object that has the invisible prim script on it, makers should offered and replaced them long ago!
    Bust as it stands, at least now i can (the effect is not miraculous but is way better then seeing deformed feet or shoes!) be in place where they are still in use and dont cry iof despair!

Comments are closed.