Search Results

Search found 427 results on 18 pages for 'sdl gfx'.

Page 8/18 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • Read/Write protected memory?

    - by PenguinBoy
    I'm trying to learn C++ currently, but I'm having issues with the code below. class Vector2 { public: double X; double Y; Vector2(double X, double Y) { this->X = X; this->Y = Y; }; SDL_Rect * getSdlOffset() { SDL_Rect * offset = new SDL_Rect(); offset->x = this->X; offset->y = this->Y; return offset; }; }; Visual studio throws throw the following error when calling getSdlOffset() An unhandled exception of type 'System.AccessViolationException' occurred in crossEchoTest.exe Additional information: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. I've got a C#/java background, and I'm lost... Any help would be much appreciated.

    Read the article

  • Problem linking SDL_Image against libpng

    - by Tim Jones
    I'm trying to compile SDL_Image 1.2.10 with MinGW + MSys (gcc 4.5.0) on Windows, I have compiled all the requires libs (zlib 1.2.5, libpng 1.4.2, libjpeg 8a, libtiff 3.9.2). SDL_Image compiles fine, but fails to link to libpng, throwing .libs/IMG_png.o:IMG_png.c:(.text+0x16): undefined reference errors on various png structs. If I run ./configure --prefix=/mingw --disable-png for SDL_Image, it compiles and links against the other libs just fine. I have tried older versions of libpng (1.2.43), but they also caused SDL_Image to throw the same errors.

    Read the article

  • OpenGL Performance Questions

    - by Daniel
    This subject, as with any optimisation problem, gets hit on a lot, but I just couldn't find what I (think) I want. A lot of tutorials, and even SO questions have similar tips; generally covering: Use GL face culling (the OpenGL function, not the scene logic) Only send 1 matrix to the GPU (projectionModelView combination), therefore decreasing the MVP calculations from per vertex to once per model (as it should be). Use interleaved Vertices Minimize as many GL calls as possible, batch where appropriate And possibly a few/many others. I am (for curiosity reasons) rendering 28 million triangles in my application using several vertex buffers. I have tried all the above techniques (to the best of my knowledge), and received almost no performance change. Whilst I am receiving around 40FPS in my implementation, which is by no means problematic, I am still curious as to where these optimisation 'tips' actually come into use? My CPU is idling around 20-50% during rendering, therefore I assume I am GPU bound for increasing performance. Note: I am looking into gDEBugger at the moment Cross posted at Game Development

    Read the article

  • How do I build SDL_TTF?

    - by William
    Okay, so I'm on Windows Vista, and I want to use SDL_TTF, but the idiots who made it decided you have to build everything from source, so I to build the .lib files and all that other stuff, but I'm on Windows, so how am I suppose to do this?

    Read the article

  • SDL_surface that contains several images

    - by l19
    Suppose I have a SDL_Surface that is just one image. What if I wanted to make that SDL_Surface have three copies of that image, one below the other? I came up with this function, but it doesn't do anything: void adjust(SDL_Surface* img) { int imageHeight = img->h; int desiredHeight = 3*imageHeight; int repetitions = desiredHeight / imageHeight ; int remainder = desiredHeight % imageHeight ; SDL_Rect rect; rect.x = 0; rect.y = 0; rect.w = img->w; rect.h = img->h; int i = 0; for (i ; i < repetitions ; i++) { rect.y = i* imageHeight; SDL_BlitSurface(img,NULL,img,&rect); } rect.y += remainder; SDL_BlitSurface(img,NULL,img,&rect); }

    Read the article

  • A GFX card with two DVI and one HDMI with audio?

    - by TomaszRykala
    I haven't upgraded my PC for a while nor kept up to date with pc hardware since 2007, but have recently come up with a requirement and I am wondering if I can solve it! Are there any graphics cards out there that have two DVIs and one HDMI output, with the HDMI supporting sound over it? Basically, I've got a two PC monitor setup, and both monitors are connected to the two DVI's of my GTX9800+. I want to upgrade my card to say, GTX 460, but can't find if there is such with two DVIs (for my monitors) and one HDMI with audio (for my TV). So I am wondering, if such solution possible at all? I noticed that there are some cards out there with two DVI's and one mini-HDMI, but they all say 'HDMI Output Yes x 1 (via DVI to HDMI adaptor x 1 )', which probably means that because of the DVI element, the audio won't work. Is this true? Such card is an exmaple: http://uk.asus.com/Graphics_Cards/NVIDIA_Series/ENGTX460_DirectCU2DI1GD5/#specifications Many thanks for your help!

    Read the article

  • Collecting IO outputs into list

    - by sisif
    how can i do multiple calls to SDL.pollEvent :: IO Event until the output is SDL.NoEvent and collect all the results into a list? in imperative terms something like this: events = [] event = SDL.pollEvent; while( event != SDL.NoEvent ) events.add( event ) event = SDL.pollEvent

    Read the article

  • Ubuntu make symbolic link between new folder in Home to existing folder

    - by Fath
    Hello, To the point. I have Ubuntu Maverick running on my Lenovo G450. Before, it was Windows 7. All my data are inside another partition, its NTFS. FSTAB line to mount that partition : /dev/sda5 /data ntfs auto,users,uid=1000,gid=1000,utf8,dmask=027,fmask=137 0 0 Inside /data there are folder Musics, Graphics, Tools, Cores, etc. If I'm about to create new folder, let see, GFX on /home/apronouva/GFX and make it link or pointing to /data/Graphics, how do I do that ? So when I open /home/apronouva/GFX the content will be the same as inside /data/Graphics .. and whatever changes I made inside GFX, it will also affect /data/Graphics I tried : $ ln -s /data/Graphics /home/apronouva/GFX it resulted : error, cannot make symbolic link between folder Thanks in advance, Fath

    Read the article

  • Type signature "Maybe a" doesn't like "Just [Event]"

    - by sisif
    I'm still learning Haskell and need help with the type inference please! Using packages SDL and Yampa I get the following type signature from FRP.Yampa.reactimate: (Bool -> IO (DTime, Maybe a)) and I want to use it for: myInput :: Bool -> IO (DTime, Maybe [SDL.Event]) myInput isBlocking = do event <- SDL.pollEvent return (1, Just [event]) ... reactimate myInit myInput myOutput mySF but it says Couldn't match expected type `()' against inferred type `[SDL.Event]' Expected type: IO (DTime, Maybe ()) Inferred type: IO (DTime, Maybe [SDL.Event]) In the second argument of `reactimate', namely `input' In the expression: reactimate initialize input output process I thought Maybe a allows me to use anything, even a SDL.Event list? Why is it expecting Maybe () when the type signature is actually Maybe a? Why does it want an empty tuple, or a function taking no arguments, or what is () supposed to be?

    Read the article

  • (newbie) type signature "Maybe a" doesn't like "Just [Event]"

    - by sisif
    i'm still learning Haskell and need help with the type inference please! using packages SDL and Yampa i get the following type signature from FRP.Yampa.reactimate: (Bool -> IO (DTime, Maybe a)) and i want to use it for: myInput :: Bool -> IO (DTime, Maybe [SDL.Event]) myInput isBlocking = do event <- SDL.pollEvent return (1, Just [event]) ... reactimate myInit myInput myOutput mySF but it says Couldn't match expected type `()' against inferred type `[SDL.Event]' Expected type: IO (DTime, Maybe ()) Inferred type: IO (DTime, Maybe [SDL.Event]) In the second argument of `reactimate', namely `input' In the expression: reactimate initialize input output process i thought "Maybe a" allows me to use anything, even a SDL.Event list? why is it expecting "Maybe ()" when the type signature is actually "Maybe a"? why does it want an empty tuple, or a function taking no arguments, or what is () supposed to be?

    Read the article

  • how to find which libraries to link to? or, how can I create *-config (such as sdl-config, llvm-con

    - by numeric
    Hey, I want to write a program that outputs a list of libraries that I should link to given source code (or object) files (for C or C++ programs). In *nix, there are useful tools such as sdl-config and llvm-config. But, I want my program to work on Windows, too. Usage: get-library-names -l /path/to/lib a.cpp b.cpp c.cpp d.obj Then, get-library-names would get a list of function names that are invoked from a.cpp, b.cpp, c.cpp, and d.obj. And, it'll search all library files in /path/to/lib directory and list libraries that are needed to link properly. Is there such tool already written? Is it not trivial to write a such tool? How do you find what libraries you should link to? Thanks.

    Read the article

  • Installing pygame with pip

    - by David Y. Stephenson
    I'm trying to install pygame using pip in a virtualenv. I'm following this tutorial on using Kivy. However, running pip install pygame returns Downloading/unpacking pygame Downloading pygame-1.9.1release.tar.gz (2.1MB): 2.1MB downloaded Running setup.py egg_info for package pygame WARNING, No "Setup" File Exists, Running "config.py" Using UNIX configuration... /bin/sh: 1: sdl-config: not found /bin/sh: 1: smpeg-config: not found Hunting dependencies... WARNING: "sdl-config" failed! WARNING: "smpeg-config" failed! Unable to run "sdl-config". Please make sure a development version of SDL is installed. No files/directories in /tmp/pip-build-root/pygame/pip-egg-info (from PKG-INFO) Storing complete log in /home/david/.pip/pip.log The content of /home/david/.pip/pip.log can be found at http://paste.ubuntu.com/5800296/ What am I doing wrong? I'm trying to keep to the standard methodology for installing pygame as much as possible in order to avoid deviating from the tutorial. Suggestions?

    Read the article

  • How do you configure an SDL Tridion CME extension for a subset of views?

    - by Chris Summers
    I have created a new editor for SDL Tridion which adds some new functionality to the ribbon bar. This is enabled by adding the following snippet to the editor.config <!-- ItemCommenting PowerTool --> <ext:extension assignid="ItemCommenting" name="Save and&lt;br/&gt;Comment" pageid="HomePage" groupid="ManageGroup" insertbefore="SaveCloseBtn"> <ext:command>PT_ItemCommenting</ext:command> <ext:title>Save and Comment</ext:title> <ext:issmallbutton>false</ext:issmallbutton> <ext:dependencies> <cfg:dependency>PowerTools.Commands</cfg:dependency> </ext:dependencies> <ext:apply> <ext:view name="*" /> </ext:apply> </ext:extension> This is applied to all views by using a wildcard value in the node. This has results in my new button being added to the ribbon of every view, including the main dashboard. Is there a way to add this to all views except for the dashboard? Or do I have to create something like this? <ext:apply> <ext:view name="PageView" /> <ext:view name="ComponentView" /> <ext:view name="SchemaView" /> </ext:apply> If this is the only way to achieve the result I need, is there a list of all the view names somewhere?

    Read the article

  • How do I draw anti-aliased holes in a bitmap

    - by gyozo kudor
    I have an artillery game (hobby-learning project) and when the projectile hits it leaves a hole in the ground. I want this hole to have antialiased edges. I'm using System.Drawing for this. I've tried with clipping paths, and drawing with a transparent color using gfx.CompositingMode = CompositingMode.SourceCopy, but it gives me the same result. If I draw a circle with a solid color it works fine, but I need a hole, a circle with 0 alpha values. I have enabled these but they work only with solid colors: gfx.CompositingQuality = CompositingQuality.HighQuality; gfx.InterpolationMode = InterpolationMode.HighQualityBicubic; gfx.SmoothingMode = SmoothingMode.AntiAlias; In the two pictures consider black as being transparent. This is what I have (zoomed in): And what I need is something like this (made with photoshop): This will be just a visual effect, in code for collision detection I still treat everything with alpha 128 as solid. Edit: I'm usink OpenTK for this game. But for this question I think it doesn't really matter probably it is gdi+ related.

    Read the article

  • Is it possible to run C++ binded with SDL+OpenGL code on a web browser?

    - by unknownthreat
    My client wants her website to have an application that renders 3D (light 3D stuff, we are drawing only flat squares in 3D world) but web programming is not my thing. So I am looking for something that can run a C++ program from a web browser. But I think, if this is the case, then the client side must download the program first, and that's not what I want. The client should only be able to use this application only on the website. I came across Google Native Client, which claims that it can run x86 native code in web applications. I haven't decide whether it is worth it or not and I don't know whether this is what I want or not, so I decided to ask experienced people about this. If I want to have something like this, is what I said above possible? Or I completely need other languages like Flex because it does not worth the trouble? Or is Google Native Client suitable for doing something like this?

    Read the article

  • Is there a (free) reliable place to get statistics from sites, more reliable than Alexa, Quantcast, Compete?

    - by S.gfx
    I mean, seems there's no way. I am just asking in case someone knows of a recent new site being more accurate. I am aware of Alexa's, Compete and Quantcast inaccuracies and/or limited system/range of sites to get their stats. I also know about websitegrader perhaps being a little more accurate (although not sure if that's the data I am after). And read Seomoz tools are reliable. I am yet though looking for a free solution, a 'reliable' Alexa. And not a place depending on a toolbar installation, an easy to trick place, or one with stats way too off, or of a very limited range of sites. I am almost sure there's nothing new, but I wanted to be sure.

    Read the article

  • One True Event Loop

    - by CyberShadow
    Simple programs that collect data from only one system need only one event loop. For example, Windows applications have the message loop, POSIX network programs usually have a select/epoll/etc. loop at their core, pure SDL games use SDL's event loop. But what if you need to collect events from several subsystems? Such as an SDL game which doesn't use SDL_net for networking. I can think of several solutions: Polling (ugh) Put each event loop in its own thread, and: Send messages to the main thread, which collects and processes the events, or Place the event-processing code of each thread in a critical section, so that the threads can wait for events asynchronously but process them synchronously Choose one subsystem for the main event loop, and pass events from other subsystems via that subsystem as custom messages (for example, the Windows message loop and custom messages, or a socket select() loop and passing events via a loopback connection). Option 2.1 is more interesting on platforms where message-passing is a well-developed threading primitive (e.g. in the D programming language), but 2.2 looks like the best option to me.

    Read the article

  • bash dirtrim produces strange results with ~/foo/bar/var directory

    - by queueoverflow
    In some of my projects, I keep a var or a lib folder for runtime output and external libraries. To keep my prompt rather short, I have the export PROMPT_DIRTRIM=3 option in my .bashrc. This works very well for most paths, but as soon as I have a /var in there, it goes nuts like this (for ~/Projects/someproject/var/gfx): ~/.../gfxr/gfxr/gfxr/gfxr/gfxr/gfx Interestingly, it works with /opt/lampp/lib Is there some way to get around this? Update my .bashrc my .bash_functions

    Read the article

  • How do i make an installer instead of a crash (.NET)

    - by acidzombie24
    My situation is Using .NET 3.5 Using SDL.NET Need to make a friendly installer or warning system. Chances are the user will be on XP (.NET 1.1). If possible can i do something to let the user know he needs to update to 3.5? Maybe have a yes/no dialog which downloads and install the .NET runtimes for him? Now how do i detect if the user has sdl.net installed (chances are its in program files/sdldotnet) and let them know they need sdl.net runtime and have a yes/no dialog that brings them to http://sourceforge.net/projects/cs-sdl/files/ The problem i have mostly is how to make the app not outright crash and how to download 3.5 .NET runtime if it is possible.

    Read the article

  • Formatting jquery timeline?

    - by Beginner
    I am using a timeline plugin from here This is my current code: <ul id="dates"> <li><a href="#1940s">1940s</a></li> <li><a href="#1950s" class="selected">1950s</a></li> <li><a href="#1960s">1960s</a></li> <li><a href="#1970s">1970s</a></li> <li><a href="#1980s">1980s</a></li> <li><a href="#1990s">1990s</a></li> <li><a href="#2000s">2000s</a></li> </ul> <ul id="issues"> <li id="1940s"><img src="/gfx/timeline/1950.jpg" /> <h1>1940's</h1> <p>Ronald.</p> </li> <li id="1950s"><img src="/gfx/timeline/1960.jpg" /> <h1>1950's</h1> <p>Eddy.</p> </li> <li id="1960s"><img src="/gfx/timeline/1970.jpg" /> <h1>1960's</h1> <p>1960s</p> </li> <li id="1970s"><img src="/gfx/timeline/1980.jpg" /> <h1>1970's</h1> <p>1970s</p> </li> <li id="1980s"><img src="/gfx/timeline/1990.jpg" /> <h1>1980's</h1> <p>1980s</p> </li> <li id="1990s"><img src="/gfx/timeline/1990.jpg" /> <h1>1990's</h1> <p>1990s</p> </li> <li id="2000s"><img src="/gfx/timeline/2000.jpg" /> <h1>2000s</h1> <p>2000s</p> </li> </ul> But I don't understand how I can make it look like this... Any assistance?thanks Current CSS: #timeline { width: 660px; height: 350px; overflow: hidden; margin: 100px auto; position: relative; background: url('Img/vline.png') left 65px repeat-x; } #dates { width: 660px; height: 60px; overflow: hidden; } #dates li { list-style: none; float: left; width: 100px; height: 50px; font-size: 24px; text-align: center; background: url('Img/hline.png') center bottom no-repeat; } #dates a { line-height: 38px; text-decoration:none; color:#999; font-size:15px; font-weight:bold; } #dates .selected { font-size: 38px; color:#000; } #issues { width: 660px; height: 350px; overflow: hidden; } #issues li { width: 660px; height: 350px; list-style: none; float: left; } #issues li img { float: right; margin: 100px 30px 10px 50px; } #issues li h1 { color: #999; font-size: 20px; margin: 20px 0; } #issues li p { font-size: 14px; margin-right: 70px; font-weight: normal; line-height: 22px; }

    Read the article

  • Making A C++ Game

    - by user1758938
    I'm gonna make a game and I think C++ would be perfect for it. I think I'm gonna use SDL and OpenGL but I need help with making the code manageable. These were my ideas: 1. Making A DLL File With Commands Such A CreateScreen(640, 480); Which Binds SDL And OpenGL Commands For A Manageable Setup 2. Making It Harder To Mod (Like UnCompiling My Code) Like Encrypting Save Files That Only My Program Can Read Any Suggestions?

    Read the article

  • White Paper: How the Security Development Lifecycle Helped Improve the Security of the 2007 Microsof

    The 2007 Office system was the first Microsoft Office release to include the standardized Security Development Lifecycle (SDL) process throughout the product development life cycle. Read this paper to understand how the SDL contributed to improving the security of the 2007 Microsoft Office System....Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • Can't Run Assault Cube

    - by Debashis Pradhan
    I installed assault cube from the Software centre and it just opens for half a second and closes. When i run in it from the terminal, this is what i get - d@d-platform:~$ assaultcube Using home directory: /home/d/.assaultcube_v1.104 current locale: en_IN init: sdl init: net init: world init: video: sdl init: video: mode X Error of failed request: BadValue (integer parameter out of range for operation) Major opcode of failed request: 129 (XFree86-VidModeExtension) Minor opcode of failed request: 10 (XF86VidModeSwitchToMode) Value in failed request: 0xb3 Serial number of failed request: 131 Current serial number in output stream: 133

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >