Vista?

Some Vista users are reporting problems, and I'm not sure if it's related to OpenTK or my own code. So far I know one user has version 6.0.6000.16386 of opengl32.dll, and is reporting the following error:
Error Screenshot

My own version of opengl.dll (5.1.2600.2180) on Windows XP works fine (I assume that's the significant DLL here). Is there possibly a compatibility problem working with different versions of opengl32.dll? Or just an OS problem?

The game in question was the same one linked in my previous post:
http://sgdk2.enigmadream.com/support/TVSGDK2.zip
And the OpenTK code is based off of version 1166 from SubVersion.

(Edit: Also, what in the world is this "@" prefix I see on some of the parameters. I can't find any documentation on that for C#.)


Comments

Re: Vista?
posted by the Fiddler

Try adding a few GL.Error checks at the code that causes the problem, they might shed some light.

Also, the drivers up to date? Outdated drivers sometimes cause strange problems on Vista, especially with Nvidia video cards.

I spend half of my time on Vista (x64) working on OpenTK, and it looks stable here. After how much time does this error occur?

Re: Vista?
posted by BlueMonkMN

I'll try adding some error checks in my own code. I'm not sure if that could shed any light on an Access Violation, unless the access violation is the result of some other failed call, but it's hard to guess where that would be -- perhaps in loading the texture.

Also, in case you didn't notice the edit that I made after your previous post (I was updating at the same time you were posting I guess), what is this "@" modifier I see on some parameters?

I'll try to get more information about the drivers too.

Edit: I assume the error happens during startup. They didn't mention anything about seeing anything work at all. They said they couldn't even run the game, so I guess the main window doesn't even appear (?)

Re: Vista?
posted by BlueMonkMN

I don't see any GL.Error -- I assume you mean GL.GetError. So I created this function:

  private void CheckError()
   {
      ErrorCode ec = GL.GetError();
      if (ec != 0)
      {
         System.Diagnostics.StackFrame sf = new System.Diagnostics.StackFrame(1, true);
         string fileName = sf.GetFileName();
         int lineNum = sf.GetFileLineNumber();
         System.Diagnostics.Debug.WriteLine(String.Format("{0} at {1} line {2}", ec.ToString(), fileName, lineNum));
      }
   }

I do see a whole bunch of errors occurring even on my own system. Strange that everything seemed to be running so well! It looks like my second call to GL.GenTextures is causing InvalidOperation. But the graphics which it loads seem to work fine. It even returns a valid (new) texture number in the output parameter which lets the rest of the function work. Subsequently, every call to BindTexture is failing.

This is my code for loading a texture. It reports success on the first call and outputs 1. It reports failure on the second call, but outputs 2 and works anyway:

  private int GetTexture(string Name)
   {
      int texture;
      GL.GenTextures(1, out texture);
      CheckError(); // Line 186
...

Later on I have this code. The last CheckError here reports hundreds of InvalidOperation errors while the code is running, but I see no evidence of failure:

  public void DrawFrame(TextureRef texture, System.Drawing.Rectangle sourceRect, System.Drawing.PointF[] corners, int offsetX, int offsetY)
   {
      if ((m_currentOp != DisplayOperation.DrawFrames) ||
          (m_currentTexture != texture))
      {
         if (m_currentOp != DisplayOperation.None)
            GL.End();
         else
         {
            GL.TexEnv(TextureEnvTarget.TextureEnv, TextureEnvParameter.TextureEnvMode, (float)TextureEnvMode.Modulate);
            CheckError(); // Line 417
            GL.Enable(EnableCap.Blend);
            CheckError();
            GL.BlendFunc(BlendingFactorSrc.SrcAlpha, BlendingFactorDest.OneMinusSrcAlpha);
            CheckError();
            GL.Enable(texCap);
            CheckError();
            GL.Disable(EnableCap.DepthTest);
            CheckError();
            GL.Disable(EnableCap.Lighting);
            CheckError();
            GL.Disable(EnableCap.Dither);
            CheckError();
         }
         GL.BindTexture(texTarget, texture.Texture);
         CheckError(); // Line 432
         GL.Begin(BeginMode.Quads);
...

The BindTexture in that second block actually triggers the getTexture in the first block (because the Texture property does lazy initialization) if that makes any difference. Despite all these failures being reported, everything appears to work.

This is a sample of the debug output from the first report of an error. The remainder is very repetitive.

InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 186
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 417
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 432
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 417
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 432
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 417
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 432
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 417
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 432
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 417
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 432
InvalidOperation at C:\Documents and Settings\Ben\Desktop\SGDK2\TVSGDK2\Display.cs line 417

Edit: I tried removing the "else" and allowing the block of code after the GL.End to execute regardless of the condition, then all the errors were on the equivalent of line 417 (which ended up being line 415) and none were occurring on line 432 any more. I'm not sure why I had the else there.

Edit 2: I decided to put CheckError all over the place because it appeared that some of the errors being reported were left over from other operations. As it turns out, all my errors are occurring during calls to GL.End(). Any way to narrow down the source of the actual error?

Re: Vista?
posted by the Fiddler

Ok, I just recovered from a hard disk crash that made Vista unbootable (there's a free software called testdisk that works miracles!)

The '@' allows you to use names that are reserved keywords as variables, e.g. void Foo(int[] @params) (params is a reserved keyword in C#). It's quite useful when generating bindings to C.

Errors in GL.End() usually indicate that the code calls a function that is not allowed between GL.Begin - GL.End. I don't remember off-hand what operations are not allowed, but in general anything that has to do with construction will fail (e.g. VBOs, display lists, textures). Try commenting out code until the error stops happening.

Errors such as these will hopefully be much easier to catch from OpenTK 0.9.2 onwards - I'm planning to add implicit GetErrors in every OpenGL call, so you won't need to litter your code with these (in debug builds only, of course).

Edit: I forgot to mention that once an OpenGL error occurs, behavior is implentation dependent. Usual symptoms include random crashes, horrible performance and/or OpenGL functions failing at random. Different drivers will produce different results.

There's a good chance that the access violations will disappear as soon as you discover the problem.

Re: Vista?
posted by BlueMonkMN

As it turns out, all my error checking was causing errors, which was a real pain. I didn't realize you weren't allowed to check for errors between a Begin and an End. But I finally narrowed it down to the fact that I was trying to change the scissor rectangle between a begin and an end. I'll try sending a fixed version to the user who was having a problems and get back with the results later.

Re: Vista?
posted by BlueMonkMN

It looks like the systems now fail due to (I suspect) inadequate hardware support (graphics on the problem systems don't fail immediately, but they do render improperly and eventually fail). I need to figure out how to do better checking and reporting on hardware requirements before allowing the program to continue.

Re: Vista?
posted by the Fiddler

You could use GL.SupportsExtension/GL.SupportsFunction to detect what opengl functions are supported. In general, a GL.SupportsExtension("VERSION_1_5") is enough to ensure that you can use VBOs.

GLSL is a little more complicated: the opengl wiki contains a good guide here on how to detect different shading models.

Re: Vista?
posted by BlueMonkMN

I tried GL.SupportsExtension("VERSION_1_5") all the way down through GL.SupportsExtension("VERSION_1_1") and they all returned false on my system. What could I be missing here?

Also, if anybody is willing to look at the code, I have a C# Express 2008 project posted at http://sgdk2.enigmadream.com/support/TVSGDK2Src.zip.

Everything is working fine in my environment -- no errors reported from GL.GetError any more even. But other environments where this project worked in DirectX are completely unable to draw graphics, and still others are mostly working but showing odd behavior (drawing the wrong graphics sometimes). So I would appreciate any help in identifying fundamental flaws that might exist in this code, which is a general example of the kind of code generated for all SGDK2 projects, with the exception of a few customized pieces.

Re: Vista?
posted by the Fiddler

I've tested on a couple of computers and both show the same results: shows a windows menu, an fps counter and two white rectangles; if I press enter, the screen goes white and nothing happens.

What should the program show?

Computer config: XP on Intel 865 and Vista x64 on Ati X1950Pro.

Ok, you try this: build a debug version of OpenTK and route System.Diagnostics.Debug to the disk. OpenTK is quite chatty in debug mode, and maybe it can help us find out what's going wrong.

Re: Vista?
posted by objarni

Maybe it would be a good idea to have a debug-version of OpenTK.dll ready-for-download?

Re: Vista?
posted by the Fiddler

Yes. I'll put the debug version along the release one in the next package.

Re: Vista?
posted by Inertia

Taking a quick look at the project, in Display.cs DrawFrame() DrawPoint() there might be more problems with changing state inside a begin/end block.

opengl.org: Only a subset of GL commands can be used between glBegin and glEnd. The commands are:
glVertex,
glColor,
glIndex,
glNormal,
glTexCoord,
glEvalCoord,
glEvalPoint,
glArrayElement,
glMaterial, and
glEdgeFlag.

Regarding extensions always reporting negative, this is most likely happening because there's no current GL context. Not sure if this is related, but Nvidia drivers under Vista64 seems to be rather slow at application start compared to Ati's (torusknot test launches on my config in the blink of an eye, while on a 8600GTS it takes more than a second until the app starts drawing. Both systems dual core AMD, >4GB Ram). I'd recommend trying to add a GL.Finish() very early into your initialization, to make sure there's no GL code executed before GL is ready for it.

Re: Vista?
posted by BlueMonkMN

I don't think there's any way for anything other than GL.TexCoord2 and GL.Vertex2 to execute between the GL.Begin in DrawFrame and a GL.End. The DrawFrame function sets m_currentOp to DisplayOperation.DrawFrames and every other GL call (which are all confined to the Display object) that might be called checks the state before doing any work. If it's going to execute any call outside the set you listed, it performs GL.End first if it sees that the state is not DisplayOperation.None. Do you see something I don't as far as allowing the potential for other functions to get in there? Maybe I need to add some protection to the Resize event. In any case, I'm not getting errors reported any more, which should be a good sign that nothing else is getting in there any more, right?

Re: Vista?
posted by the Fiddler

Not getting errors is certainly a good sign.

One thing that might be good to check: do you set parameters/mipmap levels for all textures? If you forget some, things may not appear (or may appear depending on default values set by the drivers).

Re: Vista?
posted by BlueMonkMN

I've never done anything with mipmaps, so I don't know anything about that, and the only parameters I set were those I found in the sample code from GameDev.net. Basically I'm trying to draw 2D sprites with OpenGL using the example set by this code:
http://www.gamedev.net/reference/articles/article2429.asp

There have been a few adjustments since I copied that code (use TextureRectangleArb instead of TextureRectangleNv for example), but that's where I started. Is there something I should check to see if the hardware supports TextureRectangleArb? (The article mentions using TextureRectangleNv or TextureRectangleExt but not TextureRectangleArb, which I believe you mentioned a while back.)

Re: Vista?
posted by the Fiddler

First, you should check whether GL.SupportsExtension("GL_ARB_texture_rectangle"); returns true. The you should check every function from this extension with GL.SupportsFunction();

The fact that everything returns false in your system is not very encouraging (I'll have to check this), but everything seems to work here...

Also, check the specs for the extension. Especially this part:

NPOTS textures are accessed by dimension-dependent (aka
non-normalized) texture coordinates. So instead of thinking of
the texture image lying in a [0..1]x[0..1] range, the NPOTS texture
image lies in a [0..w]x[0..h] range.

Are you using the correct texcoords? Also, do you set a (non-mipmapped) minification and a magnification filter with GL.TexParameter, for every texture? If you don't, the textures will appear white.

Re: Vista?
posted by BlueMonkMN

After I moved the code to a place where the control was fully initialized, GL.SupportsExtension was working fine and returns true for VERSION_1_5 and for GL_Arb_texture_rectangle. Of course my system is the one where it works. I posted the result so others could try it. The one person who has replied so far says that he still gets an access violation exception before anything else. He tried it on a friend's computer with Vista and it seemed to work fine there. He tried it in safe mode on his own computer and got a message that OpenGL 1.5 was required (one of the tests I recently added) instead of the access violation. The binary he's using now is at http://sgdk2.enigmadream.com/support/TVSGDK2c.zip

Edit: I am using the correct texture coordinates for the Arb extension (which is why everything works fine in my environment, I assume). I'm not limiting the range to be 0-1 (that never occurred to me until I started researching alternatives to ARB, NV and EXT, but I much prefer ARB or its rough equivalents, NV and EXT).

I do have the following code when creating a texture, which I assume applied the minification and magnification filters.

GL.TexParameter(texTarget, TextureParameterName.TextureMinFilter, (int)TextureMinFilter.Linear);
GL.TexParameter(texTarget, TextureParameterName.TextureMagFilter, (int)TextureMagFilter.Linear);

Edit:
This user also reports that he's using an ATI Radeon Xpress 1150, and updated the drivers to 8.3 just under a week ago

Should I post some OpenTK sample/test application to see how it runs in that environment? (Does the newer TVSGDK2 run any differently in yours?)

Re: Vista?
posted by the Fiddler

Ok, the app now fails on the machine with the integrated 865 chipset (no VERSION_1_5 support). I'll test on the other machine when I get home.

A debug version of Examples.exe (comes with OpenTK) could shed some light to the AccessViolation.

Edit: or you could try sending your app with a debug version of OpenTK to your tester.

Without the debug output it's difficult to see what's going wrong (which function fails? why? is a context created? is the pixel format supported? are monitors enumerated? resolutions?)

Re: Vista?
posted by Inertia

public void DrawPoint(System.Drawing.Point location)
   {
      ....
      GL.Disable(texCap);
      GL.Vertex2(location.X, location.Y);
   }

Either you are changing state inside a begin/end block here, or you are calling GL.Vertex2() outside one.

The game starts without any complaint under Vista64/Radeon 3870 (catalyst 8.3) and shows the options Play or Quit. (Any keypress will show unhandled exceptions, but that wasn't the question asked I guess)

Re: Vista?
posted by BlueMonkMN

Good catch on DrawPoint. Fortunately (or unfortunately, depending on how you look at it), this particular application doesn't call DrawPoint. DrawPoint is there primarily for the implementation within the IDE where it draws a picture of a path showing where the sprites will travel. Pretty much the only functions called at runtime are DrawText and DrawFrame.

The person who was reporting access violation exceptions says that the OpenTK samples were also reporting Access Violation exceptions, but the Mono samples worked fine. Looks like it might be a .NET problem.

What unhandled exception occurs when pressing a key?

Re: Vista?
posted by Inertia

occurs when pressing cursor down:

Free Image Hosting at www.ImageShack.us

occurs when pressing left Ctrl:

Free Image Hosting at www.ImageShack.us

And before you ask: Yes, it is Vista. :P

Re: Vista?
posted by BlueMonkMN

Dang, it looks like I'm going to have to (get some more people to help me) do some heavy testing/debugging on Vista. It's strange that Vista would display simple errors like that XP doesn't when running on the same .NET framework... unless... when you say Vista64, does that mean we're talking about a 64-bit OS where converting an LParam/IntPtr to an Int32 causes that error like that?

What would be the proper way to write this code to work on both 32- and 64-bit OSes?

     switch (m.WParam.ToInt32())
      {
         case 0x10:
            if ((m.LParam.ToInt32() & 0xFF0000) == 0x2A0000)
               return (int)Key.LShift;
            else
               return (int)Key.RShift;
            break;
         case 0x11:
            if ((m.LParam.ToInt32() & 0x1000000) != 0)
               return (int)Key.RControl;
            else
               return (int)Key.LControl;
            break;
         case 0x0d:
            if ((m.LParam.ToInt32() & 0x1000000) != 0)
               return (int)Key.NumPadEnter;
            else
               return (int)Key.Enter;
      }
      return m.WParam.ToInt32();

Re: Vista?
posted by the Fiddler

Change:

switch (m.WParam.ToInt32())

to:
switch (m.WParam.ToInt64())

Fixed the same issue in OpenTK last night.

Edit:
The ImageFormatException occurs because FMOD is compiled for 32bits and the program is running in 64bit mode. Either distribute a 64bit FMOD binary (and choose the correct one at runtime or during install), or compile your .Net app for 32bits instead of AnyCPU (you'll lose some 64bit optimizations, but at least it will run).

Re: Vista?
posted by BlueMonkMN

This is the debug log from the system where AccessViolation exceptions are occurring:


DisplayDevice 0 (primary) supports 21 resolutions.
640x480x8@61Hz
640x480x16@61Hz
640x480x32@61Hz
720x480x8@61Hz
720x480x16@61Hz
720x480x32@61Hz
800x600x8@61Hz
800x600x16@61Hz
800x600x32@61Hz
848x480x8@61Hz
848x480x16@61Hz
848x480x32@61Hz
1024x768x8@61Hz
1024x768x16@61Hz
1024x768x32@61Hz
1280x768x8@61Hz
1280x768x16@61Hz
1280x768x32@61Hz
1280x800x8@61Hz
1280x800x16@61Hz
>> 1280x800x32@61Hz <<
Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Creating GraphicsContext.
GraphicsMode: Index: 2, Color: 32 (8888), Depth: 24, Stencil: False, Samples: 0, Accum: 0 (0000), Buffers: 2, Stereo: False
IWindowInfo: Windows.WindowInfo: Handle 1835978, Parent (null)
Loaded opengl32.dll: 1808859136
OpenGL will be bound to handle: 1835978
Setting pixel format...
2
Creating render context... done! (id: 65536)
Load extensions for OpenTK.Platform.Windows.Wgl... 47 extensions loaded in 25 ms.
Load extensions for OpenTK.Graphics.OpenGL.GL... 912 extensions loaded in 352 ms.
Load extensions for OpenTK.Graphics.OpenGL.Glu... 58 extensions loaded in 16 ms.
Extension "
2.0.6956 Release
gl_arb_depth_texture
gl_arb_draw_buffers
gl_arb_fragment_program
gl_arb_fragment_shader
gl_arb_multisample
gl_arb_multitexture
gl_arb_occlusion_query
gl_arb_point_parameters
gl_arb_point_sprite
gl_arb_shader_objects
gl_arb_shading_language_100
gl_arb_shadow
gl_arb_shadow_ambient
gl_arb_texture_border_clamp
gl_arb_texture_compression
gl_arb_texture_cube_map
gl_arb_texture_env_add
gl_arb_texture_env_combine
gl_arb_texture_env_crossbar
gl_arb_texture_env_dot3
gl_arb_texture_float
gl_arb_texture_mirrored_repeat
gl_arb_texture_rectangle
gl_arb_transpose_matrix
gl_arb_vertex_buffer_object
gl_arb_vertex_program
gl_arb_vertex_shader
gl_arb_window_pos
gl_ati_draw_buffers
gl_ati_envmap_bumpmap
gl_ati_fragment_shader
gl_ati_meminfo
gl_ati_separate_stencil
gl_ati_texture_env_combine3
gl_ati_texture_float
gl_ext_bgra
gl_ext_blend_color
gl_ext_blend_func_separate
gl_ext_blend_minmax
gl_ext_blend_subtract
gl_ext_compiled_vertex_array
gl_ext_copy_texture
gl_ext_draw_range_elements
gl_ext_fog_coord
gl_ext_framebuffer_object
gl_ext_gpu_program_parameters
gl_ext_multi_draw_arrays
gl_ext_packed_depth_stencil
gl_ext_packed_pixels
gl_ext_point_parameters
gl_ext_rescale_normal
gl_ext_secondary_color
gl_ext_separate_specular_color
gl_ext_shadow_funcs
gl_ext_stencil_wrap
gl_ext_subtexture
gl_ext_texgen_reflection
gl_ext_texture_compression_s3tc
gl_ext_texture_cube_map
gl_ext_texture_edge_clamp
gl_ext_texture_env_add
gl_ext_texture_env_combine
gl_ext_texture_env_dot3
gl_ext_texture_filter_anisotropic
gl_ext_texture_lod_bias
gl_ext_texture_mirror_clamp
gl_ext_texture_object
gl_ext_texture_rectangle
gl_ext_texture3d
gl_ext_vertex_array
gl_ktx_buffer_region
gl_nv_blend_square
gl_nv_texgen_reflection
gl_sgis_generate_mipmap
gl_sgis_texture_edge_clamp
gl_sgis_texture_lod
gl_version_1_1
gl_version_1_2
gl_version_1_3
gl_version_1_4
gl_version_1_5
gl_version_2_0
gl_win_swap_hint
wgl_ext_swap_control
Disposing context.

Apparently it's not merely a .NET Framework problem -- it looks like it's getting quite a ways before the error occurs. So what's different about the .NET samples and the Mono samples that could be causing an error only with OpenTK on .NET?

Re: Vista?
posted by BlueMonkMN

I've posted an updated version at http://sgdk2.enigmadream.com/support/TVSGDK2e.zip
I can't figure out why he's getting an AccessViolation exception, but I'd like to verify that the other problems are fixed if I can. And if anybody has any idea on why someone would be getting an AccessViolation exception on this and all the .NET samples delivered with OpenTK, I'm eager to hear it.

Re: Vista?
posted by the Fiddler

Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100
Selecting pixel format... Device context: 704713100

This doesn't look good, I'll have to investigate a bit.

The app you uploaded fails on an integrated intel 865 chip (no wonder!):

System.ApplicationException: Extension GL_ARB_texture_rectangle must be supported
   at Display.CheckRequirements()
   at Display.DrawFrame(TextureRef texture, Rectangle sourceRect, PointF[] corners, Int32 offsetX, Int32 offsetY)
   at LayerBase.Draw()
   at Menu_Map.Draw()
   at MapBase.DrawAllViews()
   at GameForm.Run()
   at Project.Main()

I'll test more when I get back home.

Re: Vista?
posted by Mincus

For what it's worth, I've tried all your uploads and not had any issue with them under Vista Ultimate 32-bit on a Geforce 8600M.

Re: Vista?
posted by BlueMonkMN

I've been told that the program actually does work on systems where GL_ARB_texture_rectangle is not supported, which is surprising to me because I am using ARB_texture_rectangle I think. But you could try taking that requirement out of the source code and see if it works. BTW, this is the error I can't get past on the system in question:

System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt.
at OpenTK.Graphics.OpenGL.GL.Imports.Begin(BeginMode mode)
at OpenTK.Graphics.OpenGL.GL.Begin(BeginMode mode)
at Display.DrawFrame(TextureRef texture, Rectangle sourceRect, PointF[] corners, Int32 offsetX, Int32 offsetY)
at LayerBase.Draw()
at Menu_Map.Draw()
at MapBase.DrawAllViews()
at GameForm.Run()
at Project.Main()

Re: Vista?
posted by the Fiddler

Update: it works fine on my dev PC (X1950Pro, 8.3 drivers), albeit it's running too fast to be playable.

So, the call to glBegin fails. I've seen that occur on two circumstances: invalid OpenGL context and outdated video drivers.

Could there be a problem in OpenTK that causes memory to be corrupted? Possibly, but a) it would have shown up before the call to Begin, and b) it should have shown up on other systems, too. It's interesting that all .Net examples fail on his system. Is he able to run any OpenGL applications at all? (for example the GLFW or NeHe examples)

Re: Vista?
posted by Inertia

The Exceptions mentioned in my last post still occur in TVSGDK2e.zip. Drawing still works fine.