Thanks for this !! I must admit that between Effects and Physics, I'm not sure which file I have to download and install. Could you please provide documentation and directions in order to be sure to use the needed files for 3D integration ? Very nice and useful work BTW !!
hey I'm having trouble opening the example projects. My Construct 3 shows that they aren't valid .c3p files... Do you happen to know why is this happening? This message only appears in older example files too, the fog and screendoor example work just fine. I tried using a stable release instead of beta versions too, that didn't work either
I just tried: 3DObjectFragLight-8.c3p and FragLightTrain.c3p and they worked for me. Make sure you are using the latest version of the effects and 3dobject addon. When using the latest 3DObject in 3DObjectFragLight-8.c3p, remove the main.js script from the project (the addon does the change itself.)
If you still see an error on loading, Hit 'F12' to bring up dev console and take a snapshot of the error and post it here.
I downloaded the file and it is working for me with 2.5.0 (should be 1.5.0, but I messed up the numbering). If you show me error messages, especially on console, I can help more.
Hello! Looking to use this on a project I'm working on. Does this support smooth shading, or is it always faceted?
I'm looking to experiment with this to shade planets, and the last experiment I did with the lighting option available for the 3DObject would only show faceted shading.
This does per pixel shading, however the pixel normal is calculated from the tangent of nearby pixels, so it is effectively a plane. The difference from 3Object lighting is that the light attenuation can vary across the face of a polygon. Additionally spotlight edges can vary across the face of a polygon. Finally, you can enable procedural normals based on diffuse texture which can further vary the normal and light calculation.
I am also experimenting with adding normal map support to this effect with 3DObject, it is not yet available, but if the experiment works out, I'll add it as an option.
Thanks for the response! So in this case, is it possible to get smooth shading using procedural normals? Are procedural normals available in this plugin or are you referencing the procedural normals effect? (sorry for the rapid-fire questions)
Having more normal support on the 3D object would be awesome! I think that currently not being able to have smooth shading is holding back the 3DObject and lighting. Would love to get some smooth shading, as right now the only option I seem to have is making a duplicate of the sphere mesh and fake the shading with a gradient effect, which will cause me to have an extra mesh and draw call.
Right now, more focused on normal mapping. if something is critical for a project, I do commissions to. Per vertex color or normals requires major C3 engine optimization. Normal map is major engine optimization too.
Thanks for the response, I see, even with normal mapping it would be easy enough to create a normal map that smooths out the surface, so one could just do that I guess. Regarding the commissions, that's good to know! Definitely will be considering at some point. Is there a platform to submit commissions, what are your rates?
This depends on the requests I have made for SDK V2, waiting for a response from Scirra. In the past requests have takes months to years to get implemented. If they implement the requests, main.js will no longer be needed.
Scirra has said the current SDK will be supported at least for two more years (through C3 SDK V1 LTS), which is what is used with the main.js file.
With this version (early in development), you do not set the position/color in js code. You use the effect parameters. You can set them as properties in the editor or change them at runtime with events with the set effect parameter action. The JS code is now only to patch the vertex shader to enable the effect/addon.
← Return to asset pack
Comments
Log in with itch.io to leave a comment.
Why so many addons? Is it necessary to add them all? Do these 3D addons have cars, ships, characters?
Is there a step-by-step tutorial on how to implement and use each of these plugins?
Just use the last version (2.7.0).
if you use it with 3DObject you should not include the main.js file.
You can look at some of the sample projects to see how it works.
This addon does NOT draw 3D Models, it is only an effect.
Hey Mikal, are there any plans for tilemap support?
Not right now. There is a tile parameter towards the end, but it is just for flipping and tiling a single 'seamless' texture.
I think there's a problem with the vertex color js. In the newest update it only gives me a black screen.
Try using the latest versions of both frag light and 3D Object _and_ remove the main.js script from the project. If that doesn't work, let me know.
main.js is no longer necessary?
Nope, not if you have the latest 3DObject addon in the project.
what export settings should i use to export models with, and how do i export a float vec3?
Export from what source?
I am not sure about the float vec3 comment, is that for the format of vertex color?
Thanks for this !! I must admit that between Effects and Physics, I'm not sure which file I have to download and install. Could you please provide documentation and directions in order to be sure to use the needed files for 3D integration ? Very nice and useful work BTW !!
hey I'm having trouble opening the example projects. My Construct 3 shows that they aren't valid .c3p files... Do you happen to know why is this happening? This message only appears in older example files too, the fog and screendoor example work just fine. I tried using a stable release instead of beta versions too, that didn't work either
I just tried: 3DObjectFragLight-8.c3p and FragLightTrain.c3p and they worked for me. Make sure you are using the latest version of the effects and 3dobject addon. When using the latest 3DObject in 3DObjectFragLight-8.c3p, remove the main.js script from the project (the addon does the change itself.)
If you still see an error on loading, Hit 'F12' to bring up dev console and take a snapshot of the error and post it here.
I see. Thank you for your response!
The vertex color c3p isn't able to be opened
Did you install the latest 3D effect addon?
Yes everything has been updated
ok, I will take a look today, working on my side, but perhaps something is not updated on itch.
Can you also please hit F12 and share a picture of any errors in console?
I downloaded the file and it is working for me with 2.5.0 (should be 1.5.0, but I messed up the numbering). If you show me error messages, especially on console, I can help more.
I've got it working. Just an error on my end
hi i think u skipped 6? was wondering why my parameters in events werent working lol.
Yes, I did, I'll fix it at some point soon.
Hello! Looking to use this on a project I'm working on. Does this support smooth shading, or is it always faceted?
I'm looking to experiment with this to shade planets, and the last experiment I did with the lighting option available for the 3DObject would only show faceted shading.
Cheers!
This does per pixel shading, however the pixel normal is calculated from the tangent of nearby pixels, so it is effectively a plane. The difference from 3Object lighting is that the light attenuation can vary across the face of a polygon. Additionally spotlight edges can vary across the face of a polygon. Finally, you can enable procedural normals based on diffuse texture which can further vary the normal and light calculation.
I am also experimenting with adding normal map support to this effect with 3DObject, it is not yet available, but if the experiment works out, I'll add it as an option.
Thanks for the response!
So in this case, is it possible to get smooth shading using procedural normals? Are procedural normals available in this plugin or are you referencing the procedural normals effect? (sorry for the rapid-fire questions)
Having more normal support on the 3D object would be awesome! I think that currently not being able to have smooth shading is holding back the 3DObject and lighting. Would love to get some smooth shading, as right now the only option I seem to have is making a duplicate of the sphere mesh and fake the shading with a gradient effect, which will cause me to have an extra mesh and draw call.
Right now, more focused on normal mapping. if something is critical for a project, I do commissions to. Per vertex color or normals requires major C3 engine optimization. Normal map is major engine optimization too.
Thanks for the response,
I see, even with normal mapping it would be easy enough to create a normal map that smooths out the surface, so one could just do that I guess.
Regarding the commissions, that's good to know! Definitely will be considering at some point. Is there a platform to submit commissions, what are your rates?
You can DM me on the Construct Community discord. We'll see if normal maps come together, have to wrestle with C3 to get them to work.
Will it be possible to use and customize lighting without a main.js file?
This depends on the requests I have made for SDK V2, waiting for a response from Scirra. In the past requests have takes months to years to get implemented. If they implement the requests, main.js will no longer be needed.
Scirra has said the current SDK will be supported at least for two more years (through C3 SDK V1 LTS), which is what is used with the main.js file.
Hi! the 3d light plugin won't be finished?
What do you mean? Can you provide more details?
Does the effect work when exported to Android?
I would think it would on any modern android platform, but have not tried it.
Well that’s an instant purchase if I ever saw one. Thanks for pushing the 3D related capabilities of Construct, Mikal & Federico!
Thank you!
hi, any chance to add tutorial where edit size / position/ color for light in js code?
With this version (early in development), you do not set the position/color in js code. You use the effect parameters. You can set them as properties in the editor or change them at runtime with events with the set effect parameter action. The JS code is now only to patch the vertex shader to enable the effect/addon.