Anonymous Login
2021-09-24 15:14 UTC

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0001870OpenClonkEnginepublic2017-12-23 11:15
Assigned To 
PlatformOSWindowsOS Version7
Product Version8.0 
Target Versiongit masterFixed in Version 
Summary0001870: SetObjDrawTransform causes unintended distortion on certain objects
DescriptionSetObjDrawTransform() causes a distortion that is not intended. For example, in objects with a large width and a small height, it causes distortion if the width parameter is low - in this case the graphics are drawn about twice as high as they should be.

This depends on the window size, see "Steps to Reproduce"
Steps To ReproduceAn object with


was created. The phenomenon appears, regardless whether you transform a layer of the object itself or if you give another object these graphics and transform them.

To reproduce the phenomenon, do the following:
1) Setup:
var dummy = CreateObject(foo);
dummy->SetGraphics("bar", nil, 1, 1);
dummy->SetGraphics("bar", nil, 2, 1);
dummy->SetClrModulation(RGB(0, 0, 0), 1);

2) Reproduce:
dummy->SetObjDrawTransform(x, 0, 0, 0, 1000, 0, 2);

Change the parameter x to different values, for example x=50, and x=1000; If x is very small, then the object should appear with more distortion in the height than intended.
Additional Information* You can determine a certain boundary value for the distortion. In my case this was x_distorted=106, x_undistorted=107). Once I changed the size of the editor window, so that the window was less wide, the values changed to x_distorted=137 and x_undistorted=138;
* If you use a dummy object the values may be different.
* The phenomenon seems not to appear on square shaped object graphics, such as the rock.
* See bug, the object in question is Hazard_HUD from the following pack
TagsNo tags attached.
Attached Files




Luchs (administrator)

I'd guess it's an issue with float precision somewhere? It only happens for small screen sizes because in OpenGL, screen coordinates are always between 0 and 1.

If that's the case, I don't know if we can do anything about it. It doesn't seem to be much of an issue if it only happens for tiny editor viewports.


Marky (developer)

It happens not only for tiny editor viewports, but with "normal" screen resolution when playing the Hazard pack.

-Issue History
Date Modified Username Field Change
2016-12-18 17:03 Marky New Issue
2016-12-19 17:02 Luchs Status new => confirmed
2016-12-19 17:02 Luchs Note Added: 0005549
2016-12-20 08:52 Marky Note Added: 0005552
2017-08-05 13:58 Maikel Target Version => 8.0
2017-12-23 11:15 Luchs Product Version git master => 8.0
2017-12-23 11:15 Luchs Target Version 8.0 => git master
+Issue History