Daily Archives

Articles indexed Sunday June 30 2013

Page 5/13 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • What is the most cross-browser/system compatible option for 3d graphics on a web page?

    - by LachlanB
    I would like to develop a bit of functionality for a web site that involves a bit of 3D - the user can move around objects, rotate them and texture them. So far I've looked into: WebGL (in particular three.js) and it looks great, but it's not supported in IE nor IOS. IOS supports the <canvas> tag, but only 2d. It looks like three.js has an unsupported hack to make a 3d thing use the 2d canvas instead without textures, but this looks like a hack. I also considered resorting to Flash which works on most browsers, but that won't work on IOS. What's my best option for doing 3d web graphics on the vast array of browsers and interfaces? At the moment I'm thinking WebGL for web (and ask people to use chrome or firefox, and take the hit on IE) and then maybe write a native app for IOS, but I am not sure if there are better alternatives available that I don't know of.

    Read the article

  • Remote server's x menus without vino, vnc etc

    - by Fredde
    A question where both google searches, as well as askubuntu and ubuntu forums searches fails though rephrasing the question a number of times. Have a Lubuntu server with some storage and functions and a lubuntu laptop. Previous when running winXP, I had Xming, could start a x-session on the server, got the lxpanel on the laptop, switching, running x-programs without a hitch though the lxpanel menu. A very neat and convenient solution. However the winXP crashed, me moving to lubuntu also for the laptop. still things work, I ssh into the server and can start x-programs without a hitch. But, as with all graphical desktops, I at times need access to the lx menus on the server to find programs and here the problems arise, most finding I got talk about installing VNC, vino etc overkills, avoiding existing X-integration between the servers. I'll like to do as I did with Xming, see the menu system on the server, in my "client's" xwin? Just to see the servers installed software without colliding with the laptop X-server, just using it as normal X-apps.

    Read the article

  • Uninstall backtrack 5 dual booted with Ubuntu

    - by omerjerk
    Some days ago I installed BackTrack over my Ubuntu installation. I was having some problems in the bootloader of BackTrack. So I set default bootloader to that of Ubuntu. I didn't remember the command that I typed. so now the default bootloader is of Ubuntu and I want to completely remove BackTrack. how to do that ? If I just delete the installation files of backtrack from ubuntu then it'll still be there in the bootloader.

    Read the article

  • Why is my fan constatnly blowing in Ubuntu?

    - by Derfder
    I have installed Ubuntu 13.04 (64-bits) alongside Windows 7 on different partition on my second desktop. It's working nice. I have updated everything. However, I have problems with my fan. It's blowing non-stop and very fast(loud). I haven't these problems in Windows 7 where it works nicely. How to update drivers for my fan or something else? My desktop is: HP Pro 3410 Microtower PC. Graphic card: AMD Radeon HD 6570 Board: 2A9C 1.1 Bus Clock: 133 megahertz BIOS: American Megatrends Inc. 6.14 11/05/2010 Processor: 3,20 gigahertz Intel Core i3 550 DRIVERS I HAVE TRIED FOR MY GRAPHIC CARD: I have tried these drivers so far: xserver-xorg-video-ati, version: 1:7.1.0-0ubuntu2 fglrx Version: 2:9.010-0ubuntu3 fglrx-updates Version 2:9.012-0ubuntu1 But the fan is still blowing like a maniac. I have tried to install Linux Mint 15 previously and I have had the same problems with the fan. Any idea how to fix it?

    Read the article

  • configuration issue with respect to .htaccess file on ubuntu

    - by Registered User
    I am building an application tshirtshop I have following configuration in /etc/apache2/sites-enabled/tshirtshop <VirtualHost *:80> ServerAdmin webmaster@localhost DocumentRoot /var/www/tshirtshop <Directory /var/www/tshirtshop> Options Indexes FollowSymLinks AllowOverride All Order allow,deny allow from all </Directory> ErrorLog ${APACHE_LOG_DIR}/error.log # Possible values include: debug, info, notice, warn, error, crit, # alert, emerg. LogLevel warn CustomLog ${APACHE_LOG_DIR}/access.log combined </VirtualHost> and following in .htaccess file in location /var/www/tshirtshop/.htaccess <IfModule mod_rewrite.c> # Enable mod_rewrite RewriteEngine On # Specify the folder in which the application resides. # Use / if the application is in the root. RewriteBase /tshirtshop #RewriteBase / # Rewrite to correct domain to avoid canonicalization problems # RewriteCond %{HTTP_HOST} !^www\.example\.com # RewriteRule ^(.*)$ http://www.example.com/$1 [R=301,L] # Rewrite URLs ending in /index.php or /index.html to / RewriteCond %{THE_REQUEST} ^GET\ .*/index\.(php|html?)\ HTTP RewriteRule ^(.*)index\.(php|html?)$ $1 [R=301,L] # Rewrite category pages RewriteRule ^.*-d([0-9]+)/.*-c([0-9]+)/page-([0-9]+)/?$ index.php?DepartmentId=$1&CategoryId=$2&Page=$3 [L] RewriteRule ^.*-d([0-9]+)/.*-c([0-9]+)/?$ index.php?DepartmentId=$1&CategoryId=$2 [L] # Rewrite department pages RewriteRule ^.*-d([0-9]+)/page-([0-9]+)/?$ index.php?DepartmentId=$1&Page=$2 [L] RewriteRule ^.*-d([0-9]+)/?$ index.php?DepartmentId=$1 [L] # Rewrite subpages of the home page RewriteRule ^page-([0-9]+)/?$ index.php?Page=$1 [L] # Rewrite product details pages RewriteRule ^.*-p([0-9]+)/?$ index.php?ProductId=$1 [L] </IfModule> the site is working on localhost and is working as if there is no .htaccess rule specified i.e. if I were to view a page as http://localhost/tshirtshop/nature-d2 then I get a 404 Error but if I view the same page as http://localhost/tshirtshop/index.php?DepartmentId=2 then I can view it. sudo apache2ctl -M Loaded Modules: core_module (static) log_config_module (static) logio_module (static) mpm_prefork_module (static) http_module (static) so_module (static) alias_module (shared) auth_basic_module (shared) authn_file_module (shared) authz_default_module (shared) authz_groupfile_module (shared) authz_host_module (shared) authz_user_module (shared) autoindex_module (shared) cgi_module (shared) deflate_module (shared) dir_module (shared) env_module (shared) mime_module (shared) negotiation_module (shared) php5_module (shared) reqtimeout_module (shared) rewrite_module (shared) setenvif_module (shared) status_module (shared) Syntax OK What is the mistake if any one can point out in above configuration, or else I need to check any thing else?

    Read the article

  • apt-get does not install dependencies

    - by Saran
    When i try to install the gnutls libraries (libgnutls26), and the generic linux kernel headers (linux-headers-generic), I get the following error: The following packages have unmet dependencies: libgnutls26: Depends: libc6 (>= 2.14) but 2.15-0ubuntu10.4 is installed Depends: zlib1g (>= 1:1.1.4) but 1:1.2.3.4.dfsg-3ubuntu4 is installed libgnutls26:i386: Depends: zlib1g (>= 1:1.1.4) but 1:1.2.3.4.dfsg-3ubuntu4 is installed linux-headers-generic: Depends: linux-headers-3.2.0-41-generic but it is not installed How can I fix this error?

    Read the article

  • how to change gtk3 color scheme on ubuntu 13.04

    - by Michael87
    I am making the transition from windows 7 to ubuntu 13.04. I have ran ubuntu twice on my laptop and switched back to windows 7 namely becuase the orange and gray colors of ubuntu is just ugly. I know how to change ambiance to radiance but the gtk colors themselves SHOULD be customizable. I managed to do it once with 12.04 using kde's color manager but the thing wigged out on me. So please. is there a way to change 13.04's color scheme without downloading some theme that may or may not work? thank you.

    Read the article

  • Launching php script through comman line - keeping terminal window open after execution

    - by somethis
    Oh, my girlfriend really likes it when I launch php scripts! There's something special about them, she says ... Thus, I coded this script to run throught the CLI (Command Line Interface) - so it's running locally, not on a web server. It launches just fine through right click open run in terminal but closes right after execution. **Is there a way to keep the terminal window open? Of course I can launch it through a terminal window - which would stay open - but I'm looking for a one click action. With bash scripts I use $SHELL but that didn't work (see code below). So far, the only thing I came up with is sleep(10); which gives me 10 seconds for my girl to check the output. I'd rather close the terminal window manually, though. #!/usr/bin/php -q <?php echo "Hello World \n"; # wait before closing terminal window sleep(10); # the following line doesn't work $SHELL; ?> (PHP 5.4.6-1ubuntu1.2 (cli) (built: Mar 11 2013 14:57:54) Copyright (c) 1997-2012 The PHP Group Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies )

    Read the article

  • Grub errors during UEFI dual boot for Windows 8 (can't find command 'drivemap')

    - by luca-mastro
    I have got a newly bought ASUS N56V with Windows 8 preinstalled. I needed to install Ubuntu so i partitioned the disk and after having disabled the Secure Boot option from Windows 8 i successfully installed Ubuntu 12.10 from a Live USB. The problem is that if i try to access both to Windows 8 (loader) and Windows Recovery System (loader) from the GRUB menu, these two errors show: can't find command 'drivemap' and invalid EFI file path and it goes back to the grub menu. In conclusion I do not have access to my Windows 8 partition but can only use Ubuntu. How can I solve the problem? I am pretty new to the matter. Thank you!

    Read the article

  • Gnome 3 - Multiple Video Cards - Xinerama -- Forced Fallback Mode

    - by Alvin
    Just installed a 2nd nvidia video card -- previously had gnome 3 working perfectly with 2 monitors on a a single video card using twinview tried a number of things thus far twinview on 1 card + xinerama no xinerama no twinview various manual xorg.conf hacks based on random forums (couple references below) xinerama no twinview with and without Extensions Composite The last one is what I'm using now -- it results in a forced fallback mode with Composite Disable set at the end of xorg.conf via nvidia-settings Section "Extensions" Option "Composite" "Disable" EndSection when I disabled that last snippet it boots to gnome 3 full with the left monitor on a black screen and the middle monitor as primary but non-responsive switching to console mode Ctrl+Alt+F1 and then switching back I get 3 black screens with a mouse that can move around but nothing to interact with issue seems related to OpenGL and the multiple video cards -- I can boot into Unity without issue though my Glx-Dock shows up with the black background as barely shows in the screenshot below indicating the OpenGL is not initiated has anyone had any luck with getting Xinerama to work with Multiple NVidia Video Cards with OpenGL support? Found this in the logs while looking a bit further [ 23.208] (II) NVIDIA(1): Setting mode "nvidia-auto-select+0+0" [ 23.254] (WW) NVIDIA(1): The GPU driving screen 1 is incompatible with the rest of the [ 23.254] (WW) NVIDIA(1): GPUs composing the desktop. OpenGL rendering will be [ 23.254] (WW) NVIDIA(1): disabled on screen 1. [ 23.277] (==) NVIDIA(1): Disabling shared memory pixmaps [ 23.277] (==) NVIDIA(1): Backing store disabled [ 23.277] (==) NVIDIA(1): Silken mouse enabled [ 23.277] (==) NVIDIA(1): DPMS enabled According to this page at the NVidia User Docs http://us.download.nvidia.com/XFree86/Linux-x86/173.14.09/README/chapter-14.html I may be out of luck =( Starting this question with the hopes that others may be able to help debug and perhaps gain answers over time as I really want to get the full gnome 3 back.

    Read the article

  • How to uninstall Latex?

    - by ATMathew
    Ubuntu and Latex newbie here. Very basic question I have. I recently installed Latex using the following code: sudo apt-get install texlive However, I want to uninstall this and just get the latex base for now. I tried the following but it doesn't work: sudo apt-get remove texlive dpkg --get-selections | grep tex shows that a number of latex related files are installed. How do I remove texlive?

    Read the article

  • Shifting from no-www to www and browsers' password storage

    - by user1444680
    I created a website having user-registration system and invited my friend to join it. I gave him the link of no-www version: http://mydomain.com but now after reading this and this, I want to shift to www.mydomain.com. But there's a problem. I saw that my browser is storing separate passwords for mydomain.com and www.mydomain.com. So in my friend's browser his password must have been stored for no-www. That means after I shift to www and next time he opens the login page, his browser wouldn't auto-fill the username and password fields and there will also be an extra entry (of no-www) in his browser's database of stored passwords. Can this be avoided? Can I do something that will convey to browsers that www.mydomain.com and mydomain.com are the same website? I already have a CNAME record for www pointing to mydomain.com but it seems that search engines consider CNAME as alias but browsers consider them as different websites, I don't know why.

    Read the article

  • Google Analytics - include filter not working

    - by gerl
    I just added an include filter this morning in my domain (test.org). I have: Custom Filter Include Request URI ^/test-a/46212$|^/test-a/46212|^/test-a/46315 Now after I go to Content Site Content All Pages, I see stats for other pages that I didn't include in my filter. For example I see /somethingelse. I only want to see stats for /test-a/46212 and whatever else in my filter. Please let me know what I'm doing wrong.

    Read the article

  • Texture not drawing on cubes

    - by Christian Frantz
    I can draw the cubes fine but they are just solid black besides the occasional lighting that goes on. The basic effect is being set for each cube also. public void Draw(BasicEffect effect) { foreach (EffectPass pass in effect.CurrentTechnique.Passes) { pass.Apply(); device.SetVertexBuffer(vertexBuffer); device.Indices = indexBuffer; device.DrawIndexedPrimitives(PrimitiveType.TriangleList, 0, 0, 8, 0, 12); } } The cubes draw method. TextureEnabled is set to true in my main draw method. My texture is also loading fine. public Cube(GraphicsDevice graphicsDevice, Vector3 Position, Texture2D Texture) { device = graphicsDevice; texture = Texture; cubePosition = Position; effect = new BasicEffect(device); } The constructor seems fine too. Could this be caused by the Vector2's of my VertexPositionNormalTexture? Even if they were out of order something should still be drawn other than a black cube

    Read the article

  • Creating a 2D perspective in 3D game

    - by Accatyyc
    I'm new to XNA and 3D game development in general. I'm creating a puzzle game kind of similar to tetris, built with blocks. I decided to build the game in 3D since I can do some cool animations and transitions when using 3D blocks with physics etc. However, I really do want the game to look "2D". My blocks are made up of 3D models, but I don't want that to be visible when they're not animating. I have followed some XNA tutorials and set up my scene like this: this.view = Matrix.CreateLookAt(cameraPosition, Vector3.Zero, Vector3.Up); this.aspectRatio = graphics.GraphicsDevice.Viewport.AspectRatio; this.projection = Matrix.CreatePerspectiveFieldOfView( MathHelper.ToRadians(45.0f), aspectRatio, 1.0f, 10000.0f); ... and it gives me a very 3D-ish look. For example, the blocks in the center of the screen looks exactly how I want them, but closer to the edges of the screen I can see the rotation and sides of them. My guess is that I'm not after a perspective field of view, but any help on which field of view/settings to use to get a "flat" look when the blocks aren't rotated would be great!

    Read the article

  • Loading images in XNA 4.0; "Cannot Open File" Problems

    - by user32623
    Okay, I'm writing a game in C#/XNA 4.0 and am utterly stumped at my current juncture: Sprite animation. I understand how it works and have all the code in place, but my ContentLoader won't open my file... Basically, my directory looks like this: //WindowsGame1 - "Game1.cs" - //Classes - "NPC.cs" - Content Reference - //Images - "Monster.png" Inside my NPC class, I have all the essential drawing functions, i.e. LoadContent, Draw, Update. And I can get the game to find the correct file and attempt to open it, but when it tries, it throws an exception and tells me it can't open the file. This is how my code in my NPC class looks: Texture2D NPCImage; Vector2 NPCPosition; Animation NPCAnimation = new Animation(); public void Initialize() { NPCAnimation.Initialize(NPCPosition, new Vector2(4, 4)); } public void LoadContent(ContentManager Content) { NPCImage = Content.Load<Texture2D>("_InsertImageFilePathHere_"); NPCAnimation.AnimationImage = NPCImage; } The rest of the code is irrelevant at this point because I can't even get the image to load. I think it might have to do with a directory problem, but I also know little to nothing about spriting or working with images or animations in my code. Any help is appreciated. Not sure if I provided enough information here, so let me know if more is needed! Also, what would be the correct way to direct that Content.Load to Monster.png given the current directory situation? Right now I just have it using the full path from the C:// drive. Thanks in advance!

    Read the article

  • Win32 strange exception

    - by Christian Frantz
    When creating 2500 objects, I get a strange windows exception. It says the operation copmleted successfully at my constructor line. The program doesn't run or anything. I'm assuming it has something to do with memory. Each object has 32 indices and 8 vertices, so that 640,000 bytes or whatever vertices and indices are stored as. Any idea on how to fix this? Creating 25 objects works fine\ System.ComponentModel.Win32Exception was unhandled Message=The operation completed successfully Source=System.Drawing ErrorCode=-2147467259 NativeErrorCode=0 StackTrace: at System.Drawing.Icon.Initialize(Int32 width, Int32 height) at System.Drawing.Icon..ctor(Type type, String resource) at Microsoft.Xna.Framework.WindowsGameWindow.GetDefaultIcon() at Microsoft.Xna.Framework.WindowsGameWindow..ctor() at Microsoft.Xna.Framework.WindowsGameHost..ctor(Game game) at Microsoft.Xna.Framework.Game.EnsureHost() at Microsoft.Xna.Framework.Game..ctor() at Cube_Chaser.Cube..ctor(GraphicsDevice graphicsDevice, Vector3 Position, Color Color) in C:\Users\daj\Desktop\Cube Chaser after removal of cubedrawable - Copy\Cube Chaser\Cube Chaser\Cube.cs:line 31 at Cube_Chaser.Cube.CreateMap() in C:\Users\user\Desktop\Cube Chaser after removal of cubedrawable - Copy\Cube Chaser\Cube Chaser\Cube.cs:line 247 at Cube_Chaser.Game1.LoadContent() in C:\Users\daj\Desktop\Cube Chaser after removal of cubedrawable - Copy\Cube Chaser\Cube Chaser\Game1.cs:line 86 at Microsoft.Xna.Framework.Game.Initialize() at Cube_Chaser.Game1.Initialize() in C:\Users\daj\Desktop\Cube Chaser after removal of cubedrawable - Copy\Cube Chaser\Cube Chaser\Game1.cs:line 77 at Microsoft.Xna.Framework.Game.RunGame(Boolean useBlockingRun) at Microsoft.Xna.Framework.Game.Run() at Cube_Chaser.Program.Main(String[] args) in C:\Users\user\Desktop\Cube Chaser after removal of cubedrawable - Copy\Cube Chaser\Cube Chaser\Program.cs:line 15 InnerException:

    Read the article

  • Setting Higher Z-Index for Sprite

    - by Siddharth
    For my game, I have to set highest z index for my sprite. At present, I wrote following code but didn't work for me. Sprite houseSprite = new Sprite(pX, pY, textureManager.houseBgRegion.deepCopy(), mVertexBufferObjectManager); attachChild(houseSprite); houseSprite.setZIndex(500); sortChildren(); My requirement did not satisfied with setting sprite in the HUD. So any how I have to apply highest z index. Also in my game sprites are dynamically generated as per game play. So members please share your thoughts.

    Read the article

  • XNA Skinned Model - Keyframe.Bone out of range exception

    - by idlackage
    I'm getting an IndexOutOfRangeException on this line of AnimationPlayer.cs: boneTransforms[keyframe.Bone] = keyframe.Transform; I don't get what it's really referring to. The error happens when keyframe.Bone is 14, but I have no idea what that's supposed to mean. The 14th bone of my model? What would that even be? I read this thread, but nothing there seemed to work. I don't have many bones, stray edges/verts, unassigned verts, unparented/non-root bones, or bones with dots in the name. What else can I be missing? Thank you for any help!

    Read the article

  • how to make a simple collision detection of bitmaps in Android

    - by Dritan Berna
    I already have a code with collision but it has check for winners and ontouch method that I don't really need because my bitmaps are moving itself and I just want them to collide if they overlap. private boolean checkCollision(Grafika first, Grafika second) { boolean retValue = false; int width = first.getBitmap().getWidth(); int height = first.getBitmap().getHeight(); int x1start = first.getCoordinates().getX(); int x1end = x1start + width; int y1start = first.getCoordinates().getY(); int y1end = y1start + height; int x2start = second.getCoordinates().getX(); int x2end = x2start + width; int y2start = second.getCoordinates().getY(); int y2end = y2start + height; if ((x2start >= x1start && x2start <= x1end) || (x2end >= x1start && x2end <= x1end)) { if ((y2start >= y1start && y2start <= y1end) || (y2end >= y1start && y2end <= y1end)) { retValue = true; } } return retValue; }

    Read the article

  • Excel - check if row contains ANY value *more than once*

    - by user2536778
    I am doing data analysis and sometimes I need to check and to make sure each row in excel does not have any repeated value. I hope that there is a formula where each time if there's a repeated value in the same row, the value will be highlighted and it doesn't matter what value it is, as long as it's repeated in the same row. I try to search it everywhere but the closest I can find is below question & answer ( which couldn't apply to me as I need a formula that can highlight any value that's repeated and not only zero): I have rows which contain grades for students (numerical values), where the number 0 means they missed a class. I want the row to be highlighted in one color if they have "0" 3 or 4 times, and in another color if they have "0" 5 times or more. =COUNTIF(1:1,0)=5 Anyone can help me? Thanks in advance!

    Read the article

  • Google maps api v3: geocoding multiple addresses and infowindow

    - by user2536786
    I am trying to get infowindow for multiple addresses. Its creating markers but when I click on markers, infowindow is not popping up. Please help and see what could be wrong in this code. Rest all info is fine only issue is with infowindow not coming up. <!DOCTYPE html> <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8" /> <title>Google Maps Multiple Markers</title> <script src="http://maps.google.com/maps/api/js?sensor=false" type="text/javascript"></script> </head> <body> <div id="map" style="height: 800px;"></div> <script type="text/javascript"> var locations = [ ['Bondi Beach', '850 Bay st 04 Toronto, Ont'], ['Coogee Beach', '932 Bay Street, Toronto, ON M5S 1B1'], ['Cronulla Beach', '61 Town Centre Court, Toronto, ON M1P'], ['Manly Beach', '832 Bay Street, Toronto, ON M5S 1B1'], ['Maroubra Beach', '606 New Toronto Street, Toronto, ON M8V 2E8'] ]; var map = new google.maps.Map(document.getElementById('map'), { zoom: 10, center: new google.maps.LatLng(43.253205,-80.480347), mapTypeId: google.maps.MapTypeId.ROADMAP }); var infowindow = new google.maps.InfoWindow(); var geocoder = new google.maps.Geocoder(); var marker, i; for (i = 0; i < locations.length; i++) { geocoder.geocode( { 'address': locations[i][1]}, function(results, status) { //alert(status); if (status == google.maps.GeocoderStatus.OK) { //alert(results[0].geometry.location); map.setCenter(results[0].geometry.location); marker = new google.maps.Marker({ position: results[0].geometry.location, map: map }); google.maps.event.addListener(marker, 'mouseover', function() { infowindow.open(marker, map);}); google.maps.event.addListener(marker, 'mouseout', function() { infowindow.close();}); } else { alert("some problem in geocode" + status); } }); } </script> </body> </html>

    Read the article

  • Creating keystore for jarsigner programmatically

    - by skayred
    I'm trying to generate keystore with certificate to use it with JarSigner. Here is my code: System.out.println("Keystore generation..."); Security.addProvider(new BouncyCastleProvider()); String domainName = "example.org"; KeyPairGenerator keyGen = KeyPairGenerator.getInstance("RSA"); SecureRandom random = SecureRandom.getInstance("SHA1PRNG", "SUN"); keyGen.initialize(1024, random); KeyPair pair = keyGen.generateKeyPair(); X509V3CertificateGenerator v3CertGen = new X509V3CertificateGenerator(); int serial = new SecureRandom().nextInt(); v3CertGen.setSerialNumber(BigInteger.valueOf(serial < 0 ? -1 * serial : serial)); v3CertGen.setIssuerDN(new X509Principal("CN=" + domainName + ", OU=None, O=None L=None, C=None")); v3CertGen.setNotBefore(new Date(System.currentTimeMillis() - 1000L * 60 * 60 * 24 * 30)); v3CertGen.setNotAfter(new Date(System.currentTimeMillis() + (1000L * 60 * 60 * 24 * 365*10))); v3CertGen.setSubjectDN(new X509Principal("CN=" + domainName + ", OU=None, O=None L=None, C=None")); v3CertGen.setPublicKey(pair.getPublic()); v3CertGen.setSignatureAlgorithm("MD5WithRSAEncryption"); X509Certificate PKCertificate = v3CertGen.generateX509Certificate(pair.getPrivate()); FileOutputStream fos = new FileOutputStream("/Users/dmitrysavchenko/testCert.cert"); fos.write(PKCertificate.getEncoded()); fos.close(); KeyStore ks = KeyStore.getInstance(KeyStore.getDefaultType()); char[] password = "123".toCharArray(); ks.load(null, password); ks.setCertificateEntry("hive", PKCertificate); fos = new FileOutputStream("/Users/dmitrysavchenko/hive-keystore.pkcs12"); ks.store(fos, password); fos.close(); It works, but when I'm trying to sign my JAR with this keystore, I get the following error: jarsigner: Certificate chain not found for: hive. hive must reference a valid KeyStore key entry containing a private key and corresponding public key certificate chain. I've discovered that there must be a private key, but I don't know how to add it to certificate. Can you help me?

    Read the article

  • Facebook Open Graph Not Showing Object Title

    - by gregavola
    I'm having conflicting reports for our users that people that share Object Graph objects to their wall, are sometimes showing the Object title and other times not. Specifically, every test I do on my own account shows the Object Title, but on their Mobile apps - it doesn't appear. I've tested the Open Graph debugger.So I have a couple of questions: Is there a length limit on the number of characters? Does Facebook not show the whole Object.title on Mobile? Does Facebook scrap the OG tags and if it can't find them or if it timeout do they not receive them? Here is my sample OG url: https://untappd.com/user/gregavola/checkin/35486976 Response from FB: Post on my Wall: What can I do here? What am I missing?

    Read the article

  • Android camera AVD error 100

    - by Cristian Voina
    I am trying to learn how to make a simple app in android. As background information I have only programmed in C language, no OOP. Currently I am trying turn on the camera using the indications from Android Developer site but some minor changes: - no button for capturing image. - no new activity. What I am trying to do is jut preview the camera. I will post the Code that I am using, the manifest and the LogCat. Main Activity: package com.example.camera_display; import android.app.Activity; import android.hardware.Camera; import android.os.Bundle; import android.view.Menu; import android.widget.FrameLayout; import android.widget.TextView; public class MainActivity extends Activity { private Camera mcamera; private CameraPreview mCameraPreview; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); mcamera = getCameraInstance(); mCameraPreview = new CameraPreview(this, mcamera); FrameLayout preview = (FrameLayout) findViewById(R.id.camera_preview); preview.addView(mCameraPreview); } public static Camera getCameraInstance(){ Camera c = null; try { c = Camera.open(); // attempt to get a Camera instance } catch (Exception e){ // Camera is not available (in use or does not exist) } return c; // returns null if camera is unavailable } @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.main, menu); return true; } } CameraPreview Class: package com.example.camera_display; import java.io.IOException; import android.content.Context; import android.hardware.Camera; import android.util.Log; import android.view.SurfaceHolder; import android.view.SurfaceView; /** A basic Camera preview class */ public class CameraPreview extends SurfaceView implements SurfaceHolder.Callback { private static final String TAG = "MyActivity"; private SurfaceHolder mHolder; private Camera mCamera; public CameraPreview(Context context, Camera camera) { super(context); mCamera = camera; // Install a SurfaceHolder.Callback so we get notified when the // underlying surface is created and destroyed. mHolder = getHolder(); mHolder.addCallback(this); // deprecated setting, but required on Android versions prior to 3.0 mHolder.setType(SurfaceHolder.SURFACE_TYPE_PUSH_BUFFERS); } public void surfaceCreated(SurfaceHolder holder) { // The Surface has been created, now tell the camera where to draw the preview. try { mCamera.setPreviewDisplay(holder); mCamera.startPreview(); } catch (IOException e) { Log.d(TAG, "Error setting camera preview: " + e.getMessage()); } } public void surfaceDestroyed(SurfaceHolder holder) { // empty. Take care of releasing the Camera preview in your activity. } public void surfaceChanged(SurfaceHolder holder, int format, int w, int h) { // If your preview can change or rotate, take care of those events here. // Make sure to stop the preview before resizing or reformatting it. if (mHolder.getSurface() == null){ // preview surface does not exist return; } // stop preview before making changes try { mCamera.stopPreview(); } catch (Exception e){ // ignore: tried to stop a non-existent preview } // set preview size and make any resize, rotate or // reformatting changes here // start preview with new settings try { mCamera.setPreviewDisplay(mHolder); mCamera.startPreview(); } catch (Exception e){ Log.d(TAG, "Error starting camera preview: " + e.getMessage()); } } } Manifest: <uses-permission android:name="android.permission.CAMERA"/> <uses-feature android:name="android.hardware.camera"/> LOG CAT: 06-30 15:58:35.075: D/libEGL(1153): loaded /system/lib/egl/libEGL_emulation.so 06-30 15:58:35.147: D/(1153): HostConnection::get() New Host Connection established 0x2a156060, tid 1153 06-30 15:58:35.478: D/libEGL(1153): loaded /system/lib/egl/libGLESv1_CM_emulation.so 06-30 15:58:35.515: D/libEGL(1153): loaded /system/lib/egl/libGLESv2_emulation.so 06-30 15:58:36.334: W/EGL_emulation(1153): eglSurfaceAttrib not implemented 06-30 15:58:36.685: D/OpenGLRenderer(1153): Enabling debug mode 0 06-30 15:58:36.935: D/MyActivity(1153): Error starting camera preview: startPreview failed 06-30 15:58:36.965: I/Choreographer(1153): Skipped 125 frames! The application may be doing too much work on its main thread. 06-30 15:58:38.455: W/Camera(1153): Camera server died! 06-30 15:58:38.455: W/Camera(1153): ICamera died 06-30 15:58:38.476: E/Camera(1153): Error 100 So If anyone could tell me what I am doing wrong (and explain why it should be done different) that would be great :) Thanks!

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >