Skip to main content
Question

Strange view of CityGML model


cossy27
Contributor
Forum|alt.badge.img+1

Hello!

I generated a CityGML building model from an fbx model. The model could be opened in FZKViewer but the view is very strange. I could see the textures in the back when I am on the front view. It is like the surface in front of me becomes a very transparent glass.

This happens at all of the sides of the model except the roof and ground surface. When I turn off the texture, everything is back to normal. 

Is it the problem of the texture? How could I check if it is on the texture and how could it be fixed?

 

2 replies

virtualcitymatt
Celebrity
Forum|alt.badge.img+34

This sounds a bit like an issue with surface orientation. It can be that some surfaces are oriented incorrectly and only the front side is rendered but the front is pointing in the wrong direction. in FME you can try to set the surfaces so that everything is double-sided. This may solve your issue. 

If it’s not an orientation issue then possibly the issue comes from a setting in the appearance. The Alpha value might be set to something other than one. 

this might actually be easier to fix in the CityGML file itself rather than in the FME workspace. You should be able to just do a find and replace with a text editor. 

Here’s an example of a material which has transparency set. If you set this to 0.0 is should be opaque. You can also just remove this line and the default will be opaque.  

        <app:X3DMaterial>
          <app:isFront>true</app:isFront>
          <app:transparency>0.8</app:transparency>
          <app:target>#fme-gen-ee91bb7b-7c5b-4c2b-9398-3dd51edf7732</app:target>
        </app:X3DMaterial>

If using texture images it could be the texture images themselves. If the textures are PNG images then it could be they have a ALPHA band set. You should see the same thing in FME though to be honest. You can try setting the textures to be JPEG - the CtiyGML writer supports this. JPEG images are smaller and don’t support transparency. 

 


cossy27
Contributor
Forum|alt.badge.img+1
  • Author
  • Contributor
  • January 8, 2025

Hello Matt, thank you for your reply.

In my GML file, there is no such line about transparency under <app:X3DMaterial>. 

Plus, the texture that I am using is JPG (which is the same as JPEG).

I am not sure whether the orientation that you mean is the normal vector of the surfaces. If so, I have already checked in Blender that the normal vector of the surfaces are correct in the FBX that I used to convert into CityGML.

I may just try adjusting the settings in appearance.

Thanks for your help!


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings