Windows - Displaying Textures In OpenGL In XP Vs 7
Nov 12, 2010
I am running into the strangest problem that I just can't place my finger on. I've been developing an application in VB.net for the last couple months in Windows 7. The program involves some basic OpenGL drawing and animation with basic shapes (squares and circles) and basic textures mapped onto pointlists. The time has come to distribute the program to another machine. On some machines though, I encounter problems when I'm drawing textures. I know that openGL is still functional because drawing basic squares and circles still occur, the textured objects are the only things missing.
[Code]...
View 2 Replies
ADVERTISEMENT
Dec 25, 2011
i have installed visual studio 2010 32 bit on my new computer which have windows 7 64 bit. Everything seems ok. But now I try to learn how to draw some spheres with movement. I have tried to install openGL2 but it does not work or said that it does not fit with 64 bit, or it works only with VC.
Could any one, please, give me a short introduction to install and use open GL in vb.net 2010 installed on windows 7 64 bits ?
View 3 Replies
Jul 4, 2009
I'm trying to blend a few textures together to "bake" the final texture. Since I need the actual resulting bitmap, I don't think I can/want to do this using DirectX or OpenGL. I have:
- 4 Textures (RGB, 2048x2048): t0, t1, t2, t3
- 3 Alphamaps (ARGB, the RGB value is irrelevant, 64x64): a1, a2, a3
Here's what I currently do for each pixel (in simplified notation):
FinalColor = ((t0 * (1 - a1) + t1 * a1) * (1 - a2) + t2 * a2) * (1 - a3) + t3 * a3
This works fine, however, it takes forever, because I have to iterate over a 2048x2048 image pixel by pixel. Is there a more elegant way to solve this (i.e. using graphics.drawimage or something like it, but then, how?) How can I scale to Alphamap up with bilinear/bicubic interpolation (without having to do it pixel by pixel)? I currently use the original resolution, but that leads to rather visible transitions.
View 19 Replies
Mar 12, 2011
SI like doing random things like 3D objects inside a windows form. With that said, I'm creating an application that will, eventually, write the code for me, after I do it myself visually.If you run the app it will make some more sense I guess.Now, to rotate the cubes, I'm using
.Transform.World = Matrix.RotationYawPitchRoll(CSng(CubeRx(1) / 10), CSng(-CubeRy(1) / 10), CSng(CubeRz(1) / 10))
now I do not want the world to rotate, just my individual cubes.Here's an example of me referring to my cube in action
If howmanycubes >= 1 Then
' vb2 = New VertexBuffer(GetType(CustomVertex.PositionNormalColored), 36, d, Usage.Dynamic And Usage.WriteOnly, CustomVertex.PositionColored.Format, Pool.Default)
[code]....
how to apply textures to the cube.instructions:When running the program, type in values on right side and click create cube.before you click create cube again, those same text boxes will adjust your current cube.Then when you click create new, it places another cube ontop of your current cube, so you'll need to give it new values.Not much validation is going on so some bad values will cause crashes.
View 1 Replies
Mar 19, 2011
I am making a TabControl with different textures and a sliding look. But I am having trouble with following points :-
1. How to make buttons click able at Design time, so as to switch to different tabPages [which are panels in this case]
2. How to add a property ex. TabPages() as Panel collection Editor [like TabPages Collection editor in case of TabControl]
I tried,
Public ReadOnly Property TabPages() As List(Of Panel)
Get
TabPages = p
ref()
End Get
End Property
Where p is another List of panel and ref() checks new addition of control in p -> adds it to UserControl.
3. How to get the upper-right corner arrow to quickly add a tab in Design mode.
View 6 Replies
Aug 24, 2009
in vb.net is it possible to display a pdf file on a form?
View 3 Replies
Feb 24, 2009
I want to add opengl to my vb.
View 2 Replies
Feb 17, 2012
I was trying to learn how to do openGL within a VB .NET environment and it seems that the Tao framework or OpenTK is recommended with OpenTK having a higher recommendation so that is what I chose to try using. Since I am brand new to this, I am trying to just draw a simple box, triangle, or anything really so that I can understand it all before making more complex things. I have been unsuccessful at this so far so I will list in order what I have done so far and hopefully someone here can help me correct it or provide a new example just so I can draw a simple shape.
1) I installed OpenTK using opentk-2010-10-06.exe
2) In a new project I added the references to OpenTK.dll and OpenTK.Compatibility.dll
3) I added the control (opentk.glcontrol.dll)
4) I added the actual control to my form.Using some examples online I added the rest:
5) I wrote my references in:
Imports OpenTK
Imports OpenTK.GLControl
Imports OpenTK.Platform
[code]....
The above results in no display?
View 2 Replies
Feb 28, 2011
I try to create a MDI child form that should be resizable but it should not have a title bar visible. Is it possible? Or is there a better method to display child windows within a main form than displaying other forms. In this case the panel would be visually better than the form but the panel cannot be set to act as a child like a form.
View 3 Replies
May 5, 2011
I am making a change to some code written in vb.net, its a winforms app. The menuitem uses the System.Windows.Forms.MenuItem control. I need to display the values in that drop down menu into 2 columns. It displays a number of items and therefore is too long.I wish to display the items side but side in 2 columns. In C# you can use ToolStripMenuItem which allows you to display multiple columns. Even though ToolStripMenuItem is available in Vb.net its difficult for me in the current app to switch to that tool.
View 3 Replies
Nov 6, 2010
I was wondering if anyone could steer me to any good references to using OpenGL in vb.Net? I wanted to try a simple line drawing test to start off with, and came across many old discussions about using CsGl or the Tao Framework. But I could not get CsGL to import into Net2008 (the Add Reference window simply could not see the DLL that was clearly there when using Windows Explorer). And although I could get Tao to import OK, and found portions of one person's project, I figured that somehow the GL window he was referring to had to first be set up as a GL object (new class?).In addition, all the OpenGL books I have looked at only discuss OGL with respect to some version of C.From what I have gathered, you need a connector between vb.Net and the opengl32.dll libraries and that is what CsGL and Tao are about. But the edumucation resources seem very few.
View 13 Replies
Sep 13, 2011
I wanted to install visual Basic or C++ (but Basic really seems easyer to use) with DirectX or OpenGL but I can't get it to work!I've tried Visual Basic Express 2008 and 2010 and i'm getting the same type of errors...
-> Directx
When I try this program [URL]with VB I either get
with 2008 : just a red cross on a blank screen
with 2010 : an unlimited waiting time, and when i click i get an error message that tells me to continue waiting, im forced to CTRL -ALT - DEL to shut down VB.
-> OpenGL:So i've tried a lot of times! they tell me that it's already installed on windows so i don't need any installation but then VB gives me alot of errors, telling me that some part of code isnt recognized!!
i've tried tutorials with Csgl or Tao, but none seem to work...I already got some knowlege of OpenGL but not DirectX, so could anyone please tell me which one does work on my computer and is best for creating a graphics window inside an API that i create, for instance a mob maker?
View 15 Replies
Apr 6, 2011
how to write program based on OpenGL in VS? cause when i begine debugging ,it says library not found..
View 13 Replies
Jan 31, 2009
i want to do a graphics project in Vb.net but have to use OpenGl Libraries . How do i download compatible OpenGl package and how to use them in my .net code.
View 3 Replies
Oct 9, 2010
I render a complex shape in OpenGL which requires a lot of calculations, is there anyway to export that to a state like a model that can be opened again later given you wont edit it again?
I can't create them outside the program (with something like Blender) since the shape is computed when the program starts. The render then gets translated, rotated, drawn over, etc. Note, that I don't need to edit the shape though, but I do want it in a 3D state so saving an image isn't an option.
View 2 Replies
Aug 3, 2010
i heard OpenGL is 3D and it can be used in visual basic for models and games. Now i dont know if OpenGl is a contol or coding script. But i want to know how to make a simple model in OpenGl in visual basic.
View 9 Replies
May 30, 2009
I have a User control having two panels. one at the top border and second at the bottom border of the control.
The panels contain some buttons on the click of which i want to display some forms. But I want thoes forms to act like children of the user control i.e. like MDi Parent - Child (here parent being User control and child being the new forms which would be opening). Unfortunately i've not been able to find any way of do'in so.
View 2 Replies
Nov 19, 2011
Here is what I'm trying to do: Using WPF technology, I want to generate simple 3d solids inside a picturebox in vb windows form application, insert a camera and a light and control their position and direction through vb code, but it seems to be impossible, I know how to do that in a wpf project but I want to make use of WPF 3D capabilities in my windows form project.
View 5 Replies
Jan 4, 2011
I am trying to create a tool to make terrains for my game and would like to develop it in Visual Basic Express 2010. I want to use OpenGL but am having trouble.1. Will VB support OpenGL 3.x or higher?
View 6 Replies
Sep 3, 2010
I'm working on a game engine, and I want to be able to draw a billboarded (i.e. rectangular to the screen) quad with the center-bottom of the quad being determined by a single point.
View 1 Replies
Jun 22, 2010
i have to do a college project on this platform so i decided to learn open GL. while working with glui i am facing some problems. i downloaded glui-2.36. I thought of starting with the example1 (code added at bottom of the post) that was included in source folder of glui-2.36. i am using VB.net 2008 When i build the project it gives me 3 errors:
error C2661: 'GLUI_Checkbox::GLUI_Checkbox' : no overloaded function takes 3 arguments
error C2661: 'GLUI_Spinner::GLUI_Spinner' : no overloaded function takes 3 arguments
error C2227: left of '->set_int_limits' must point to class/struct/union/generic type
Here is cpp code:
#include <string.h>
#include <GL/glui.h>
/** These are the live variables passed into GLUI ***/
int wireframe = 0;
[code]....
View 1 Replies
Oct 19, 2010
I'm currently running into a problem regarding animation in OpenGL. I have between 200 and 10000 gears on the screen at a time all rotating. When the window is not in maximized view, my CPU runs at about 10-20 % consistently. No spikes, no stuttering in the animation, it runs perfectly smooth regardless of the number of gears on screen. When I maximize the window though, everything falls apart. My CPU maxes out, I begin getting weird spikes in CPU usage, the animation begins stuttering as a result, and it just looks really ugly, even when I have only 200 gears on screen.
My animation technique looks like this:
While Animating
Calculate current rotation angle based on a running timer
draw Image
call glFlush()
End While
I'm using the Tao framework in VB.net. I'm not performing any other calculations other than the ones to calculate the rotation angle mentioned above and perform a few glRotateD and glscaleD in the method to draw the image.
In addition, I guess I was under the impression that regardless of the window size in an orthographic 2-dimensional drawing that is scaling on resizing of the window, the drawing time would always take the same amount of time. Is this a correct assumption?
Note that I've seen the animation run perfectly smooth at full screen before. Every once in awhile, OpenGL will decide it's happy and run perfectly at full screen using between 10-20% of the CPU (same as when not maximized). I haven't pinpointed what causes this though, because it will run one time perfectly, then without changing anything, I will run it again and encounter the choppiness. I simply want to pinpoint what causes the animation to slow down and eliminate it.
I've run a dot trace on my program and it says that the swapBuffers method is using 55 % of my processing time even though I'm never explicitly calling the method. Is the method called by something else that I can eliminate, or is this simply OpenGL's "dead time" method to limit the animation to 60 fps?
View 1 Replies
Sep 28, 2011
make a openGL overlay so for an examplei play a game and when i click shift + tab then the game will fade and my application will be seen but without minimizing the game
View 3 Replies
Jul 26, 2011
Does anybody know how I can render openGL into a Visual Basic 2010 picture box?If you havent already done so please delete the abusive posts that responded to my original enquiries. I have decided to start a new thread on this subject rather than in an existing thread because it's more convinient for me.
View 9 Replies
Jan 28, 2011
how you display a live or current date and time on a Windows for application.
I am working with Visual Basic 2008(VS Studio 2008).
Example: January 28, 2011 8:00AM.
I have several books, strangely this subject is not properly covered.
This is my
Private Sub lblDisplayDateTime_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles lblDisplayDateTime.Click
Dim currentDateTime As Date = #8/2/2007 1:02:00 PM#
[Code]....
Finally, how do I make the time load when the form runs? I can't seem to find an event, that allows the time to display when I run the form. Currently, I have to click the area containing the label to get the time to display.
View 5 Replies
Sep 23, 2011
We have a GIS application that has some performance issues. It creates and sends an image to a web browser. We start with a Bing Maps imager, add complex polygons (complete with transparent fill), save the finished image as a PNG, and send it to the browser.
The idea has come up that we could possibly install a graphics card and use DirectX or OpenGL to improve performance. I believe this would be the case even though we ultimately generate an image instead of sending the data the the screen. I believe our processes could still make use of the API and the hardware acceleration it provides. Our process is not unlike what CGI film makers do to render individuals frames of a film, though we simply render a single image and send it, as opposed to the hundreds of thousands of images needed for a single CGI film.
So my question is: would a powerful graphics card and use of DirectDraw or OpenGL provide us a worthwhile performance boost? It can take us 20-30 seconds to render a more complex map. Which is a long time to wait on a web page...
View 10 Replies
Jan 15, 2012
I want to use "OpenGL" in my project. Is it possible to associate it with "Visual Basic" application developed in Visual Studio 2010? If yes then how can we do it.
View 1 Replies
Apr 2, 2010
I have a progress bar on a Windows Form which displays the number of records as they are retrieved from the database.The problem I'm having is that the entire Form.Load() method seems to run prior to the form being displayed, which means all my code updating the progress bar is gone to waste.
View 4 Replies
Oct 8, 2010
I have a VB 2008 program that was converted from VB6. I used an AxMSComCtl2.AxAnimation COM control to show a simple AVI file (no sound) in VB6. Is there a .NET Framework control that I can replace this old control with? I have found the MediaElement that looks like it can only be used in a WPF Application. There is also the Media Player Component which seems to also be a COM component. So, I don't see the advantage of switching to that.
View 2 Replies
Sep 16, 2011
Protected Sub Upload_Click(ByVal sender As Object, ByVal e As EventArgs) Handles Upload.Click
If Me.FileUpload1.HasFile Then
Dim intWidth, intHeight As Integer
Dim UlFileName, NewFileName As String
[code].....
After an image is uploaded it is not displaying on the web page like it should be:
'*** View Images ***'
Me.imgPicture.Visible = True
Me.imgPicture.ImageUrl = NewFileName
View 1 Replies