‹ BackHN Continuity

Thread

Show HN: Simple algorithm and color space to generate diverse skin tones

616 points · 100 comments · automatoney

  1. vermarish · · focus · HN ↗
    This is beautiful work! First, I thought this would involve using PCA to go from 3D to 2D, which would result in an easier selector to use, but at the expense of representing every person.

    Then, I thought this would stop at using the U-space vectors (the ones that form the basis of the PCA image) and their corresponding ellipse to form our color space, but no, the function fitting is a very slick idea, even if it was executed by hand.

    Lastly, I love the presentation of sampling from different r values. Whether you sample from a fixed r value or a range of r values, I bet this has great applications in game design or animation.

    I still don't quite get the manual data labeling process at the beginning? It seems like it would encode some bias, but the consistency of the first point cloud and the results certainly speak for themselves.

    1. dr_scully · · focus · HN ↗
      If you look at my doctoral thesis, in fact skin colour can be parametrised using melanin and haemoglobin concentration; which it means it is indeed (roughly) two dimensional. This allows you to invert the colour of a pixel and identify someone’s chromophore concentration. This is based on previous work of others cited in the thesis.

      <a href="https:&#x2F;&#x2F;discovery.ucl.ac.uk&#x2F;id&#x2F;eprint&#x2F;10093345&#x2F;" rel="nofollow">https:&#x2F;&#x2F;discovery.ucl.ac.uk&#x2F;id&#x2F;eprint&#x2F;10093345&#x2F;

      1. GolDDranks · · focus · HN ↗
        I&#x27;ve heard that the so-called &quot;yellowish&quot; skin color that non-tanned East Asians tend to have, is due to relative abundance of subcutaneous fat. If that&#x27;s true, is that captured by the haemoglobin dimension or is it a yet another degree of freedom?
        1. skydhash · · focus · HN ↗
          Not an expert, but when I was learning 3d modeling, there was a good chapter on subsurface scattering which affect the human skin rendering. It’s what give it liveness instead of looking like a doll.
        2. Joel_Mckay · · focus · HN ↗
          All skin is slightly translucent, and color&#x2F;tones forms a gradient across the surface of the skin. Your upper cheeks and forehead are usually slightly reddish, and the chin&#x2F;neck are slightly bluish.

          People only turn yellow if they have kidney or liver damage. However, some distinctive features like Lucy Liu&#x27;s natural freckles are tough to draw right.

          We looked around a lot for a procedural texture&#x2F;shader to help make the project characters look less sickly, and please also consider supporting the persons work if you are able:

          <a href="https:&#x2F;&#x2F;kuhantilope.gumroad.com&#x2F;l&#x2F;ultimate-skin" rel="nofollow">https:&#x2F;&#x2F;kuhantilope.gumroad.com&#x2F;l&#x2F;ultimate-skin

          Best of luck =3

          1. iwontberude · · focus · HN ↗
            &gt; People only turn yellow if they have kidney or liver damage.

            This is not true. Roughly 5% of people have Gilbert&#x27;s Syndrome which is genetic, metabolic abnormality where the bilirubin from dead blood cells are conjugated slower than the baseline patient leading to yellowing of the skin. It is not due to liver damage or disease and is a benign condition. Not to mention there is carotenemia from eating too many carrots or squash -- again not kidney&#x2F;liver damage related.

            1. Joel_Mckay · · focus · HN ↗

              [dead]

            2. itishappy · · focus · HN ↗
              Gilbert&#x27;s is a liver disease...

              <a href="https:&#x2F;&#x2F;my.clevelandclinic.org&#x2F;health&#x2F;diseases&#x2F;17661-gilberts-syndrome" rel="nofollow">https:&#x2F;&#x2F;my.clevelandclinic.org&#x2F;health&#x2F;diseases&#x2F;17661-gilbert...

              1. iwontberude · · focus · HN ↗

                [dead]

          2. CITIZENDOT · · focus · HN ↗
            I didn&#x27;t know chin&#x2F;neck are slightly bluish, can we make it more explicit without side effects?
            1. Joel_Mckay · · focus · HN ↗
              It is a classic artist starting off point to first drop a red&#x2F;blue gradient as a base mixing layer, and add skin details&#x2F;masks for each additional texture layer&#x2F;feature.

              The &quot;The Ultimate Blender 3D Sculpting Course&quot; covers several sculpting techniques, and while this course has a number of challenges it does cover several basics. Probably wise to wait for a sale event if interested.

              <a href="https:&#x2F;&#x2F;www.udemy.com&#x2F;course&#x2F;blender-3d-sculpting-course&#x2F;" rel="nofollow">https:&#x2F;&#x2F;www.udemy.com&#x2F;course&#x2F;blender-3d-sculpting-course&#x2F;

              Best of luck =3

        3. dr_scully · · focus · HN ↗
          We used the approximation that the hypodermis was a perfectly white reflector; so the thickness wouldn’t matter. The collagen fibrills scatter light in such a way to create a yellower tint. So a person’s skin might appear this way in the absence of melanin and haemoglobin. I’m not an expert on population statistics, and so cannot give an opinion on specific skin types. Everything was based on ranges.

          There is a separate effect of increased bilirubin content, that would appear if someone was ill.

          1. HanClinto · · focus · HN ↗
            This brings up an interesting topic of atypical compounds that can visibly affect skin coloring -- whether temporary or more long-lived (such as elevated methemoglobin levels in the Blue Fugates of Kentucky).

            It&#x27;s fascinating to learn that melanin and haemoglobin are the two primary factors (and cover the vast majority of cases), but I&#x27;m curious how many other illnesses &#x2F; disorders can produce compounds with visible effects.

            Thank you for your posts on this thread -- I appreciate you knowledge-sharing on this!

            1. dr_scully · · focus · HN ↗
              In theory, you can construct a skin model of any condition you want. It would be a case of knowing the concentration, scattering profiles and reflectance spectra of any chromophores. For the thesis, I wrote a Monte Carlo skin simulator using OpenCL, when it has just come out. You could plug anything in there.
        4. numpad0 · · focus · HN ↗
          One thing about East Asian yellow tint in skin is that there really isn&#x27;t such a thing. Asian base skin color is same as Europeans, if slightly more reddish or slightly more fatty or whatnot, but more or less within margins of error. It&#x27;s largely an invention from late Age of Discovery era to feed to us-them mentality, with perhaps some effect of malnourishment and sunlight some deep southeast guys was living with at the time of their first contacts.
Open on Hacker News to reply ↗

Unofficial Hacker News client; not affiliated with Y Combinator.