But they MAY be patentable! :-)
Hm... on second thought... I guess one could copyright a shader. I mean if I wrote some code, I would hold the copyright to it automatically.
The thing is, there is a large gray area when you get down to individual routines, and just because someone may not copy your program does not neccessarily mean they cannot recode certain algorithms you have coded and end up with the same code.
But it would be very rare for someone to word for word, symbol for symbol accidentally duplicate someone else's work, since there are so many ways to code anything. It could come down to a judge looking at the two functions, and decididng if they are so similar that one must have been copied from the other, and then dtermine who did the copying.
When I said you could not copyright a shader, what I meant was you can't copyright an algorithm. But you can copyright code you have written. You can PATENT an algorithm, but not copyright it.
Think of it like a book. You might be able to patent a plotline (people are trying now) but you cannot copyright a plotline. You can copyright characters. You can copyright a paragraph. But you can't stop someone from writing a book about a kid who goes to a school for wizards. You CAN probably stop someone from writing a book about a kid who goes to a school for wizards IF it can be shown that the characters and plot and actions and such are SIGNIFICANTLY similar. Say, if you named your main character Parry Hotter, and he attended the school of Wizardry and Witchraft, you probably would not get away with that.
But I think with a function you could get a whole lot closer to the original without infringing copyright. I think they would have to show without a doubt that you did lift it from them and did not simply accidentally come up with the same function. And even then, if something is too small, it can't usually be copyrighted. On the other hand, 1 minute of silence can be copyrighted and defended sucessfully in the music world. So nobody can really give you a clear answer on a specific item. You just have to figure the odds and take a gamble, and hope nobody takes you to court.
Hm... on second thought... I guess one could copyright a shader. I mean if I wrote some code, I would hold the copyright to it automatically.
The thing is, there is a large gray area when you get down to individual routines, and just because someone may not copy your program does not neccessarily mean they cannot recode certain algorithms you have coded and end up with the same code.
But it would be very rare for someone to word for word, symbol for symbol accidentally duplicate someone else's work, since there are so many ways to code anything. It could come down to a judge looking at the two functions, and decididng if they are so similar that one must have been copied from the other, and then dtermine who did the copying.
When I said you could not copyright a shader, what I meant was you can't copyright an algorithm. But you can copyright code you have written. You can PATENT an algorithm, but not copyright it.
Think of it like a book. You might be able to patent a plotline (people are trying now) but you cannot copyright a plotline. You can copyright characters. You can copyright a paragraph. But you can't stop someone from writing a book about a kid who goes to a school for wizards. You CAN probably stop someone from writing a book about a kid who goes to a school for wizards IF it can be shown that the characters and plot and actions and such are SIGNIFICANTLY similar. Say, if you named your main character Parry Hotter, and he attended the school of Wizardry and Witchraft, you probably would not get away with that.
But I think with a function you could get a whole lot closer to the original without infringing copyright. I think they would have to show without a doubt that you did lift it from them and did not simply accidentally come up with the same function. And even then, if something is too small, it can't usually be copyrighted. On the other hand, 1 minute of silence can be copyrighted and defended sucessfully in the music world. So nobody can really give you a clear answer on a specific item. You just have to figure the odds and take a gamble, and hope nobody takes you to court.