Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

271
Views
Three js RectAreaLight on MeshPhongMaterial no light reflection (OES_texture_half_float not supported)

I want to add RectAreaLight to a three.js scene where I placed object with MeshPhongMaterial however there is no light reflection on the objects. I found a working example here: Link

You can see the source code when you open the developer tools.

So I tried to port it to React and the scene renders all objects but there is light reflection. In line 46 the OES_texture_half_float error was thrown. I commented this lines out. Maybe it has something to do with this.

Here is the not working codesandbox: Link

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

There are a couple of issues in your code:

  • You have to import RectAreaLightUniformsLib and call its init() method.
  • As mentioned in the documentation, RectAreaLight only supports PBR materials (meaning MeshStandardMaterial and MeshPhysicalMaterial).
  • There is also no shadow support yet so setting flags like castShadow and receiveShadow won't have any effect.

Fixed codesandbox: https://codesandbox.io/s/restless-cherry-4jh72

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!