Lens Studio Tutorials!
Hey everyone!
I have been making tutorials for Lens Studio and thought you might find them useful! They cover a range of topics such as tweening, basic javascript, animation, as well as some more fun topics! If you have any questions about the videos feel free to comment inside the videos on youtube or reply to this comment!
Here's a list of my current tutorials:
Object Spawner Template - Use this template to allow your users to choose between different objects, then move, scale and rotate them, and spawn them in the AR Scene! Shoutout to Charles Hamblen for the modeling and animation of the trees!
Make Objects follow the Camera from any direction! - In this video, you’re going to learn how to make objects follow the camera in augmented reality! Whether you want to have a zombie, a spooky skeleton dancing, or even a severed hand stalking your users, this is the video for you!
Skeletal Mask Template - This template adds a slight modification to the new Skeletal tracking template in the latest 2.1 build. It allows you to mask out certain effects using the skeletal tracking, so you can make effects happen on people's arms and torso!
Particle Controller Template - This Template lets your start and stop any particles you want when the user opens and closes their mouth! You can also add other effects and, for the scripters, you can change the mouth opened and closed events to any other events you want to trigger the particles! Just make sure to copy the code inside the events :)
Tracers Template - Here's a template to make your own custom Tracers Lens! Template download is in the Youtube description!
The Call Template - Now you can make your own Fake FaceTime call lens and prank your friends! Template download is in the Youtube description, enjoy!
Four Cameras Template - This is an expansion of a previous tutorial, where you learn how to make four different effects for your lens. In this tutorial, I've made a fully functioning template for you to use! Now, users can just tap on the screen to make one of the effects to fullscreen! Template download link is in the Youtube description.
Smooth Effect Template - Use this template to create your own wacky face effects that smoothly transition as you open your mouth! (Updated for Lens Studio 2.0)
Tracers 2.0 - Learn how to re-create the Tracers effect in Lens Studio 2.0!
Lens Studio 2.0 Walkthrough - With the newest update, a lot of features and functionality has been added! In this video, I walk through the major additions and changes made. I added timestamps in the YouTube description so you can skip to certain areas you're more interested in. Let me know if you have any questions, and happy creating!
Creepy Face Effect from my Nightmare - In this tutorial we will learn how to imitate one of the recent Snap Official lenses that has haunted my dreams. We'll learn how to combine a face texture with a face mask to get a small piece of our skin tone, and cover our whole face with it. Then, we can start adding more face effects to complete our nightmare fuel!
One thing I forgot to mention in the video - In the face texture you can play around a little more with the scale, offset and face region to get a better sample of skin. Let me know if you have any questions!
Adding Multiple Camera Outputs for Different Effects - After watching this video you'll be able to create multiple different cameras and add whatever effects you want to them! That way people can see all your post effects in one lens!
Creating a dynamic count or score using Javascript and the Text Label - This one is great if you want to add a score to your lens, to add some game elements! You could also use it as a general counter!
Creating an Augmented Reality VR Animated Solar System - Here's a great sciene project that is super easy to make. All the resources are available online for free, so anyone can create their own solar system model!
Fading a Face Mask using Tweens - Here's an easy way to incorporate tweens and a little scripting to make your face mask fade in on a custom event!
Cycling through Post Efefcts on Tap - If you like making cool post effects or filters, this tutorial will show you how to add multiple effects and cycle through them with some scripting! You could also achieve the same effect using the fullscreen template :P
How to Create Smooth Effect Transitions - This is a fun tutorial because it shows you how to dynamically change values based on how much someone opens their mouth! It's a great way to make a smooth realistic transition instead of just using a mouth opened event!
Beginner Scripting in Javascript - This tutorial goes over some very basic javascript knowledge you'll need to start creating custom scripts in Lens Studio. You'll learn about things such as referencing objects, creating variables, and also conditional logic statements!
Pixelate Effect - If you've seen those 'censored' effects in some lenses, this is how they did it! Simply by lowering the camera output resolution!
Blur/Tracer Effect - If you liked the 'Tracers' lens, then this tutorial will show you how to get that effect in your own lens! This effect will create visual trails from the camera adding a groovy feeling!
Behavior Script and Custom Animations using Tweens - This tutorial goes over the behavior script and shows you how to create some custom tween animations without doing any scripting!
How to make the Bongo Cat Lens - This shows you how to do a little custom scripting to make your own tappable critter!
Sunrise Face using Custom Tweens - This lens goes through my process for creating the sunrise face lens, and how you can make your own 2D animations with Tweens and some custom scripting!
Outstanding work.
Love you ben
Thanks Ben, these are fantastic.
Thank you Ben. I love your Youtube channel with very creative content.👍
Can I request a tutorial please?
It would actually be kind of an extension of one of your existing tutorials. For the multiple camera effects lens, it would be amazing if you could do a walk through of how to make it so that when you tap one of the four small images, it fills the screen, and then when you tap again it goes back to being split into 4.
I messed around with the Behavior script and tweening for a while to try to get that working right but in the end just made myself frustrated!
You're not the first to request this Rhonda, this was long overdue thanks for the suggestion!
Hello
I need your help explaining the lens
https://www.youtube.com/watch?v=ETRYKDAWwpQ
I did not find any explanation for the functioning of the lens
Hi Ben, These are amazing.
You mentioned in your video (Behavior Script and Custom Animations using Tweens) which was great and I see you've said in comments that resetting has been implemented for Tweens in SC.
I've been looking for a way to reset a script and can't see how to do that.
I'm trying to stop a script from running that has been triggered by touch when the camera is flipped from back to front camera. Basically the script is triggered and instantiates an object which will appear after a certain amount of time. I need the script to go back to its original state - essentially resetting it if the ser flips the camera halfway through. I've tried enable/disable script but seems to still run. Also using 'SpectaclesTimeLoopHelperModified' script which resets tweens but doesn't seem to reset scripts. Any thoughts would be gratefully received!
Best,
Rich
Hey Rich!
You could try adding some logic around the inside of the tap event, which would basically say if the back camera is active then run the code inside, otherwise if it's on the front camera, don't trigger it. This can be done by adding the CameraFrontEvent and CameraBackEvent, then set some type of variable like "backCam" to true or false inside these events. then, put an if statement around the code inside the tap event that only runs if backCam is true!
Hope that helps
Ben
Hi Ben, thanks for this. I understand the logic but I’m not sure how to set that up in code. I have my head around the behaviours and tweens etc, but I’m not a coder. Any chance you could outline the script for me. One thing on this it seems that it says it won’t trigger if on front camera. That’s fine, but if you are on back camera and have triggered it, then go to front camera, will it stop the script from running in the background?
Hi Ben,
The tutorials are great by the way thank you very much. I was just letting you know I am struggling at the pixelate effect tutorial as in the resources panel I don't seem to have the technique called 'Camera Output'. This issue meant even if the resolutions were changed, it would still not have an effect on the face.
I have a feeling that maybe the software has been updated regularly so I wanted to know how I can overcome this issue.
Best,
Cold
Thanks Ben, these are fantastic
Hi Ben.
Thanks for your work!
I'm trying to follow the video tutorial that you made with sellia "Dynamic vine growth effect".
I follow each step of your tutorial but something doesn't work. I would like to know if you can help me to find my mistake or if it's a consequence of the new LS?
If you want you can download my project here
By advance thanks and once again thanks for you work
Hey Takinours,
Try using this tutorial from the Lens Studio team, they use a different method that should still work with the new update! - https://www.youtube.com/watch?v=x6ydL9WB0Q0
Hey Ben
Looks like you have some great tutorials. I was wondering if you could perhaps point me in the right direction. I'm a total beginner that's looking to experiment with creating some face lenses. Do you have a tutorial that describes how to use an image of an existing face - like a celebrity to create my own lens?
I'd love to create something of a similar quality to this: https://www.snapchat.com/unlock/?type=SNAPCODE&uuid=3D4A499924824910B8F5866805735BFC&metadata=01
Any help would be greatly appreciated:)
Bad
Wonderful!
Shop exquisite gifts for your loved ones and make your christmas special like never before. Choose from variety of gift items. unique christmas gifts
Hi, guys check out my lens. I made it since its Christmas. Let me know if I need to improve anything. I'd appreciate it.
https://www.snapchat.com/unlock/?type=SNAPCODE&uuid=582cdcae8c474309971f364d085a1034&metadata=01
nice thank you .
excellent work mann
excellent work mann
excellent work mann
You could try adding some logic around the inside of the tap event, which would basically say if the back camera is active then run the code inside, otherwise, if it's on the front camera, don't trigger it. This can be done by adding?
John Smith, the forum is not the place to advertise your website. (if it has nothing to do with lens studio)
Hello Ben!
First of all, thank you Ben for sharing with us your wonderful video tutorials and templates.
I made a lens called "Eyeglasses Styles" using the "Four Cameras" template. And while I was making the lens, I didn't see anything wrong with the Lens Studio. Then my lens went LIVE. I found out there was a small bug in this template when I was taking pictures with my rear camera. See the following small bugs.
1. When taking pictures with the rear camera, the 3rd and 4th cameras showed such overlapping images. (Small view: Bottom Left and Bottom Right)
2. It showed the same overlapping image when the 3rd camera is selected. (Full view: Bottom Left)
3. Also showed the same overlap as the 3rd camera. (Full view: Bottom Right)
Finally, after many attempts, I am sharing with you guys a solution that fixes the bugs above.
Solution: Open the template file, go to "Scene Config" and place the render "Ortho" at the bottom of the sequence. That's it.
Hope it works for you.
Erdenebaatar G.
The tutorials are great by the way thank you very much. I was just letting you know I am struggling at the pixelate effect tutorial as in the resources panel I don't seem to have the technique called 'Camera Output'.
Hey Ahtasham,
The Camera Output has been replaced by "Render Target"
Thanks Ben Knutson there is fantastic.
Thanks for sharing.