Is there a way to change the camera lookat from ease-in-out to linear?


(Pierre Savoie) #1

Is there a way to change the camera lookat from a ease-in-out transition to a linear one?

And also, how could I make my camera turn in a perfect circle around my model instead of my model rotating?
I can’t set camera constraint because I need my user to be able to navigate the scene.


I think easing parameters are only available in translate and rotate, but adding them to lookAt is probably a good idea.

Creating a perfect camera path like that would be tricky. Is there a reason you can’t use rotate ?

(Pierre Savoie) #4

I just didn’t want the shadows to move around the ground whereas a camera movement wouldn’t affect lighting.

I mostly wanted to test if we could create camera path. Rotating the model might be the best trick since we plan on baking lighting anyway.

(Pierre Savoie) #5

The camera lookat function work very strangely, if I limit my orbit camera.

If I don’t move at all in the scene, the functions work like it should.
If I move a tiny bit, the lookat will never bring me in my desired spot.

My camera position are well within the limit I set up and my target is always the same as the initial position.
So what’s causing this?


Do you have a live example?

(Pierre Savoie) #7

Seems like it work now :sweat_smile:
Got that thing when you want to show something that doesn’t work to someone and it just work when they get there.
I fiddled a bit in the scene so I don’t know what I exactly did to fix this…
Will post a example if this problem occur again.



We’re looking into next steps to improve the Viewer API. Could you elaborate on why you need to have different easing options?

(Pierre Savoie) #9

Hi James,

I’m happy to hear there is change coming to the Viewer API.
For the different easing option for the camera lookat, it was to create a fluid camera path from point to point.
With the current easing options the camera always makes a pause when getting to its indicated location.


Ok cool. We’re just trying to be sure of the exact need before we commit to something. For linear, the camera would be moving at a constant speed between points?

@klaasnienhuis @shaderbytes if you have any input on this, we’d love to hear it.

(Shaderbytes) #11

any numerical interpolation has a curve, the most common is linear but not always. Even in blenders data system for animation it stores all animations as a collection of interpolation curves , keyframes are just points on those curves.

Being able to set the interpolation method is how you take animation to where it is supposed to be at. Sometime you want linear other times you want easein or ease out or both also other sub motions like bounce back or elastic etc…

The default interpolation in blender is a smooth bezier curve , not linear , so this gives the best blending ( easein and easeout ) but not good for looping short interpolations where a constant speed is required. obviously you would then choose a linear interpolation.

(Klaasnienhuis) #12

When introducing easing options to the camera movement it makes sense to add a few different ones. It’s hard to predict the ones you’re going to need. When doing interpolations myself I always take a peek here for the basics


For the translate and rotate methods we have easeOutQuad, easeInQuad, easeOutCubic, easeInCubic, easeOutQuart, easeInQuart, easeOutElastic, easeOutBounce for easing options.

It’s hard to say how useful these have been or will be…

(Klaasnienhuis) #14

that seems like a pretty complete list, except for linear

(Shaderbytes) #15

no this is a very short list :wink:

take a look at the easing options for GSAP for html and dotween for unity , this will give you an idea of a more comprehensive list. To me it is one of the most important aspects of any motion , the more options the better.

(Shaderbytes) #16

ideally you want to store these in one place and make any interpolation be able to use them be it rotate or translate or scale … objects or camera doesnt matter. easing equations dont care what the object is or what the properties represent they only care to interpolate start and end values over time.


That’s quite a list

(Shaderbytes) #18

yeah very powerful , i only use Greensock for any html/css property interpolation.

(Klaasnienhuis) #19

I agree that all interpolation types could be shared across all transformable items in Sketchfab. The math is the same whether you’re moving a target or rotating an object. But we’re not talking about css animations here. It only makes sense to offer such a long list of interpolations if the user has more insight in the animation process or the trajectories/curves/tracks. Otherwise picking an interpolation from an endless list is more like guessing (or like flipping though the blending modes in photoshop until you like what you see, or not).

(Shaderbytes) #20

yes but this is just your experience of it so far, also there is nothing wrong in flipping through blend modes in photoshop as art is a process. Yes you can learn what certain blend modes do and are more commonly used for over time, and also some might be more popular than others but i dont think the list is too long, definitely not endless :wink: You dont have to flip though them all if you just know the common ones you want to use like easeoutQuad would be common for example… but if you feel like exploring any others then if the list is there you can …

  1. not having the list can only satisfy one type of restricted curiosity but fails for others… win - lose.

  2. having the list can satisfy both a restricted curiosity and one which wants to explore further. win win

Here have a look at the intro i created for myself for these games years ago… this is fully scripted inside unity and uses various interpolations.

(Klaasnienhuis) #21

That looks might fine @shaderbytes!