Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8869263
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T17:26:55+00:00 2026-06-14T17:26:55+00:00

In some case, I think the translateZ and scale have the same effect ,just

  • 0

In some case, I think the translateZ and scale have the same effect ,just like zoom in or zoom out.

I think there are some calculate connection between them, if I konw one value of them, like translateZ(-1000px) and the parent perspective value, can I calculate the scale value that have the same effect equal to the translateZ ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T17:26:56+00:00Added an answer on June 14, 2026 at 5:26 pm

    You are correct. As an object moves towards you (i.e. translateZ) it appears larger (i.e. scale).

    As shown in this diagram, perspective defines where the viewer is relative to the container and translateZ defines where the subject is relative to the container.

    diagram of translateZ

    The formula to go from scale to translateZ (and back):

    scale=perspective/(perspective-translateZ) -OR- enter image description here

    I’ll leave the mathematical proof to a math whiz, but I did some checking with the pythagorean theorem and everything works out.

    Example:

    Let’s say you’re 100px from the container: #container { perspective: 100px; }

    1. If you translateZ(50px), the subject has moved halfway to you and will appear twice as large, making it 2x.
    2. If you translateZ(75px), the subject has moved another halfway closer and will double again, making it 4x.
    3. If you keep doing this, as you get closer to translateZ(100px), the subject will approach being to infinitely large.

    Try it out. Here’s a JSFiddle to compare different examples visually.

    Limits:

    This works if the subject is moving directly towards you, but falls apart if you do things like rotate the subject in 3D space. There is math for that too, but it gets complicated. Check out 3D Projection on wikipedia.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a queryset containing some objects. Depending on some case or the other
The use case is some what like this: public class SomeClass : ICloneable {
This is a minimal test case of some code that I actually have. It
In some case, when accessing an activity field from an anonymous class, I get
I've some case about executing stored procedures in SQL Server. Maybe it's unusual practice,
My code in scala template: @session.get(user.id) match { case Some(_) => xx case _
I've been thinking on how the memory would be handled in some specific case
My downloadFile AsyncTask may need quite some time in case of concurrent downloads over
I'm working on a project where huge imports, in my case meaning some 20
I am new to use moq. I am into creating some unit test case

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.