Jump to content

pointSize of shaderMaterial


Recommended Posts

It’s not generic if it’s a shader material and you did not inclued the point cloud stuff.

a shader material you define yourself or compile from other shaders.  So if there is no point cloud support on the shaderMaterial then it won’t do anything.  The only reason it works with standard material is that shader has it set up and a setter for the variable pointSize that sets the value on the effect when it’s changed I’m assuming.

@NasimiAsl what’s the quickest way to add point cloud support to his shader? 

I would just copy and paste the fragment code for the pointcloud stuff outta the standardMaterials shader. 

Link to comment
Share on other sites

great, i get what you mean now.

i assumed that since it is possible to use things like .wireframe = true; and .pointsCloud = true; with shaderMaterial, then pointSize would also be supported, but i get your point now.

some help with copy pasting the pointsCloud code from the standardMaterial would be much appreciated.

Link to comment
Share on other sites

If wireframe and pointCloud work then point size should work, odd. When I get home I’ll take a look.



I do not see anything here for wireframe or pointCloud support.  

Ill get you a better awnser once I’m off my phone and on a pc.

Link to comment
Share on other sites

if you can find distance formula you can manage that by discard  need more  time to calculate that

y = f( length(vPositionW-vEyePosition) ) ; f is  your formula


it is not depend your shader that control by webgl base kernel so you can just discard that

find that :) i am stupid most of the time




Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...