Set Texture Origin for GDL Objects?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-01-21
05:28 PM
- last edited on
‎2023-05-11
12:54 PM
by
Noemi Balogh
I've made a GDL object which essentially performs as a wall tile, each one 500mm square.
I've placed them in a grid covering my wall 4 objects wide by 4 high (so a 2m square piece of wall).
I want to apply a tiling texture that I've made that is 1m square to the group of objects, so the texture will be display twice horizontally and twice vertically.
The problem is, each object seems to have its own texture origin so the texture placement just goes crazy, and using the Set Origin command has no effect when I try to use it to unify the objects' texture placement.
Is there a way round this? Is it not possible to set a Texture Origin for an object?
http://derekjackson.artstation.com
AC19 / 21 / 23 / 27
Windows 7 Intel Xeon 18Gb
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-01-21 06:11 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2013-01-21 09:10 PM
The book is copyrighted by DNC, but is apparently available for download from various sites... I just found this one which has working links:
I've compressed the images on the pages of interest so that they are small enough to upload here for you. Note the VERT and COOR commands in the second column of the second page, which align the wood grain on the chair pieces properly.
Cheers,
Karl

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2019-01-16 08:06 PM
1. Put an IMAGE on a PLANE
a. The image will stretch to the extents of the plane
b. The image will START at the lower left corner
2. I NEED to use a MATERIALs TEXTURE to do this because the PICTURE command does NOT translate to ENSCAPE...
3. I need to ROTATE the object (automatically) to point AT THE CAMERA
a. I can already do this part, but the texture wants to start at 0,0... so it is shifted on the plane by half.
I've gone thru COOR / VERT / TEVE... but cannot get it to shift over -a/2...
Any help appreciated..
DUane
Visual Frontiers
AC25 :|: AC26 :|: AC27
:|: Enscape3.4:|:TwinMotion
DellXPS 4.7ghz i7:|: 8gb GPU 1070ti / Alienware M18 Laptop

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2019-01-17 09:14 AM
*****
One thing that's counter-intuitive here is that the VERT/COOR statements must be placed after the object code.
Also remember to place a BODY -1 statement before the object code as a companion to the one at the end of the VERT/COOR statements. This makes sure that the new texture origin applies apply only to the specific object. Of course, several objects can be included between the the BODY -1 statements. A stray BODY -1 anywhere in between the object code and the VERT/COOR statements will cancel the texture change.
Another thing: Apply the origin changes to the VERT/COOR statements, along with the required DEL statements, instead of trying to work out the vert vectors.
Here's what works for me:
MATERIAL brick
BODY -1
PRISM_ 5, 0.10,
0,0,15,
0,1,15,
1,1,15,
1,0,15,
0,0,-1
ROTy 90
ADD 0.30, 1.20, 0.00
base
vert 0, 0, 0
vert 1, 0, 0
vert 0, 1, 0
vert 0, 0, 1
coor 2 + 256, -1, -2, -3, -4
DEL 2
BODY -1
Win10 64bit Intel i7 6700 3.40 Ghz, 32 Gb RAM, GeForce RTX 3070
AC 27.0 (4001 INT FULL)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2019-01-18 07:47 AM
Note that I also put a switch in the parameters to MIRROR the texture (to make the variety of the plants look better)… I was unable to use an EQUATION in the "x" vector, but was able to set up a simple IF THEN and have the x direction turn from positive to negative.
Anyway, your suggestion was very much appreciated.
duane
Visual Frontiers
AC25 :|: AC26 :|: AC27
:|: Enscape3.4:|:TwinMotion
DellXPS 4.7ghz i7:|: 8gb GPU 1070ti / Alienware M18 Laptop
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2021-02-10 03:09 PM
David wrote:Worked a charm for me! Spent ages trying and in the end it was the -1,-2,-3,-4 at end of COOR.
Here's a tutorial I posted back in 2009. Maybe this helps?
*****
One thing that's counter-intuitive here is that the VERT/COOR statements must be placed after the object code.
Also remember to place a BODY -1 statement before the object code as a companion to the one at the end of the VERT/COOR statements. This makes sure that the new texture origin applies apply only to the specific object. Of course, several objects can be included between the the BODY -1 statements. A stray BODY -1 anywhere in between the object code and the VERT/COOR statements will cancel the texture change.
Another thing: Apply the origin changes to the VERT/COOR statements, along with the required DEL statements, instead of trying to work out the vert vectors.
Here's what works for me:
MATERIAL brick
BODY -1
PRISM_ 5, 0.10,
0,0,15,
0,1,15,
1,1,15,
1,0,15,
0,0,-1
ROTy 90
ADD 0.30, 1.20, 0.00
base
vert 0, 0, 0
vert 1, 0, 0
vert 0, 1, 0
vert 0, 0, 1
coor 2 + 256, -1, -2, -3, -4
DEL 2
BODY -1
Can someone explain why that works the way it does?


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎2021-02-11 02:35 AM
GDL wrote:
Use a minus sign (-) before VERT indices if they are used only for defining the local coordinate system.
AC22-28 AUS 3110 | Help Those Help You - Add a Signature |
Self-taught, bend it till it breaks | Creating a Thread |
Win11 | i9 10850K | 64GB | RX6600 | Win11 | R5 2600 | 16GB | GTX1660 |