processing / processing/processing4
rotate a texture in PShape bug not but work not
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 494
- Forks
- 183
- Avg merge
- 4h 39m
- Merged PRs (30d)
- 3
Description
Created by: matheplica
Hi, here's a bug with last Processing version :
PMatrix2D uvtr = new PMatrix2D();
textUVA = new PVector(0, 0.5);
textUVB = new PVector(0.25, 0.08);
memUVA = new PVector(0, 0.5);
memUVB = new PVector(0.25, 0.08);
void adaptTexture(){
uvtr.reset();
uvtr.translate(0.5, 0.5);
uvtr.rotate(rotText);
uvtr.translate(-0.5, -0.5);
uvtr.mult(memUVA, textUVA);
uvtr.mult(memUVB, textUVB);
sh.setTextureUV(1, textUVA.x, textUVA.y);
sh.setTextureUV(2, textUVB.x, textUVB.y);
}
Before I start to change the variable rotText like this:
ani = new Ani(this, time, "rotText", rotText+((PI/3)*sens), Ani.CIRC_OUT, "onUpdate:adaptTexture");
This part of code runs in P3 but not in P4.
There is no error message but it's append nothing.
In P3 the texture turn in the shape.
I'm on ubuntu 22.04
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the provided texture-rotation sketch in Processing 4 on Ubuntu 22.04, then compare its behavior with Processing 3. Trace the PShape texture UV path around setTextureUV() and the PMatrix2D transformations; done means the texture visibly rotates in Processing 4 without errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- computer-graphics
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100