Jump to content



Photo
- - - - -

Some of my primitives with transparency have "edge" or "halo"?

primitive help transparency

  • Please log in to reply
10 replies to this topic

#1 bjinn

bjinn

    Neophyte

  • Members
  • Pip
  • 5 posts

  • Flag: Canada

  • Favorite Pinball: KISS, Elvira and the Party Monsters

Posted 29 April 2025 - 08:17 PM

Greetings!

I try my best not to bother with my build questions as I've found that with enough time and searching (and sweating...) the answer(s) can be figured out on my own... but one matter that I can't seem to resolve is when I create a Primitive with an image containing a transparency. 

You can see in the example image (the front of my building is a PNG with transparency brought in via a Primitive) that in the areas where the image has no opaque value still still renders items behind it a bit more brightly... and there is a very faint "edge" to the PNG/Primitive. Ideally, I'd be able to get rid of both the edge and the halo/brightness effect it casts.

I've messed around a bit with the Depth and have researched settings for my GPU but to no avail. Hoping that maybe there is a quick answer to this problem that maybe others have encountered? 

Many thanks in advance for your time! 

 

screenshot_20250429_130419_gallery_t.jpg



#2 jpsalas

jpsalas

    Grand Schtroumpf

  • VIP
  • 7,153 posts
  • Location:I'm Spanish, but I live in Oslo (Norway)

  • Flag: Norway

  • Favorite Pinball: I like both new and old, but I guess I prefer modern tables with some rules and goals to achieve.



Posted 30 April 2025 - 04:13 AM

I think you need to remove this property from the transparent primitives:

 

primitive_option_t.png

 

Try it and check how it looks.


If you want to check my latest uploads then click on the image below:

 

vp.jpg

 

WIP? Some EM tables


#3 bjinn

bjinn

    Neophyte

  • Members
  • Pip
  • 5 posts

  • Flag: Canada

  • Favorite Pinball: KISS, Elvira and the Party Monsters

Posted 30 April 2025 - 04:50 AM

Thanks so much for your response, @JPSalas!

Clicking off the "Hide parts behind" property *does* solve the transparency 'halo' and edge problem... but it introduces a new issue in that there are elements now showing through the opaque parts of the primitive. That's probably why I had "Hide parts behind" clicked on initially. 

A quick test with tweaking the depth biases for the primitive and items in the background doesn't have any effect for what's showing through the front of the building now. 

 

untitled-1_t.png
 



#4 jpsalas

jpsalas

    Grand Schtroumpf

  • VIP
  • 7,153 posts
  • Location:I'm Spanish, but I live in Oslo (Norway)

  • Flag: Norway

  • Favorite Pinball: I like both new and old, but I guess I prefer modern tables with some rules and goals to achieve.



Posted 30 April 2025 - 05:01 AM

Try moving the primitive a little more to the front. Or you may replace that flat primitive with a ramp.


If you want to check my latest uploads then click on the image below:

 

vp.jpg

 

WIP? Some EM tables


#5 bjinn

bjinn

    Neophyte

  • Members
  • Pip
  • 5 posts

  • Flag: Canada

  • Favorite Pinball: KISS, Elvira and the Party Monsters

Posted 30 April 2025 - 01:29 PM

Thanks for the suggestions, JP! 

I tried nudging that Primitive more to the front but to no avail.  I then replaced the Primitive with a Ramp and applied appropriate image/dimensions/etc and thought it was working (solved the transparency/opaque issue that recently arose!) but when you look closely to its perimeter it has gone back to doing that original brightened halo effect and thin edge: 

untitled-11_t.png


Edited by bjinn, 30 April 2025 - 01:30 PM.


#6 jpsalas

jpsalas

    Grand Schtroumpf

  • VIP
  • 7,153 posts
  • Location:I'm Spanish, but I live in Oslo (Norway)

  • Flag: Norway

  • Favorite Pinball: I like both new and old, but I guess I prefer modern tables with some rules and goals to achieve.



Posted 30 April 2025 - 07:33 PM

I guess you have tried to change the primitive Depth bias to -1000 or similar. Sometimes it helps with those weird artifacts.


If you want to check my latest uploads then click on the image below:

 

vp.jpg

 

WIP? Some EM tables


#7 bjinn

bjinn

    Neophyte

  • Members
  • Pip
  • 5 posts

  • Flag: Canada

  • Favorite Pinball: KISS, Elvira and the Party Monsters

Posted 30 April 2025 - 10:32 PM

Yeah, I've tried a whole bunch of random numbers (both positive and negative) in that Depth Bias field.  I will keep trying and might get lucky one of these days!  (I'm also going to see if there is any issue with how I'm generating my PNGs as that seems to be a bit of a common denominator here...) 

Thanks so much for sharing your ideas with me - much appreciated!



#8 kiwi

kiwi

    Pinball Fan

  • VIP
  • 2,627 posts

  • Flag: Italy

  • Favorite Pinball: Star Trek 25th Anniversary



Posted 01 May 2025 - 07:40 AM

I have seen the outer halo on flat primitives and with a scale, X Y or Z, at zero.

 

Is it a set of primitives?

Can you attach an example of what you are doing so we can understand better?



#9 Gravy

Gravy

    Pinball Fan

  • VIP
  • 1,147 posts

  • Flag: Australia

  • Favorite Pinball: Simpsons pinball party



Posted 02 May 2025 - 12:46 AM

This is unlikely related but I'll mention it anyway just in case. A while back when attempting to apply an 8 ball texture to the pinball, it resulted in a milkiness to the ball if the texture contained pure white, I wonder if you are using white as your transparent colour? The fix in the case of the ball was to change the transparent colour to slightly grey.

https://www.vpforums...=51249&p=517574

 

 

Edit: If your PNG has an alpha channel for transparency, are you sure that the channel is 100% transparent?


Edited by Gravy, 02 May 2025 - 01:04 AM.

Pinball Addict


#10 bigus1

bigus1

    Pinball Fan

  • Members
  • PipPipPipPip
  • 930 posts
  • Location:Brisbane, Australia

  • Flag: Australia

  • Favorite Pinball: Firepower

Posted 02 May 2025 - 03:16 AM

I had a transparency issue just last night that sounds similar. I changed the material to a non-active one and the problem vanished. If your image has transp bits, they'll still work fine on a static material.



#11 bjinn

bjinn

    Neophyte

  • Members
  • Pip
  • 5 posts

  • Flag: Canada

  • Favorite Pinball: KISS, Elvira and the Party Monsters

Posted 02 May 2025 - 05:26 PM

Thanks again everyone for chiming in and offering some more ideas/solutions! 

To answer a couple of the recent questions/points:

-It is a flat primitive. The building you see in my images contains a flat primitive for the front-facing wall and it has transparency to create its shape. For other similar buildings, I've actually created a "slice" between the square base and triangular slopping top area so that neither portion required a transparent section like in my example (and rotated the slopping piece) and that avoids this issue.   It's a slight bit more work so I thought I'd see if there was something incorrect about my current process of placing an alpha PNG into a Primitive and placing in front of the entire structure in one fell swoop. My building example only uses a single Primitive for the front facing side, it is not part of a set or collection. 

-To Gravy's point/example... I was trying to work in that direction actually as I figured it could have something to do with the colour values when modulating... but ultimately I'm not even using a black or white to target to create my transparent areas in the PNG... in Photoshop, I simply create my PNG with regions transparent and export them out/use as the image for my Primitive in VPX. And, yeah, the transparent areas are definitely void of any and all values. My understanding as I learn VPX has been that the targeting of black (or another colour) is how transparent regions were handled in previously versions... but that it's not exactly applicable any longer if you're creating PNG-24s with alpha channels - PLEASE correct me if I'm wrong on this! :)

-Thanks Bigus - It does sound a bit similar...  I changed my primitive to Static Rendering and it has had a little bit of effect on matters... Below is the latest example (with Static Rendering turned ON, Reflection enabled turned ON, and Hide Parts Behind turned ON):

untitled-10_t.png

 

It seems that if I turn everything off  and only keep Visible and Reflection Enabled both ON then it's as close as I can get, all things considered:

untitled-2_t.png

Not sure what changed between its current state and earlier when JP noted turning off Hide Object Behind could be the culprit but it's in a not-too-bad state now...I really appreciate you all taking a quick stab at this  :dblthumb: 
 







Also tagged with one or more of these keywords: primitive, help, transparency