Fixed a couple of regressions from namespace refactoring

From the ES3 spec, section 4.4.2 (about DeleteRenderbuffers):
"Unused names in renderbuffers are silently ignored, as is
 the value zero."

And from section 6.1.5:
"IsSampler will return TRUE if sampler is the name of a
 sampler object previously returned from a call to
 GenSamplers and FALSE otherwise".

Also, glIsSampler can use Context::isSampler(), which uses
ResourceManager::isSampler(), which should only look whether a
name has been reserved, not whether the object is allocated.

Note: Even though the spec mentions (about Sampler objects):
"they acquire state only when they are first used as a parameter
to BindSampler, SamplerParameter*, GetSamplerParameter*, or
IsSampler", it shouldn't hurt to not allocate the object when
calling IsSampler, since a subsequent call to any other Sampler
object related function should allocate it.

Change-Id: I69c9d8bbcf93231747b913c0afbd970c78d02cf1
Reviewed-on: https://swiftshader-review.googlesource.com/5161
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
3 files changed