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 7032729
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T00:58:23+00:00 2026-05-28T00:58:23+00:00

The problem is this, I have input from a camera in 240×160 res, I

  • 0

The problem is this, I have input from a camera in 240×160 res, I place it in a 256×256 texture.

I then map it to a quad [0..240/256] on the U, and [0..160/256] on the V. Works fine, but the problem is I am rendering to a buffer…

The buffer is the correct ratio because I don’t want to do more pixels than is nessasary. Then I come to apply a different effect and render to the next buffer. But by this point I have to use the range [0..1] on both U and V and so my aspect ratio has been lost.

The problem is that my pixel shader effects can rely on aspect ratio, for example, a water ripple needs to calculate distance from the centre.

I can fix the problem in the shaders, but ideally at the second (or more) pass I want to set the UV range so that aspect ratio is preseved.

Can I do this?

  • 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-05-28T00:58:24+00:00Added an answer on May 28, 2026 at 12:58 am

    Texture coordinates are always from [0,1] in OpenGL ES. You’ll have to either pass in the aspect ratio as a uniform, or create your texture with the same aspect ratio to begin with.

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

Sidebar

Related Questions

I have this simple problem that gets an input from the user using a
I was thinking of a solution to this problem. My input: 1. Have a
i have this problem: starting from an empty list (0 elements) i want check
Problem! I Have the following input (rules) from a flat file (talking about numeric
I have this Java input-related problem. I'm solving some cases in UVAToolkit, but there
i have this problem: i need to remove the disabled attibute from the siblings
I have this code to retrieve data from file then make some treatment, and
Please help me to troubleshoot this problem. A have an input file 'Trial.txt' with
I have this problem I'm hoping someone knows the answer to. I have an
I have this problem where I open Visual Studio and the internal windows are

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.