Jump to content

havenphillip

Members
  • Posts

    550
  • Joined

  • Last visited

Everything posted by havenphillip

  1. This is what I have: VERTEX: void main() { //entity matrix mat4 entitymatrix = entity.matrix[gl_InstanceID]; mat4 entitymatrix_ = entitymatrix; entitymatrix_[0][3]=0.0; entitymatrix_[1][3]=0.0; entitymatrix_[2][3]=0.0; entitymatrix_[3][3]=1.0; //model position ex_vertexposition = entitymatrix_ * vec4(vertex_position,1); gl_Position = projectioncameramatrix * ex_vertexposition; //clip float cam = cameraposition.y; float c = 2 * (cam - ex_vertexposition.y); vec4 e = ex_vertexposition; e.y += c; clipspace = projectioncameramatrix * e; //normals mat3 nmat = mat3(entitymatrix_); ex_normal = normalize(nmat * vertex_normal); ex_binormal = normalize(nmat * vertex_binormal); ex_tangent = normalize(nmat * vertex_tangent); ex_texcoords0 = vertex_texcoords0; } FRAGMENT: void main() { //Normal vec3 normal = ex_normal; normal = normalize(texture(texture1,ex_texcoords0).xyz * 2.0 - 1.0); normal = ex_tangent * normal.x + ex_binormal * normal.y + ex_normal * normal.z; normal = normalize(normal); vec4 clip = clipspace; clip.xyz *= vec3(1,-1,1); clip.x = (clip.x / clip.w) * 0.5 + 0.5; clip.y = (clip.y / clip.w) * 0.5 + 0.5; //Reflection vec4 reflection = texture(texture10,clip.xy)*0.8; //Diffuse Output fragData0 = reflection; }
  2. I was trying to make my own. So far I'm just using a shader. I'm basically just flipping the Y texcoord on the model so the image is flipped. But I can't seem to figure out how to make it move the opposite direction when I "yes" nod the camera.
  3. Would I need to use a script for this or can it be done entirely in the shader?
  4. Yeah this works. With this all you need to do is make a pivot, attach the script, and drag the player/camera into the script slot. The closer you get to the pivot the thicker the fog gets. fog zone.zip
  5. This is an interesting idea. I'm thinking maybe somehow use a PostEffect fog then thin it out or thicken it based on the distance of the cameraposition to the "center" of it. I'm going to try this. Something like: output = mix(regular screen, foggy screen, distance(cameraposition , self.entity:GetPosition())))
  6. I'm not that good at scripting but I think maybe put the self.Updatecamera() line in the UpdatePhysics() function? I think the Start() function would only update the camera once at the beginning and that's all. You want it to keep updating. Something like that
  7. Yeah man that's awesome. I'm glad you like them . I don't mind if you put me in there somewhere.
  8. havenphillip

    Art of the pull

    Macklebee was legit. Wish he was still here.
  9. havenphillip

    Geometry

    Yooooo...that looks awesome.
  10. If the problem's in the shader I can probably figure it out. If you get stuck you can send it to me and I'll fiddle with it. But my best guess - assuming it's not a bug, is that either the shader is not compiling or maybe you made a change and forgot to hit save somewhere so the changes didn't update.
  11. Looks like maybe the shader isn't compiling?
  12. Hey Josh how did you get the planar reflections to stop following the camera on the water? Seems like no matter what I do if I nod the cam "yes" the reflection wont' stay put. This is what I have. I'm stuck here: vec2 coord = gl_FragCoord.xy/buffersize; if (isbackbuffer) coord.y = 1-coord.y; vec4 reflectcol = texture(texture10,coord); fragData0 = reflectcol;
  13. Will you have solved the refraction problem with foreground objects refracting by first release ?
  14. This is great dude Leadwerks needed this. I always had trouble with mist around waterfalls and water. Are you going to have the same z-sort/alpha system or is alpha going to be built-in to the standard mode?
  15. Subquestion how much do you think texture resolution plays into the speed? Like high res up close but low res far away.
  16. Looks like maybe the normal calculation on the model?
  17. Yeah sorry I didn't clarify. I added a normals from heightmap part to it to get an extra boost on the groove of the tread. I think if you don't want the heightmap used you can hide this line: normal = mix(heightnormal,normal,0.5); ...and remove the whole "normals from heightmap" section and it should work fine if you have a dramatic normal map.
  18. A lod system basically looks like three copies of the models and textures with varying degrees of polygons/resolution, right? Is any other thing to it? I always feel like I'm probably going to miss something obvious.
  19. Leadwerks has all but ruined video gaming for me. I just look around trying to figure out how they made those scenes now. I was playing Last of Us II and some of those forest scenes are just amazing. My question is how are they able to put so much stuff in the scene without losing speed? If I could even make Uncharted quality I'd be happy. Is it polygon count or LOD systems or both or none or what?
  20. That's cool. It didn't like "float m" as a constant for some reason idk.
  21. Yeah I don't know what he's capable of or is willing to kick down, but the more I think about it "Ultra Light" is kind of cool. Reminds me of beer.
  22. I get it Josh has to do what he has to do. I don't like that I'm decreasingly his target market because Leadwerks is great for me. I agree with him he should focus his efforts towards his goals. Maybe down the line he'll add some Ultra stuff to regular Leadwerks or even come up with Ultra Light or something for the people who want to just buy it outright. I feel like a company like NASA would happily pay a subscription and that would be cool to be like an outside contractor for a company like that or for Elon Musk or something. You couldn't really blame him for ditching us for something like that. My only real complaint with Leadwerks was the lack of help with shaders. I just got the internet and started trying to figure it out and passed on what I learned. I feel like thats the way tutorials would have to go. It would be cool to read tutorials from a guy like reepblue. I think the community could be way cooler if it went that direction.
  23. Bro I get it but I don't like it. Last thing I need is another bill to pay. Couldn't you just do a one-time purchase option but charge a ridiculous amount of money for it so people are more prone to just do the subscription? There's people like me out there who just prefer not to keep having to update my payments.
  24. "You have used 411.22 MB of your 200 MB attachment limit. " is that going to matter? I thought I had at least a gigabyte left.
×
×
  • Create New...