Olby Posted February 7, 2015 Share Posted February 7, 2015 Create a CSG brush and texture it with something that has a straight line. Texture locking needs to be in place. When the brush is moved the texture stays in place however as soon as it is rotated the texture slides away. I have had bad experience with this especially in prefabs. Theoretically the texture should lock. Same goes for "shearing" operation. (animation) Quote Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64) Link to comment Share on other sites More sharing options...
xtom Posted February 7, 2015 Share Posted February 7, 2015 Yeah I think this is the same problem Im getting. There seems to be a few ways it can happen. Eg. I brought in a textured box prefab into perspective view, rotated it and then ctrl drag a copy in perspective view and the texture gets all stretched. 1 Quote Check out my games: One More Day / Halloween Pumpkin Run Link to comment Share on other sites More sharing options...
Josh Posted February 7, 2015 Share Posted February 7, 2015 I can't produce this problem. Please post your map. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Olby Posted February 7, 2015 Author Share Posted February 7, 2015 Map file attached. I expect all RotatedX objects to retain the locked texture mapping. Same for shearing. [Edit] It could be related to one of the old texture locking bugs where cylinders had a similar issue (I think it was top and bottom faces that messed up the UV). texture_lock_rotate_bug.zip Quote Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64) Link to comment Share on other sites More sharing options...
Josh Posted February 7, 2015 Share Posted February 7, 2015 I see. This occurs when the brush faces have a rotation other than zero. 1 Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Josh Posted February 7, 2015 Share Posted February 7, 2015 This is really hard. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Josh Posted February 7, 2015 Share Posted February 7, 2015 Shearing will never retain the same tex coords, BTW, because the texture mapping does not allow non-orthogonal mapping, i.e. the X and Y mapping axes must be 90 degrees apart. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Olby Posted February 7, 2015 Author Share Posted February 7, 2015 I see. What about just rotating the texture based on how much you shear the brush? Quote Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64) Link to comment Share on other sites More sharing options...
Josh Posted February 7, 2015 Share Posted February 7, 2015 There's no way to keep it aligned to any edge if you do that. I think not moving is the correct behavior. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Josh Posted February 9, 2015 Share Posted February 9, 2015 Still working on this, this is driving me crazy. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Josh Posted February 9, 2015 Share Posted February 9, 2015 I think it's really working now. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Rick Posted February 10, 2015 Share Posted February 10, 2015 If I load a prefab of a csg in code and make instances via Instance() function, the textures are all jacked up and not locked. I'm not even rotating them so this is just the normal locking without rotation causing issues. 1 Quote Link to comment Share on other sites More sharing options...
Josh Posted February 10, 2015 Share Posted February 10, 2015 CSG prefabs are a different issue: http://www.leadwerks.com/werkspace/topic/10208-initial-move-of-a-texture-locked-prefab-shifts-texture/ 1 Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Olby Posted February 11, 2015 Author Share Posted February 11, 2015 Ok, restarted Steam. Made sure its up to date. Still having this issue. http://olbyonline.com/bin/leadwerks/texture_lock_bug.mp4 Quote Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64) Link to comment Share on other sites More sharing options...
macklebee Posted February 11, 2015 Share Posted February 11, 2015 I noticed with this issue that it works correctly in a couple of instances: 1) no texture rotation on the face and the csg is rotated either by the toolbar/mouse rotation or via the object's property dialog rotation or 2) a texture rotation on the face and the csg is rotated first by the object's property dialog rotation After the csg was rotated via the property dialog, I can use the toolbar/mouse rotation to rotate the csg and it seems to work properly. It appears that for some reason when a texture on the face is rotated, the texture is not locked prior to using the toolbar/mouse rotation but it is when you use the object's property panel. Quote Win7 64bit / Intel i7-2600 CPU @ 3.9 GHz / 16 GB DDR3 / NVIDIA GeForce GTX 590 LE / 3DWS / BMX / Hexagon macklebee's channel Link to comment Share on other sites More sharing options...
xtom Posted February 11, 2015 Share Posted February 11, 2015 It seems to work ok if you rotate it in perspective view, which I do most of the time. But when you rotate it in the top view the texture is sliding. If you rotate it in perspective first it seems to lock it so you can then rotate in top view (I think). Will be nice when these texture bugs are all ironed out. Quote Check out my games: One More Day / Halloween Pumpkin Run Link to comment Share on other sites More sharing options...
Josh Posted February 11, 2015 Share Posted February 11, 2015 Ah, you are doing it in the 2D viewport. That is easy to replicate now that I know. The two methods are different bits of code, so this will be an easy fix. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Olby Posted February 11, 2015 Author Share Posted February 11, 2015 Yes, its the top 2D view. But the same thing happens in perspective viewport IF a face texture is rotated and you use the toolbar rotation buttons (Y-axis). Manual axis rotation in perspective works as expected. Quote Intel Core i7 Quad 2.3 Ghz, 8GB RAM, GeForce GT 630M 2GB, Windows 10 (x64) Link to comment Share on other sites More sharing options...
Josh Posted February 11, 2015 Share Posted February 11, 2015 Thanks. There's actually many different parts of the code that carry out rotation, and many combinations of settings. Quote My job is to make tools you love, with the features you want, and performance you can't live without. Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.