Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)


Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#1
Hi all,

Is this part done?


Can the globe print be done trough texture mapping?
The part exists.

I am trying to make the image for mapping, but I am unsure how to map the image on the part.

Something like this (WIP)
   


[Image: 61287pb002.jpg]
* 

 2 
 61287pb002
Dark Tan Cylinder Hemisphere 2 x 2 with Cutout with Europe, Africa, Asia, Australia Reddish Brown Globe Pattern
CatalogPartsCylinder, Decorated


[Image: dot.gif]
[Image: 61287pb001.jpg]
* 

 2 
 61287pb001
Dark Tan Cylinder Hemisphere 2 x 2 with Cutout with the Americas and South Pacific Reddish Brown Globe Pattern
CatalogPartsCylinder, Decorated
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#2
This is one of the outstanding patterns for the modulars. If you come up with a good image, it can prolly be TEXMAPed.
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#4
(2020-07-25, 16:10)Orion Pobursky Wrote: This is one of the outstanding patterns for the modulars. If you come up with a good image, it can prolly be TEXMAPed.

OK, I am guessing the image should be square?
I do not have the part (yet), but can we do some testing with an image?
If you can provide the code for the part, I can make the image.

I have been studying the spherical texture mapping but had no success to make it work :-(
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#6
I have no idea of what I'm doing but this works, sort of.
I used, and adapted the example from Travis below.

   

Something breaks around the northpole.


Attached Files
.dat   61287s01.dat (Size: 16.45 KB / Downloads: 3)
.dat   61287s02.dat (Size: 14.29 KB / Downloads: 3)
.dat   61287.dat (Size: 490 bytes / Downloads: 3)
.dat   61287p01.dat (Size: 636 bytes / Downloads: 3)
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#7
(2020-07-26, 16:09)Magnus Forsberg Wrote: I have no idea of what I'm doing but this works, sort of.
I used, and adapted the example from Travis below.



Something breaks around the northpole.

Would it render better if the surface was recreated using a sphe primitive?
What does the difference between concave and convex triangles mean for the final impression?
Why are the lines wobbling?
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#8
(2020-07-26, 16:09)Magnus Forsberg Wrote: I have no idea of what I'm doing but this works, sort of.
I used, and adapted the example from Travis below.



Something breaks around the northpole.

One problem with spherical mapping is that things go bad at the north and south poles. This isn't a problem on the bottom due to the fact that there's nothing at the south pole, but two polygons on top share the north pole as one of their vertices.

Another problem is that your image needs to be quite a bit taller than it currently is to work as a mercator projection. It seems like the image you have is roughly -80 to +80 latitude. If you change the the second 180 to 160 in the !TEXMAP line to reflect this, things get a bit better, but still not perfect (at least in LDView). I need to check to see if there is a bug in LDView. The top edge of the texture doesn't work well. Having said that, there is no way to apply two separate textures to the same geometry, so having a texture stop in the middle of a polygon leaves the rest of that polygon blank, and there's nothing you can do about that.

If the sphere geometry stopped at +80 degrees, and then a cone was used above that, a separate texture could be applied to the cone from above, and things would probably look pretty good. (Getting that texture to line up would take some work, but it would certainly be possible.) In that case, your existing texture would work great with a 160 degree vertical span.

I also tested by resizing your original image to be 1600 pixels tall, and just filling in the new space with the tan background (leaving the angle in the file set to 180). That actually improves things a lot, but the longitude lines then stop before the pole, and extending them up runs into the north pole discontinuity problem again.

As for the wiggly lines, I think that is caused by the fact that the spherical geometry is so low-resolution.
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#9
(2020-07-26, 21:52)Travis Cobbs Wrote: One problem with spherical mapping is that things go bad at the north and south poles. This isn't a problem on the bottom due to the fact that there's nothing at the south pole, but two polygons on top share the north pole as one of their vertices.

Another problem is that your image needs to be quite a bit taller than it currently is to work as a mercator projection. It seems like the image you have is roughly -80 to +80 latitude. If you change the the second 180 to 160 in the !TEXMAP line to reflect this, things get a bit better, but still not perfect (at least in LDView). I need to check to see if there is a bug in LDView. The top edge of the texture doesn't work well. Having said that, there is no way to apply two separate textures to the same geometry, so having a texture stop in the middle of a polygon leaves the rest of that polygon blank, and there's nothing you can do about that.

If the sphere geometry stopped at +80 degrees, and then a cone was used above that, a separate texture could be applied to the cone from above, and things would probably look pretty good. (Getting that texture to line up would take some work, but it would certainly be possible.) In that case, your existing texture would work great with a 160 degree vertical span.

I also tested by resizing your original image to be 1600 pixels tall, and just filling in the new space with the tan background (leaving the angle in the file set to 180). That actually improves things a lot, but the longitude lines then stop before the pole, and extending them up runs into the north pole discontinuity problem again.

As for the wiggly lines, I think that is caused by the fact that the spherical geometry is so low-resolution.

OK, I will do some testing with the image and test the part Magnus made.
If all goes well I will have the physical part tomorrow so I can try match the worldmap as good as possible.
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#10
(2020-07-27, 20:39)Jaco van der Molen Wrote: OK, I will do some testing with the image and test the part Magnus made.
If all goes well I will have the physical part tomorrow so I can try match the worldmap as good as possible.

Please note that I repositioned the subfiles to fit the image, instead of moving the image.
This part, 61287, have a bad orientation. The outside, printed surface, will end up on the backside, in default position.

I have some ideas on how to change the surface. Let me know if you need help with the shape of the part.
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#11
(2020-07-28, 6:49)Magnus Forsberg Wrote: Please note that I repositioned the subfiles to fit the image, instead of moving the image.
This part, 61287, have a bad orientation. The outside, printed surface, will end up on the backside, in default position.

I have some ideas on how to change the surface. Let me know if you need help with the shape of the part.

I definitely need help with the part. I can do the image.
Here is another test.
   
Definitely some strange things happening on the north pole.
I got the part today, so now I am line drawing the outlines of the continents to match the part
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#12
(2020-07-28, 10:26)Jaco van der Molen Wrote: I definitely need help with the part. I can do the image.
Here is another test.

Definitely some strange things happening on the north pole.
I got the part today, so now I am line drawing the outlines of the continents to match the part

Some more WIP to download at:
https://drive.google.com/drive/folders/1...sp=sharing
I will update my work in this folder.
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#13
(2020-07-28, 13:03)Jaco van der Molen Wrote: Some more WIP to download at:
https://drive.google.com/drive/folders/1...sp=sharing
I will update my work in this folder.

I made two surfaces.
One based on a 4-8sphere primitive, and one replicating the globe/map, with longitudinal lines.
I think the logitudinal works best. May be that we should make a surface that completely match the black lines in the pattern?


Attached Files
.zip   globe.zip (Size: 10.43 KB / Downloads: 2)
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#14
(2020-07-28, 14:14)Magnus Forsberg Wrote: I made two surfaces.
One based on a 4-8sphere primitive, and one replicating the globe/map, with longitudinal lines.
I think the logitudinal works best. May be that we should make a surface that completely match the black lines in the pattern?

Indeed I agree that 61287p01_longitude.dat will work best. I will do some testing again tomorrow!

But don't you think we should match the image, instead of the geometry?
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#15
(2020-07-28, 19:49)Jaco van der Molen Wrote: Indeed I agree that 61287p01_longitude.dat will work best. I will do some testing again tomorrow!

But don't you think we should match the image, instead of the geometry?

2 subfiles are now at the Part Tracker.
https://www.ldraw.org/cgi-bin/ptscan.cgi...escription

Attatched here is a file with correct position on the part and texmap.  It might still need some finetuning.
I've extended the printed surface to include some of the bottom. It is actually also printed.
Shouldn't the tan part of the image be transparent?


Attached Files
.dat   61287p01.dat (Size: 536 bytes / Downloads: 3)
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#16
(2020-07-29, 11:56)Magnus Forsberg Wrote: 2 subfiles are now at the Part Tracker.
https://www.ldraw.org/cgi-bin/ptscan.cgi...escription

Attatched here is a file with correct position on the part and texmap.  It might still need some finetuning.
I've extended the printed surface to include some of the bottom. It is actually also printed.
Shouldn't the tan part of the image be transparent?

Looks good to me. Better than before. Still, some black longitude lines are strange at the north pole.
I have updated the files in my shared Google folder including transparent png files.
   

What do we think of the images so far?
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#17
I am not sure about the transparency of the image.
Compare with dark tan background left image (using the hex-color code for dark tan from ldconfig) and transparent right image.
Rendered with LDView in LPub3D

.jpg   Globe_tan.jpg (Size: 42.39 KB / Downloads: 35)    

Above post features image rendered in LDCad with tan background.
This is transparent background in LDCad
   
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#20
(2020-07-29, 12:49)Jaco van der Molen Wrote: I am not sure about the transparency of the image.
Compare with dark tan background left image (using the hex-color code for dark tan from ldconfig) and transparent right image.
Rendered with LDView in LPub3D


Above post features image rendered in LDCad with tan background.
This is transparent background in LDCad

If I modify the textures to be transparent, they look fine in LDView. I don't have the part, but I assume that the pattern is only present on the non-tan portions. Assuming that this is the case, then the textures should be transparent. I'm not sure why the LPub3D LDView rendering looks so bad.

Note that when I made the tan parts of your textures transparent, I was left with a faint tan halo around everything, although this wasn't really visible when it was applied to the part. If your source art is vector, you can regenerate the PNGs with transparent background instead of tan, and wouldn't have this problem. Or is that what generated the weird transparent screenshots you posted?

Can you upload the transparent version of the textures so I can investigate?
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#21
(2020-07-29, 19:43)Travis Cobbs Wrote: If I modify the textures to be transparent, they look fine in LDView. I don't have the part, but I assume that the pattern is only present on the non-tan portions. Assuming that this is the case, then the textures should be transparent. I'm not sure why the LPub3D LDView rendering looks so bad.

Note that when I made the tan parts of your textures transparent, I was left with a faint tan halo around everything, although this wasn't really visible when it was applied to the part. If your source art is vector, you can regenerate the PNGs with transparent background instead of tan, and wouldn't have this problem. Or is that what generated the weird transparent screenshots you posted?

Can you upload the transparent version of the textures so I can investigate?

OK, my source files are vector so I can easily make the background transparent.
That is what I used when I rendered in LPub3D using LDView that came with LPub3D. I'll have to test with your normal version of LDView, but I am unsure that works in LPub3D. I do not have access to my laptop with the graphics program (I use Adobe Fireworks btw) nor the LDraw stuff, so I will update later today.
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#22
(2020-07-30, 11:16)Jaco van der Molen Wrote: OK, my source files are vector so I can easily make the background transparent.
That is what I used when I rendered in LPub3D using LDView that came with LPub3D. I'll have to test with your normal version of LDView, but I am unsure that works in LPub3D. I do not have access to my laptop with the graphics program (I use Adobe Fireworks btw) nor the LDraw stuff, so I will update later today.

My daughter was so kind to give me some time on _my_ laptop, so I could upload transparent versions of the images in the Google folder: t-pb001.png and t-pb002.png =.
Where t stands for transparent, not tan. I have renamed the versions with background to dt-pb001.png and dt-pb001.png.

Next I tested and compare the two versions in LPub3D, LDView and LDcad.
Top globe is with transparent background, bottom is with dark tan background.

The strangest thing in LPub3D is that a certain area of the image is not rendered in every instance of the generated image.

   

LDCad does a very nice job rendering
   

LDView 4.3 did not render the textures and 4.2 crashed parsing the model.
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#23
(2020-07-30, 12:03)Jaco van der Molen Wrote: My daughter was so kind to give me some time on _my_ laptop, so I could upload transparent versions of the images in the Google folder: t-pb001.png and t-pb002.png =.
Where t stands for transparent, not tan. I have renamed the versions with background to dt-pb001.png and dt-pb001.png.

Next I tested and compare the two versions in LPub3D, LDView and LDcad.
Top globe is with transparent background, bottom is with dark tan background.

The strangest thing in LPub3D is that a certain area of the image is not rendered in every instance of the generated image.



LDCad does a very nice job rendering


LDView 4.3 did not render the textures and 4.2 crashed parsing the model.

The missing bits in LDView are probably due to a slider that needs to be adjusted. In the Textures section of the Primitives tab is an "Offset" slider. Setting it to a higher value will hopefully fix that problem. Having said that, the reason it isn't automatically set to a higher value is because doing so can introduce artifacts.

I made quite a few fixes to LDView's texture support relatively recently, and I don't know what code-base is being used by LPub3D. LDView 4.4 Alpha 6 (available here) renders the transparent version like this when the part color is set to Tan:

   
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#24
(2020-07-30, 19:35)Travis Cobbs Wrote: The missing bits in LDView are probably due to a slider that needs to be adjusted. In the Textures section of the Primitives tab is an "Offset" slider. Setting it to a higher value will hopefully fix that problem. Having said that, the reason it isn't automatically set to a higher value is because doing so can introduce artifacts.

I made quite a few fixes to LDView's texture support relatively recently, and I don't know what code-base is being used by LPub3D. LDView 4.4 Alpha 6 (available here) renders the transparent version like this when the part color is set to Tan:

OK, that looks good! I will test in LPub3D with LDV 4.4
LDV4.4 works just fine on my MacBook. I'll have to test in LPub3D on windows laptop.
   
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#18
(2020-07-29, 12:32)Jaco van der Molen Wrote: What do we think of the images so far?

I like them alot.
But the pattern is offset. I think the equator line has to be in the center of the image, but I'm not sure.
And the whole grid has to be perfectly adjusted to the center of the image.
The "empty" half-square to the left and right has to be equally wide. And together they should have the same width as a whole square.

The bottom surface is at y=0. The northpole is at y=-46, but the equator is at y=-20
Should the image be cut to compensate for the missing south pole?

Wount the image be distorted if we choose another angle than 180° ?
The angle from the northpole, to the bottom of the surface in the subfile, is ~150°.

I can position the image by changing the texmap code, but isn't it better to have the grid in the image centered?
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#19
(2020-07-29, 14:58)Magnus Forsberg Wrote: I like them alot.
But the pattern is offset. I think the equator line has to be in the center of the image, but I'm not sure.

It was, my mistake. Better version with some more tweaks in Drive folder

(2020-07-29, 14:58)Magnus Forsberg Wrote: And the whole grid has to be perfectly adjusted to the center of the image. 
The "empty" half-square to the left and right has to be equally wide. And together they should have the same width as a whole square.

The bottom surface is at y=0. The northpole is at y=-46, but the equator is at y=-20
Should the image be cut to compensate for the missing south pole?

I will do my best to correct the images.
Jaco van der Molen
lpub.binarybricks.nl
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#3
(2020-07-25, 14:15)Jaco van der Molen Wrote: Can the globe print be done trough texture mapping?
The part exists.

I am trying to make the image for mapping, but I am unsure how to map the image on the part.

It should be straightforward using spherical mapping. The attached file will map earth.png (not included) onto a sphere. (That just needs to be any map of the Earth using Mercator Projection, I think.) Obviously, mapping it onto the part is a bit more difficult, but it shouldn't be too hard.


.ldr   earth.ldr (Size: 493 bytes / Downloads: 5)

Note that the LDView 4.3 doesn't support spherical mapping, although LDView 4.4 will. LDD already supports it, as far as I know.
Reply
RE: Cylinder Hemisphere 61287pb002 and 61287pb001 (Earth map / Globe)
#5
(2020-07-26, 1:48)Travis Cobbs Wrote: It should be straightforward using spherical mapping. The attached file will map earth.png (not included) onto a sphere. (That just needs to be any map of the Earth using Mercator Projection, I think.)

Not just any map, but one where California is mythologically depicted as an island.  Wink
Reply
« Next Oldest | Next Newest »



Forum Jump:


Users browsing this thread: 1 Guest(s)