Using CGI In your Images

Over the last couple of years, I’ve moved more towards the “digital art” end of the spectrum with my photography. I still use a lot of on-set effects such as fog, camera movement with long exposures, props/sets and dramatic lighting, however I started adding in more elements in the post-production phase. I’ve been adding textures to walls and floors for years but I’ve recently started adding more and more effects in post. I think it started with the cosplay shoots. These really needed some sort of setting and the characters often went hand-in-hand with effects such as energy weapons, lightning and so on. You can see a good example of what I mean in the last post “Shooting for Post-Production”, where we shot and produced a mock movie-poster for a an imaginary She-Ra movie.

Wings in Daz Studio using the iRay preview mode
Studio shot combined with ground and walls from other images

In these shots, I have typically added extra elements in a subtle way in the background, obscured by fog and so could get away with the lighting not really matching the foreground lighting. For example, I might add a bit of castle wall behind the fog we had on-set, at a low opacity, just to hint at something in the background of the shot. To take this further though, I would need the light to match. Now, I could shoot on location and rent the props, and this is certainly possible, and probably the most fun way to get the results, however it does present a number of challenges around gaining access to suitable locations, the weather, and of course, the cost. Another way to do it, is to light, and render the objects and scenes using digital 3D models: so called “Computer Generated Imagery” or CGI.

Ade Kestrel, a very talented photographer and digital artist in North Wales told me about Daz Studio. He’s been using it in his work for years to fantastic effect. The software is free to use, and you pay for the content: 3D models, textures, poses, accessories etc. The general idea is very similar to modern movie production in that you light and shoot a model/actor, perhaps with stand-in props for the CGI objects (for scale, and position ) and then model, light and render the CGI objects using the stand-in props as a guide. The lighting for the CGI, can then mimic the studio lighting used earlier. I also found a very talented composite artist called Vladimir Chopine who has produced number of composite images with “angel wings” , rock textures and clouds. Check out Vladimir’s YouTube channel here He also sells packs of pre-rendered wings in various positions for those that don’t want to learn Daz Studio and render their own. I wanted the go through the full process though as I see a lot of potential for other more complex composites with fully rendered environments to put real people in. Plus – whilst the pre-rendered wings are really good, I wouldn’t be able to get such a good match for the lighting used on the model in the studio by using them.

Studio Shoot

Below is the shot that Kerry and I made in the studio. I used a 90cm octabox as my key light and it’s off to the right of this image and up high, angled down. I went for 90cm as at the distance I had to work with, this would provide a fairly flattering light but with some reasonably defined shadows on Kerry. In hindsight, I should have used something smaller and gone for a harder light to better match the idea of sunlight.

Studio shot with key light, fill light, and chilled ground fog

Now, Vladimir used fluffy toy stuffing (possibly Kapok) to make his clouds, and they look great, however this is at least one bit of this process where I have a lot of experience 🙂 Making clouds is something I’ve been doing for a few years now, and I do this using using an inexpensive fog machine and a DIY chiller made from a collapsible heating duct and about 8 freezer blocks. Passing the fog through the tube filled with the freezer blocks cools it down and makes it sit on the floor. it also vastly increases the density and the result is very realistic clouds on your studio floor – as in the shot above. Apart from a talented model, the light and the fog, there is one more important ingredient to the studio shot and that is the mottled grey backdrop cloth. This is was a great tip I picked up from Vladimir Chopine’s videos: having some texture to the background cloth really helps to blend in the background, and any other textures you might use in the composite image. Using a cloth, also allows me to use it to cover objects like stools and tables to create a platform for Kerry to sit on – in her cloud 🙂 So that’s the studio work. You can see we have some real light flare from the softbox top-right, quite a lot of fill light – which also happens naturally with real sunlight if there are clouds around for the light to bounce off, and an atmosphere to scatter it into a sky. We shot lots of frames with different poses and I selected this one to start with as the CGI and compositing would be relatively simple with a straight-on angle.

Modeling the Wings

Daz Studio is.. erm.. a little “organically grown” as a piece of software to be honest and you’ll find yourself having to poke around into every corner to find how to control certain things. Also, a lot of the parameters simply don’t do anything depending on the rendering engine you are using. Like a lot of 3D modelling and rendering software, the controls for moving and rotating objects are just obtuse. It doesn’t have to be this way either – I’ve been using set.a.light.3D for years and rotating the view of the scene, and individual objects is easy and intuitive. In Daz Studio though, you’re into weird widgets and arrows like a lot of other 3D software. It’s worth persevering with though, and after a few hours of prodding it, together with a few hours of YouTube, and googling specific things (such as why the models ship with many different textures and shaders: again down to legacy rendering engine support) I managed to get the wings I wanted into position , and lit with two lights, just as I did in the studio.

Posing the wings in Daz Studio

The wings are fully posable and I spent some time adjusting each articulating joint so they looked a bit more dynamic than the default flat, open pose. You can adjust each individual feather too, but I wasn’t feeling that energetic 😛

Lighting the Wings

I chose a “distant light” to be my key light for the wings. This is something we can’t really have in a studio: totally realistic sunlight. We can mimic some aspects of sunlight such as the colour and the hard shadows. One thing we can’t emulate though is the distance to the sun and the almost parallel rays of light this creates. The sun is far enough away from us here on Earth, that it’s rays are, for all practical photographic purposes, parallel, and so all shadows we see from sunlight are cast in the same direction. A small flash say 5 metres away will generate nice hard sun-like shadows, but the shadows across a figure will be cast at different angles – betraying the nearness of the light. In Daz, distant lights are infinitely far away, and do generate parallel rays of light on our 3D models.

Distant light – emulating the sun in Daz Studio

For the fill light, I placed a “point light” more or less next to the virtual camera. This may seem an odd choice for a fill light – surely a “point light” will just cast more hard shadows? Well, by default , yes, it will, but as a result of who-knows-what woolly thinking, you can make point lights big. I made mine 10m square so it casts a nice big soft fill light with no appreciable shadows (see highlighted sliders in the image below setting the dimensions of the “point light”). It’s now a pointless light 😛

10m square “point light” acting as a fill light in Daz Studio

Rendering the result

Not too much to adjust with the rendering in terms of settings, however there are a few things to consider:

  • Only render the “scene” for these isolated objects. You do not need the “environment”. Rendering “scene only” means you will get just the object, on a transparent background, so there is no need to cut it out in Photoshop.
  • Choose the size of the resulting render. I rendered these wings at 8000 pixels on the long edge which broadly matches the dimensions of a frame from my D850. For testing, I rendered at 1000 pixels on the long side.

Render times: my test images took about 2 minutes each to complete. As my full size renders were 8 times larger in each dimension for a total of about 64 times the area or pixels, I estimated the time to render the full size result at 64 x 2 minutes, (128 minutes or just over 2 hours). However, after the full size render had been going for 20 minutes or so, the progress bar had not yet moved off 0%. The iteration-complete messages were appearing in the progress window though and sure enough, after 80 or so iterations, the render finished – in just under 2 hours. The progress bar still read 0% :-/

One other thing to note about rendering: unless the entire scene fits in your video card memory, the GPU will not be used at all to process the rendering. A quick Google on this subject suggests you need to restart the machine just before you open Daz Studio and start the render. My 2 hour figure, was using the CPU alone.

Putting it together in Photoshop

First I did trial fit of the wings, sizing them using the Free transform tool until they looked to be the right scale for my figure. I then expanded the studio shot to accommodate the wings. I do this mostly, using “Content Aware Crop” multiple times, expanding the image a small amount each time until it gets to the required size. If you try and do it in one go, Photoshop will inevitably decide there should be a head, arm or leg every so often, so add a small amount each time to ensure the algorithm determines it’s only more background you need. I also use the clone-stamp and patch tools to adjust specific areas after the content aware crop has done it’s thing as it tends to product repeating patterns.

Studio shot after expansion to accommodate wings

There’s a 3rd element I haven’t mentioned yet and that’s the sky. I used an image I made a few years ago of some dramatic clouds hiding a late afternoon sun.

Background sky image

I used the “Select Subject” tool to create a selection of Kerry and used this to form a mask for the sky. I then used a soft brush to add more black areas to mask to blend in the clouds with my in-studio cloud. I also used a soft brush to soften my figure mask in places to let the sky “bleed in” to the figure to make it a bit more organic looking

Mask for the sky – it shows up in the white areas

I ended up using two layers of sky: one blended with the studio shot using Soft Light at 100% and then another layer with the Normal blend mode at 23%. I put both layers in a group and applied the above mask to the group. Here’s the result with the sky added.

Sky layers added and masked into the studio shot.

Next, I added the wings layer at 100% with a Normal blend mode. As the wings were already on a transparent background I didn’t need to create a mask to let the sky show through, however I would need a mask to hide them behind Kerry. As they were on a transparent background I could CTRL-Click on the wings layer to create a selection of the wings outline. I used this to create a white mask for the wings on a black background. I then used my model selection I made earlier to further subtract from this mask to hide them behind the model. I also used a soft black brush on a low flow and opacity to partially mask out the ings around the edges to make them a little bit translucent. I then added a curves layer to the wings layer only to match up the colours with the studio shot. I added some contrast, reduced the blue and added some green in the curves layer seen in the image below.

Wings layer and it’s curves adjustment layer to match colour with the studio shot

After adding a halo and some halo sparkles, the image looked like this with the sky and wings in place with colour and contrast adjusted to match.

Studio shot, sky, wings and halo

Next I added some rays of light coming from the top right. There are lots of ways of doing this, however I opted for just drawing some white lines out from the top right of varying widths, and blurring the result. This layer is blended in using the Soft Light blend-mode at 58%.

Light rays added

It’s all there bar the shouting now, but I felt it needed warming up and some contrast adding. Now, I could use curves to adjust the colours in the shadows and highlights, or perhaps a gradient map, but in this case I chose to use some pre-canned Colour Lookup Tables or “LUTs”. I added “Edgy Amber” at 10% and then another LUT layer with “Fall Colors” at 65% opacity.

LUTs added

I also added a lens flare from the apparent “sun” off to the top -right of the image. I used the flare engine in BorisFX Optics to do this. It appears in Photoshop as a plugin.

Flare added in BorisFX Optics

I then saved the image. Back in Lightroom, I did some final tweaks, setting the black point, adding 19 points of green tint, and using the “color grading” panel to add blue to the shadows, and yellow to the highlights.

Finished Image

This was certainly something of a learning curve for me, however it also felt like a natural progression from tweaking images in Photoshop, to cleaning them up and actually painting highlights or effects like flares. Adding actual objects seemed like a next step. I’ve been adding textures such as walls and floors to shots for years, and adding CGI elements allows pretty precise matching of the the one thing it’s extremely hard to draw in in Photoshop: the lighting. I’ve got a number of poses from the studio session so will render wings at to match those for a few more examples, and then: whole scenes to drop a model into. If you’re interested in getting into using CGI in your images, do check out Vladimir Chopine’s YouTube channel: he has videos on a variety of tools including Daz Studio, Unreal 5 and Vue, and a number of full editing sessions where he puts images like this together. It was very useful to me in learning how to create this image.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.