Texture mapping


RE: Texture mapping
#29
(2017-06-29, 20:40)Jaco van der Molen Wrote:
(2017-06-29, 17:41)Travis Cobbs Wrote: For use with your own custom stickers, this is fine. However, for use in an actual part, it is not a good way to do things. The texture mapping parameters can be adjusted to make the texture map smaller than the geometry it is mapped over. So texture images in official files should always be cropped to not contain any empty space around the edges.

I don't understand this. If I scale 4000x1200 pixels tot 80x24 LDU it is a perfect fit. Not?

You're forcing the app to load a 4000x1200 texture, which then must be loaded into the graphics hardware, even though only a small fraction of that is actually used. So in a typical scenario, this image would require over 24MB of graphics memory in a situation where most of it is wasted space.

Textures often get loaded using a technique called MIP-mapping, which loads multiple progressively smaller versions of the same image. All the MIP-map levels add up to roughly 133% as much memory as the main texture alone would require. 4000 x 1200 x (4 bytes per pixel) x 1.33 = 25,536,000 bytes. Cropped, the image is 1768x879. The same calculation from above yields 8,267,663 bytes, which is just under 1/3 as many. So, since it uses less than 1/3 the memory, but produces identical end results, it's worth it to go that route when creating an official part.
Reply
« Next Oldest | Next Newest »



Messages In This Thread
Texture mapping - by Jaco van der Molen - 2017-06-28, 11:05
RE: Texture mapping - by Philippe Hurbain - 2017-06-28, 11:10
RE: Texture mapping - by Jaco van der Molen - 2017-06-28, 12:04
RE: Texture mapping - by Jaco van der Molen - 2017-06-28, 12:22
RE: Texture mapping - by Jaco van der Molen - 2017-06-28, 12:29
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 3:33
RE: Texture mapping - by amanda feuk - 2018-01-31, 4:31
RE: Texture mapping - by Jaco van der Molen - 2018-01-31, 9:31
RE: Texture mapping - by Philippe Hurbain - 2017-06-28, 12:32
RE: Texture mapping - by Philippe Hurbain - 2017-06-28, 12:34
RE: Texture mapping - by Jaco van der Molen - 2017-06-28, 12:55
RE: Texture mapping - by Merlijn Wissink - 2017-06-28, 20:16
RE: Texture mapping - by Jaco van der Molen - 2017-06-28, 21:17
RE: Texture mapping - by Damien Roux - 2017-06-28, 22:28
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 3:35
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 6:02
RE: Texture mapping - by Merlijn Wissink - 2017-06-29, 7:11
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 7:26
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 7:59
RE: Texture mapping - by Merlijn Wissink - 2017-06-29, 8:24
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 8:26
RE: Texture mapping - by Merlijn Wissink - 2017-06-29, 8:42
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 21:00
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 17:41
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 17:47
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 20:47
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 20:40
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 20:56
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 21:14
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 21:18
RE: Texture mapping - by Merlijn Wissink - 2017-06-30, 6:40
RE: Texture mapping - by Travis Cobbs - 2017-07-01, 2:45
RE: Texture mapping - by Merlijn Wissink - 2017-07-01, 6:56
RE: Texture mapping - by Travis Cobbs - 2017-07-01, 18:04
RE: Texture mapping - by Roland Melkert - 2017-07-01, 18:32
RE: Texture mapping - by Travis Cobbs - 2017-07-01, 22:31
RE: Texture mapping - by Roland Melkert - 2017-07-02, 17:56
RE: Texture mapping - by Jaco van der Molen - 2017-07-03, 18:10
RE: Texture mapping - by Damien Roux - 2017-07-03, 20:09
RE: Texture mapping - by Roland Melkert - 2017-07-03, 20:21
RE: Texture mapping - by Travis Cobbs - 2017-07-04, 6:23
RE: Texture mapping - by Philippe Hurbain - 2017-07-04, 6:53
RE: Texture mapping - by Jaco van der Molen - 2017-07-04, 6:54
RE: Texture mapping - by Jaco van der Molen - 2017-07-04, 7:03
RE: Texture mapping - by Philippe Hurbain - 2017-07-04, 8:54
RE: Texture mapping - by Travis Cobbs - 2017-07-05, 5:37
RE: Texture mapping - by Jaco van der Molen - 2017-07-05, 6:30
RE: Texture mapping - by Philippe Hurbain - 2017-07-04, 8:49
RE: Texture mapping - by Jaco van der Molen - 2017-07-04, 14:24
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 21:15
RE: Texture mapping - by Travis Cobbs - 2017-06-29, 21:26
RE: Texture mapping - by Philippe Hurbain - 2017-06-30, 8:09
RE: Texture mapping - by Damien Roux - 2017-06-30, 8:54
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 9:11
RE: Texture mapping - by Merlijn Wissink - 2017-06-30, 12:50
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 14:09
RE: Texture mapping - by Merlijn Wissink - 2017-06-29, 7:59
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 8:27
RE: Texture mapping - by Merlijn Wissink - 2017-06-29, 8:43
RE: Texture mapping - by Jaco van der Molen - 2017-06-29, 8:54
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 11:44
RE: Texture mapping - by Philippe Hurbain - 2017-06-30, 12:12
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 12:51
RE: Texture mapping - by Philippe Hurbain - 2017-06-30, 13:49
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 14:07
RE: Texture mapping - by Philippe Hurbain - 2017-06-30, 14:48
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 15:03
RE: Texture mapping - by Damien Roux - 2017-06-30, 17:47
RE: Texture mapping - by Chris Dee - 2017-06-30, 18:26
RE: Texture mapping - by Jaco van der Molen - 2017-06-30, 14:12
RE: Texture mapping - by Alexander Etges - 2019-03-12, 19:05
RE: Texture mapping - by Jaco van der Molen - 2019-03-12, 22:07
RE: Texture mapping - by Alexander Etges - 2019-03-14, 20:56
RE: Texture mapping - by Jaco van der Molen - 2019-03-24, 20:40
RE: Texture mapping - by Damien Roux - 2019-03-25, 19:22
RE: Texture mapping - by Jaco van der Molen - 2019-03-26, 10:09
RE: Texture mapping - by Damien Roux - 2019-03-27, 1:29

Forum Jump:


Users browsing this thread: 3 Guest(s)