develooper Front page | perl.sdl.devel | Postings from June 2010

Re: Interfacing SDL Surface with a piddle

Thread Next
From:
Kartik Thakore
Date:
June 25, 2010 15:47
Subject:
Re: Interfacing SDL Surface with a piddle
Message ID:
F24FBC9E-A7B2-4E10-9205-A0697E46DBCF@gmail.com

> From: Kartik Thakore <thakore.kartik@gmail.com>
> Date: June 25, 2010 5:52:57 PM EDT
> To: David Mertens <dcmertens.perl@gmail.com>
> Cc: PDL-porters@jach.hawaii.edu, sdl-devel@perl.org
> Subject: Re: Interfacing SDL Surface with a piddle
>

> Hi,
>
> Again I think I have found out why PDL piddle cannot seem to write  
> to SDL
> surface. During the slice the PV is changed. I have attached the  
> script
> that will produce the following output (please update your SDL to
> http://github.com/kthakore/SDL_perl ).
>
> Here is what I have found:
>
> So how can I make the piddle not swap out the PV ?
>
>
> ###################  PIDDLE BEFORE ######################
> SV = RV(0x142ac70) at 0x142ac64
>  REFCNT = 1
>  FLAGS = (PADMY,ROK)
>  RV = 0x142b354
>  SV = PV(0x1287abc) at 0x142b354
>    REFCNT = 2
>    FLAGS = (POK,pPOK)
>    PV = 0xcebefc "\0"\0
>    CUR = 1
>    LEN = 4
>
> #################### SURFACE PIXELS ##############
> SV = RV(0x142b330) at 0x142b324
>  REFCNT = 1
>  FLAGS = (TEMP,ROK)
>  RV = 0x3e90fc
>  SV = PV(0x1287a9c) at 0x3e90fc
>    REFCNT = 1
>    FLAGS = (POK,pPOK)
>    PV = 0xcea408 "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
>    CUR = 16
>    LEN = 0
>
> ##################### PIDDLE AFTER REASSIGN ###############
> SV = RV(0x142ac70) at 0x142ac64
>  REFCNT = 1
>  FLAGS = (PADMY,ROK)
>  RV = 0x142b324
>  SV = PV(0x1287a9c) at 0x142b324
>    REFCNT = 1
>    FLAGS = (POK,pPOK)
>    PV = 0xcea408 "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
>    CUR = 16
>    LEN = 0
>
> ##################### PIDDLE AFTER upd_data ###############
> SV = RV(0x142ac70) at 0x142ac64
>  REFCNT = 1
>  FLAGS = (PADMY,ROK)
>  RV = 0x142b324
>  SV = PV(0x1287a9c) at 0x142b324
>    REFCNT = 1
>    FLAGS = (POK,pPOK)
>    PV = 0xcea408 "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
>    CUR = 16
>    LEN = 0
>
> ##################### PIDDLE AFTER SLICE ###############
> SV = RV(0x142b350) at 0x142b344
>  REFCNT = 1
>  FLAGS = (TEMP,ROK)
>  RV = 0x142b354
>  SV = PV(0x1287abc) at 0x142b354
>    REFCNT = 2
>    FLAGS = (POK,pPOK)
>    PV = 0x9e1384 "\377\3607\0\0\0\0\0\0\0\0\0\0\0\0\0" <== ***CHANGED
>    CUR = 16
>    LEN = 16
>
> ##################### SURFACE AFTER manual writing ###############
> SV = RV(0x142b3b0) at 0x142b3a4
>  REFCNT = 1
>  FLAGS = (TEMP,ROK)
>  RV = 0x142b344
>  SV = PV(0x1287ad4) at 0x142b344
>    REFCNT = 1
>    FLAGS = (POK,pPOK)
>    PV = 0xcea408 "\0\0\0\0\0\0\0\0\0\0\377\377\0\0\0\0"
>    CUR = 16
>    LEN = 0
>
>
>


Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About